Among the prominent candidates for dark matter are bosonic fields with small scalar couplings to the Standard-Model particles. Several techniques are employed to search for such couplings and the current best constraints are derived from tests of gravity or atomic probes. In experiments employing atoms, observables would arise from expected dark-matter-induced oscillations in the fundamental constants of nature. These studies are primarily sensitive to underlying particle masses below $10^{-14}$ eV. We present a method to search for fast oscillations of fundamental constants using atomic spectroscopy in cesium vapor. We demonstrate sensitivity to scalar interactions of dark matter associated with a particle mass in the range $8cdot10^{-11}$ to $4cdot 10^{-7}$ eV. In this range our experiment yields constraints on such interactions, which within the framework of an astronomical-size dark matter structure, are comparable with, or better than, those provided by experiments probing deviations from the law of gravity.