this is how the cookie crumbles

That's how things are; that's life.
It's too bad about John and Mary getting divorced, but then that's how the cookie crumbles.
Categories: {informal} {v. phr.}