Our system of choice is a gas of either cold or hot atoms, excited by the propagating photons to high-lying Rydberg levels. The ERC project focuses on optically-driven spatial and spectral structures and on multimode operation. We have built two experimental setups – hot-atom and ultracold-atom systems – for realizing these ideas. We analyzed the enhancement of photonic quantum gates by an optically-induced cavity, that is, by a photonic resonator generated by illuminating the medium with a structured pattern. We showed that the circulation of photons back-and-forth in the resonator enhances the gate fidelity, surpassing the well-known limitations of such gates. Using the cold atoms, we realized a variety of interaction regimes, from strong photon-photon attraction (dominated by one and two bound-states), through single-photon saturable absorption and genuine three-photon interaction, to the formation of ordered states of photons. Using the hot atom, we demonstrated fast, coherent excitation of electronic orbitals, towards the realization of Rydberg-mediated nonlinear optics with hot atoms. Achieving the fast (sub-nanosecond) excitation to the Rydberg level requires strong (kilowatt peak-power) pulses of narrowband infrared light, and we have developed a unique laser system to achieve it. We recently obtained preliminary signals of non-classical light generated by the hot atoms in this configuration. For the same system, we developed and demonstrated methods to counteract the reduction of absorption and reduction of coherence time due to thermal motion by using optical driving, which is crucial for reaching the quantum nonlinear optics regime with hot atoms. We developed unique thin optical fibers, which are optical structures that can guide a light field while still maintaining most of the field outside the structure. This platform is particularly suitable for realizing quantum nonlinear optics with hot atoms. Finally, we developed a novel scheme for a robust two-photon phase gate based on counter-propagating polaritons. We used this idea and others developed in this project to contribute to a recent analysis of the enhancement of photonic quantum computation using quantum nonlinear optics.