Even thin coats CAN leave a ridge. I sand the result, after removing tape, with #1200 or even finer. It is amazing how fine a sandpaper you can get these days. If you are sanding a gloss, you will then have to apply glosscoat, but I usually do anyway. With a fine enough sandpaper you may get away without flat coating when doing flats.
One very labor-intensive method is to double mask so that you are putting down the same number of layers of each color. Say you are putting down red and yellow. After primer is done, mask off only yellow areas and spray N coats. Then mask off yellow and spray red N coats. Of course, each coat has to be put down the same thickness. About the only time I do this is when spraying Alclad and some normal color paint.