To describe the king as “entangled in the tresses” is to assert that there is a level of G-d that is entangled by our conceptions and projections of Him/Her/It.
The Torah, says Sefer Yetzira, is really three in one. There’s the Torah of Bereshit, the Torah of Sinai, and the Torah of souls. Our job, says the Baal Shem Tov, is to unify these three Torot with every word we speak and breath we take.
The Zohar is teaching that HaShem (so to speak) looked into Him/Her/Itself and articulated a will for a creation that would revel in the glory of G-d. That vision and all the myriad ways it could materialize and all the laws that define its parameters…that is the primordial Torah.
This Torah of Atzilut was what Adam would have received had he not opted for duality, preferring Knowledge of Good and Evil over the Tree of Life’s non-dual Knowledge-of-the-Holy-One. It is also the Torah that we received at Sinai, but forfeited when we too betrayed its calling.