Unified Landau theory for the nematic, smecticA, and smecticCphases of liquid crystals