Prove close form $\int_a^1 \frac{x}{\sqrt{x^2-a^2}}\ln\frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}}dx=\frac{\pi}{2}(1-a)$ I found this integral in a textbook (stated without proof),
$$J(a)=\int_a^1 \frac{x}{\sqrt{x^2-a^2}}\ln\frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}}dx=\frac{\pi}{2}(1-a)$$
with $0\le\,a\le\,1$.
I tried to confirm its validity.
For $a=1$,
$$J(1)=\int_1^1 ln\frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}}dx=0$$
For $a=-1$,
$$J(-1)=\int_{-1}^1 \frac{x}{\sqrt{x^2-1}}ln\frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}}dx\;=\pi
$$
Simplifying the expression in the logarithm,
$$J(-1)=\int_{-1}^1 \frac{x}{\sqrt{x^2-1}}ln\frac{1-\sqrt{1-x^2}}{x}dx$$
Applying integration by parts,
$$J(-1)=\int_{-1}^1 \frac{\sqrt{x^2\,-1}}{x\sqrt{1-x^2}}dx=i\int_{-1}^1\frac{1}{x}dx=iln(x)|_{-1}^1$$
$$J(-1)=iln(1)-iln(i)=i(-i\pi)=\pi$$
Could there be any way to prove the $J(a)$?

Integrate by parts with $d\left( \sqrt{x^2-a^2}\right)= \frac{x}{\sqrt{x^2-a^2}}dx$
\begin{align}
&\int_a^1 \frac{x}{\sqrt{x^2-a^2}}\ln\frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}}\ dx\\
=& \int_a^1\frac1x \sqrt{\frac{x^2-a^2}{1-x^2}}dx \overset{y^2=\frac{x^2-a^2}{1-x^2}}=\int_0^\infty
\frac{(1-a^2) y^2}{(y^2+a^2)(y^2+1)}dy=\frac\pi2(1-a)
\end{align}
