Electromagnetic waves in single- and multi-Josephson junctions