Water covers 71% of the Earth's surface, where the steady increase in oceanic activities has promoted the need for reliable maritime communication technologies. The existing maritime communication systems involve terrestrial, aerial, and satellite networks. This paper presents a holistic overview of the different forms of maritime communications and provides the latest advances in various marine technologies. The paper first introduces the different techniques used for maritime communications over the RF and optical bands. Then, we present the channel models for RF and optical bands, modulation and coding schemes, coverage and capacity, and radio resource management in maritime communications. After that, the paper presents some emerging use cases of maritime networks, such as the Internet of Ships (IoS) and the ship-to-underwater Internet of things (IoT). Finally, we highlight a few exciting open challenges and identify a set of future research directions for maritime communication, including bringing broadband connectivity to the deep sea, using THz and visible light signals for on-board applications, and datadriven modeling for radio and optical marine propagation.