Replacing door, window trim with watertight seals

How to seamlessly segue from old stucco to new