I am trying to understand how SSL certificate and signing and the chain of trust works.

I know about `root CAs` and that they are used to sign `intermediate CAs` that sign the end certificates that are issued to a website. I also understand how the chain of trust works and that because a ceritifcate signed for `X.com` is signed by the intermediate certificate that issued it which is signed by the root CA, I can be assured that I am connecting to `X.com`.

My question is, how long does this chain extend? Can't I use `X.com` to sign a certificate for another domain, say `Y.com`. If no, why not? If yes, I don't see the purpose of signing.