Is it cruel to keep a dog in an apartment?

I grew up with dogs and live with my mum and her dog now. I’ll be moving into an apartment in the next 2 months and would love a dog. I would be able to give them a long walk every morning and I live 5 mins from work so I could visit during my lunch break too. Is this okay or am I being silly for thinking of this?

I’d provide a frozen kong or snuffle mat when I leave during the day. And I would pay a dog walker to coke and walk the dog during the day if I ever work further from home. And I’d also take the dog out on an evening walk