In this paper, we consider a radar system capable of adaptively adjusting its transmitted waveform to mitigate the effect of the environment and improve detection performance. We thus bring the potential of waveform agility to bear on the challenging problem of target detection in heavy sea clutter. Using a two-stage procedure, we .rst estimate the statistics of the sea clutter in the vicinity of a predicted target. A phase-modulated-waveform is then designed and transmitted so as to maximize the generalized likelihood ratio at the predicted target location, thus improving the signal-to-clutter ratio (SCR). Employing the compound-Gaussian (CG) model, we exploit a subspace-based approach to further mitigate sea clutter and deliver improved detection performance. Simulations illustrate the effectiveness of our method.