I’ve painted styrofoam and the pink foam with just house paint. The point is you need a water based paint. They sell sample size paint at paint stores for a very small price. $3 or $4 bucks.
Latex and acrylic paints will work with styrofoam; and possibly Krylon Fusion spray paints. Fusion is plastic compatible, but I have not tested it on styrofoam.
Most spray paints have solvents or propellants that will atatck styrofoam. Same for any solvent based paint of any kind. The basic rule is, if you are not sure, test it on some scraps.
I have used foam in boat building, white and pink, and put two coats of yellow carpenters glue on the foam. I fiberglass over the foam, the resin is devastating to uncovered foam. Owens Corning makes a composite foil faced insulation board that will not react with fiberglass resin, or oil based paint.
I use the sheets to form hull contours, and then cover with fiberglass mat, cloth, and tri-axle bi-ply for strength, loading up everything with waxless resin.
Zinsser makes a spray can primer/sealer called Bulls Eye 1-2-3. So long as you get good coverage of the foam, you can use all the standard spray paints over foam protected by it it.
For a set of scale steps, probably easier to use brushed on latex or other water-based paint.
My layout is mostly stryofoam painted with either chaep HD paint (sold at their ‘oops’ area) or inexepnsive craft paint. For larger areas, I use the HD paint and smaller the acryllic. You can apply with either a foam or bristle brush.