NY State is struggling, with Upstate burdened with real estate and other taxes that its residents and businesses can’t afford.
NYC is thriving, with if anything, more and more of a concentration of professionals and the upper class. The merely lower- to middle-middle class increasingly move out beyond the City’s core. Manhattan itself is incredibly expensive except to its Hispanic north and only the blocks closest to the projects in Spanish Harlem, etc..
It is in a way easier to be rich or poor in NYC than middle class, but it still draws in many young college graduates who are happy to live in a shoebox for the experience of being part of an incredibly vibrant city.