You expect Z.html to be locked, but it won't be. The client won't be surprised. To the client, it looks as if the target of Z.html is the collection member, and the target will be locked. But another principal could delete Z.html in the locked collection. This would surprise the lock holder.
Some surprise is inherent in references.
We can't avoid surprising down-level clients. The best we can do is default to something close to the intuitive case. It's only operations on the namespace that produce surprising results. A referencing client who is a good citizen will check whether the target resource is locked before modifying a direct reference. So it is possible to avoid the kind of surprises Jim W is worried about by being good citizens.