Symmetric Lorentzian and asymmetric Fano line shapes are fundamental spectroscopic signatures that quantify the structural and dynamical properties of nuclei, atoms, molecules, and solids. This study introduces a universal temporal-phase formalism, mapping the Fano asymmetry parameter q to a phase ϕ of the time-dependent dipole response function. The formalism is confirmed experimentally by laser-transforming Fano absorption lines of autoionizing helium into Lorentzian lines after attosecond-pulsed excitation. We also demonstrate the inverse, the transformation of a naturally Lorentzian line into a Fano profile. A further application of this formalism uses quantum-phase control to amplify extreme-ultraviolet light resonantly interacting with He atoms. The quantum phase of excited states and its response to interactions can thus be extracted from line-shape analysis, with applications in many branches of spectroscopy.