How the environment controls absorption and fluorescence spectra of PRODAN: a quantum-mechanical study in homogeneous and heterogeneous media