It's nice to have these types of niches when they make you money. But the Mac isn't profitable like the iPhone is, and probably makes less money than the iPad does if you count aftermarket service sales. The further Apple drifts from their roots as a computer manufacturer, the more the Mac starts to look like a liability to them.
Apple's Last Stand is their prosumer segment, and once that's gone I don't think their vertical integration playbook gets them anywhere further. Their bottom line is dependent on finding new ways to make B2C profitable, which has resulted in subscription services like AppleTV/Apple Music/iCloud so far.
That looks pretty healthy to me.
Note that because most enterprise software is now web based ( ie moved to the data centre as you have pointed out ) - a lot of the corporate Windows only lockin has gone - so I'm seeing a steady rise in Macs in business.
What's not healthy is the desktop market ( apple laptops outsell desktops like 10:1 ) - but that's whiles that's more marked in the Apple space, it's largely an overall market trend. ( Overall desktops are about 20% of total shipments ).
So Apple will only be in trouble in this space if the laptop ceases to become wanted - and that's all about the interface - some apps are better with keyboard and mouse/trackpad and a bigger screen. If all that goes away and we just talk to our computers then I'd argue that Apple are better placed than Lenovo to weather that one.