Martian water came from the rings of Saturn, before Saturn had rings. Same event created both, and filled Earth with salt water oceans. Google “Dave Talbott, Saturn Thesis”.
Immanuel Velikovsky opines that the loss of Martian water was much more recent and due to a near approach of a wandering body with a greater gravity that stripped away the atmosphere and most water. Worlds in Collision, written in 1950.