Assume we have a purely inductive circuit such as below:
To calculate the most general case, \$V_1\$ is given as such:
$$v(t) = V_m \cdot \cos(\omega t+\theta)$$
For an inductor, \$v(t) = L \dfrac{\mathrm{d}i(t)}{\mathrm{d}t}\$. Writing it in integral form:
$$i(0)+\int_0^t{v(t)\mathrm{d}t}= i(t)$$
Now consider \$i(0)=0\$, meaning there was no current in the system before the source was on:
$$\int_0^t{V_m\cdot \cos(\omega t+\theta) \mathrm{d}t}= i(t)$$
Moreover, the result of the integral, and hence the current:
$$\dfrac{V_m}{\omega}\cdot(\sin(\omega t+\theta)-\sin(\theta))= i(t)$$
If transformed to their complex counterparts via \$\mathrm{e}^{j\omega t} = \cos(\omega t)+j\sin(\omega t)\$, the result, which is the impedance, is not \$j\omega L\$ but some term similar to \$j\omega L\$, but also containing the phase of the voltage source, which shouldn't be there, since impedance is not dependent on the phase of the source.
Where am I going wrong?