We develop a non-overlapping domain decomposition method (DDM) for scalar wave scattering by periodic layered media. Our approach relies on robust boundary-integral equation formulations of Robin-to-Robin (RtR) maps throughout the frequency spectrum, including cutoff (or Wood) frequencies. We overcome the obstacle of non-convergent quasi-periodic Green functions at these frequencies by incorporating newly introduced shifted Green functions. Using the latter in the definition of quasi-periodic boundary-integral operators leads to rigorously stable computations of RtR operators. We develop Nyström discretizations of the RtR maps that rely on trigonometric interpolation, singularity resolution, and fast convergent windowed quasi-periodic Green functions. We solve the tridiagonal DDM system via recursive Schur complements and establish rigorously that this procedure is always completed successfully. We present a variety of numerical results concerning Wood frequencies in two and three dimensions as well as large numbers of layers.In the technologically relevant case of piecewise constant periodic layered media, simulation methods based on boundary-integral equations (BIE) and quasi-periodic Green functions are attractive candidates. Radiation conditions are enforced automatically, and discretizations of material interfaces are much smaller than volumetric discretizations and do not suffer from the pollution effect. Quasi-periodic Green functions are infinite sums of free-space Green functions with periodically distributed monopole singularities. These double sums converge, although very slowly, for all but a discrete set of "cutoff" frequencies, for a given quasi-periodicity parameters (Bloch wavevector). These are cutoff frequencies at which a Rayleigh diffraction mode transitions between propagating and evanescent and the number of propagating directions jumps. Around these frequencies, the energy is rapidly redistributed along emerging new directions and is associated with anomalous scattering behavior. These frequencies are often referred to as Wood frequencies (or Wood configurations of wavevector and frequency) because their problematic association in the literature to Wood's anomaly; see the works [30,41,45,48],[39, Ch. 1] and references therein for discussions on this phenomenon. Popular methods for accelerating the slow convergence at non-Wood frequencies include Ewald summation [25] and lattice sums [37]. At very high frequencies, asymptotic methods help to accelerate computation; see for example [34].While the underlying scattering problems are, with regard to the PDE, generically stable at Wood configurations of wavevector and frequency, the latter pose a challenge to BIE for quasiperiodic problems. In three dimensions, they become increasingly close together at high frequency, and this puts the solution of quasi-periodic problems based on the quasi-periodic Green function out of reach. For periodic layered media with large numbers of layers, such as thin films used in photovoltaic cells, the probability ...