Defininately get the problem found/ fixed before you go to the trouble of replacing the carpet and insulation.

Check the plenum (engine compartment side) where the a/c cooling coil is located, for proper condensation/ water drainage. There should be a small hole at or near the bottom, possibly with a flexable rubber flap covering it. On older GM's, dirt, leaves, ect., would clog or block the flap and condensation and rain from the cowl fresh air intake would fill the plenum until it would overflow through the lowest point of the ventilation ductwork, usually the heater ducts.

As far as the smell and discoloration go, I know that 10% diluted bleach will kill the mold stains, but will kill your carpet as well. Try testing some LYSOL or other disinfectant spray on an inconspicuous area of the carpet (under the door sill plate, for example) for staining or discoloration. For the smell possibly FABREEZE (sp?) .The only other thing I can think of for the smell is some sort of OZIUM odor eliminator