I answered in the "My Next Car" section, but I'll copy them. I don't own either car.
I would suggest the Mazda CX-5 over the Subaru Forester. The Mazda will likely be more reliable overtime. Also, the Mazda has a MUCH nicer interior than the Subaru. The Forester is much more utilitarian than the Mazda. The CX-5 is one of the best looking CUVs, IMO, inside and out. The Mazda has a better ride and is quieter than the Subaru. The Subaru has a good driving position and is easy to see out of, great for elderly people. The cool styling of the CX-5 means that visbility is compromised. It doesn't have as good of a driving position as the Subaru. The Subaru has a CVT, which is only good for fuel efficiency, NOT fun. The transmission in the Mazda is much better.
You really can't go wrong with either. It's smart to buy a fully loaded small crossover like these instead of a small luxury CUV. You get more for your money and a great, practical car. If it were my money, I'd get a Mazda CX-5. BTW, after negotiating, I think you could get a 2018 Subaru Forester 2.5i Touring under your budget.
The previous CX-5 before 2017 was loud and tinny. Car and Driver writes, "At highway speeds, Mazda's efforts to silence the CX-5 with a thicker windshield and additional sound insulation have paid dividends. In our test, the sound level at 70 mph dropped from the previous model's 69-decibel reading to a luxury-car-like 65 decibels. The redesigned interior also moves the CX-5 closer to the premium brands."
Motor Trend wrote, "The previous-generation CX-5 was great on a back road, too, but it was one of the loudest crossovers in the class on the freeway. The extra sound deadening Mazda worked into the 2017 CX-5 really pays off. At freeway speeds the cabin is quiet and serene... Good suspension damping filters out road imperfections and takes care of big bumps with ease."
The 2016 CX-5 had a problem with the windshield cracking easily. There isn't any information on the new 2017 CX-5 yet. The 2017 uses a new windshield, which helps with insulating out the road noise. I would think Mazda listened to their customers' complaints about the previous gen windshield. The windshield is not covered under warranty at least for my 2016 Prius, which is known for problems with the windshield chipping. Camera and sensor recalibration was free at the dealer, but the windshield was $560.
I'd take the 2017, not the older CX-5s because the new one is so much improved. The 2017 Forester has had complaints about the CVT transmission jerking.