For a (suppose smooth) map $\phi: M \rightarrow N$ where $M$ and $N$ are smooth Riemannian manifolds, the second fundamental form of $\phi$ is defined as $\nabla d\phi$.
My problem is I can not see how this Levi-Civita connection works: if I compute $\nabla_{e_j} d\phi (e_i)$ for $e_i,e_j \in TM$, I am computing the derivative of $d\phi(e_i)$, which is an element of $TN$, respect to $e_j$, which is an element of $TM$.
Maybe this means that $\nabla_{e_j} d\phi (e_i) \equiv\nabla_{d\phi(e_j)} d\phi (e_i)$?
When we write $\nabla d \phi$, we make a lot of omissions and identification in order to highlight what is essential. Unfortunately, this does not help in calculations. In order to be very careful, as Prof. Shifrin suggests, quite a bit of technical work needs to be done, which I am quite lazy now to reproduce and only can recommend the classical textbooks or Joel Persson's Master's thesis where everything is laid down nicely.
The bottom line is that $d \phi$ should be considered a section of $T^*M \otimes \phi^* TN$ with the coupled connection $\nabla^{T^*M \otimes \phi^* TN}$ which is induced by the Levi-Civita connection on the sections of $TM$ (vector fields on $M$), but on the sections of $\phi^* TN$ (vector fields along $M$) it is acting as the pull-back Levi-Civita connection .