I have read about magnetostatics and read about Lorentz force which is sum of electric force and magnetic force so it is a electromagnetic force and the mathematical expression of Lorentz force is $F=q(E+v\times B)$. So, if I want to calculate work done due to this force, I get \begin{align} \mathbf F \cdot \mathrm d\mathbf r & = q\mathbf E \cdot \mathrm d\mathbf r+ q (\mathbf v×\mathbf B)\cdot \mathrm dr \\ & =q\mathbf E \cdot \mathrm d\mathbf r+q (\mathbf v×\mathbf B)\cdot \mathbf v \:\mathrm dt \\ & =q\mathbf E \cdot \mathrm d\mathbf r+0 \\ & =q\mathbf E \cdot \mathrm d\mathbf r, \end{align} So it is only due to electrical force. However, the work done due to magnetic force, which is $\mathbf F=q(\mathbf v×\mathbf B)$, is zero.
So we can write, $$∮\mathbf F\cdot \mathrm d \mathbf r=0 .$$ Hence, from Stokes' theorem, we have $$∮\mathbf F \cdot \mathrm d \mathbf r=∬(∇×\mathbf F ) \cdot \mathrm d\mathbf s=0$$
So we can say $∇×\mathbf F=0$, but I read in books that $∇×\mathbf F≠0$.
But it gives no explanation please explain why is this happened how can curl of $\mathbf F$ be non zero?