One easy and relatively say approach would be to take a small transformer (e.g. 230V to 12V), connect its primary across the lamp contacts and rectify + filter the secondary. Measure that rectified voltage, which you can scale and amplify as you desire. Personally I'd make a simple opamp-based differential amplifier with a static offset so that you only measure fluctuations that are meaningful, then scale that as needed to feed it into the ESP32's ADC. Note that the ADC on the ESP32 isn't very linear, but this will not be a major concern. Due to the filtration of the signal, there will be some delay/dampening so in your PID you'll have to prevent oscillations. That's a matter of judicious programming.
But measuring actual light output is a more sensible approach overall.