Solution
= Solution
Since $A'/A=-i\hbar B=-\tfrac i2\tan(\phi-it)$ and
$$
\frac d{dt}\log\cos(\phi-it)=i\tan(\phi-it),
$$
integration gives
$$
\boxed{A(t)=A_0[\cos(\phi-it)]^{-1/2}},
$$
with the branch chosen continuously from the initial value. The constant $A_0$ fixes normalization.