How to prove $\int_0^1 \frac{\arctan^2(x)\ln\left(\frac{x}{(1-x)^2}\right)}x \, \mathrm{d}x=G^2$? A while back I made a post asking for examples of integrals which evaluated to famous irrational constants (or constants that were very likely irrational but yet unproven to be). The top answer in said post was by Quanto, who posted this equation:

$$\int_0^1 \frac{\arctan^2(x)\ln\left(\frac{x}{(1-x)^2}\right)}x \, \mathrm{d}x=G^2 $$

where $G$ is Catalan's constant.
I decided to try and prove said equation. These were my attempts:

Attempt 1:
The integral can be split into a linear combination of the $2$ integrals $I_1 = \int_0^1 \frac{\arctan^2(x)\ln\left(x\right)}x \, \mathrm{d}x$ and $I_2 = \int_0^1 \frac{\arctan^2(x)\ln\left(1-x\right)}x \, \mathrm{d}x$ such that the original integral $I = I_1 - 2I_2$. The first integral was evaluated in this answer to be
$$
\int_0^1 \frac{\arctan^2(x)\ln\left(x\right)}x \, \mathrm{d}x = \operatorname{Li}_4 \left (\frac{1}{2} \right ) - \frac{151 \pi^4}{11520} + \frac{7}{8} \zeta (3) \ln(2) - \frac{\pi^2}{24} \ln^2(2) + \frac{1}{24} \ln^4(2)
$$
Following the same steps used to evaluate $I_1$ for $I_2$ we get
\begin{align*}
\int_{0}^{1}\frac{\arctan^2(x)\ln\left(1-x\right)}x \, \mathrm{d}x & =-\frac{\pi^4}{96} + 2\int_{0}^{1}\frac{\arctan(x)\, \mathrm{Li}_2(x)}{x^2+1} \, \mathrm{d}x\\
& = -\frac{\pi^4}{96} - 2\int_0^1 \int_0^1\frac{\arctan(x) \ln(1-xy)}{(x^2+1)y}\, \mathrm{d}y \, \mathrm{d}x
\end{align*}
which I couldn't find a way to continue evaluating even exploiting the change of the order of integration.
Attempt 2:
Trying the substitution $u = \frac{1-x}{1+x}$ gives
\begin{align*}
\int_0^1 \frac{\arctan^2(x)\ln\left(\frac{x}{(1-x)^2}\right)}x  \, \mathrm{d}x & = \int_{0}^{1} \left( \frac{\pi}{4} - \arctan(u) \right)^2 \ln\left(\frac{1-u^2}{4u^2} \right)\frac{2}{1-u^2} \, \mathrm{d}u
\end{align*}
This allows us to split the integral into several other integrals, however, several of the resulting integrals seemed to me equally hard to evaluate compared to the original. So I felt this approach was more akin to cutting off one hydra head, just to have two more take its place.
Attempt 3:
I noticed that given real numbers $a, l$ then $\Re\{l^3 - (l + ia)^3\} = 3a^2l$. This meant that taking $a = \arctan(x)$ and $l = \ln\left(\frac{x}{(1-x)^2} \right)$ we could get:
$$
\int_0^1 \frac{\arctan^2(x)\ln\left(\frac{x}{(1-x)^2}\right)}x \, \mathrm{d}x  = \frac{1}{3}\Re \left\{ \int_{0}^{1}\left[ \ln^3\left(\frac{x}{(1-x)^2} \right)- \frac{1}{2^3} \ln^3\left( \frac{(i-x)x^2}{(i+x)(1-x)^4}\right)\right] \frac{\mathrm{d}x}{x}\right\}
$$
which I had the hopes of being able to split up, but unfortunately the integrals don't converge separately.

Since the final result is so concise, I have hopes that there's a clever way to evaluate the integral which avoids going into all the polylogarithm-territory where similar integral evaluations end up going to.
I suspect (with no evidence, though) that the integral can be cleverly split up into a separable double integral, where each of the individual integrals would evaluate to $G$ by themselves (and hence their product resulting in $G^2$). This would kind of be like doing the evaluation of the Gaussian integral in reverse, starting at the single integral $I = 2\pi \int_{0}^{\infty}e^{-x^2} x \, \mathrm{d}x$ and then splitting it into $\left(\int_{\mathbb{R}}e^{-x^2} \, \mathrm{d}x\right)\left(\int_{\mathbb{R}}e^{-y^2} \, \mathrm{d}y\right)$, except that in this case the resulting product of integrals would be a product of known integral representations of Catalan's constant. But this is only conjecture as I haven't been able to spot a clever way to do this.
Does anyone have any ideas on how to evaluate this integral? Either by continuing/improving on my attempts or trying something else entirely, everything is welcome. Thank you very much!
 A: A second solution by Cornel Ioan Valean (in large steps)
Let's start with the variable change $\displaystyle x\mapsto i\frac{1-\sqrt{x}}{1+\sqrt{x}}$ and with understanding the resulting integral as a PV integral, and then we have
$$I=\int_0^1 \frac{\arctan^2(x)}{x}\log\left(\frac{x}{(1-x)^2}\right)\textrm{d}x$$
$$=\lim_{\epsilon\to 0^{+}}\biggr\{-\frac{1}{16}\int_{-1}^{-\epsilon}\frac{\log^2(x)}{\sqrt{x}(1-x)}\log\left(\frac{1-x}{2(\sqrt{x}-i)^2}\right)\textrm{d}x$$
$$+\frac{1}{16}\int_{\epsilon}^1\frac{\log^2(x)}{\sqrt{x}(1-x)}\log\left(\frac{2(\sqrt{x}-i)^2}{1-x}\right)\textrm{d}x\biggr\}$$
$$=\frac{1}{16}\Re\biggr\{\int_0^1\frac{\log^2(x)}{\sqrt{x}(1-x)}\log\left(\frac{2(\sqrt{x}-i)^2}{1-x}\right)\textrm{d}x\biggr\}$$
$$=\frac{1}{2}\log(2)\underbrace{\int_0^1 \frac{\log^2(x)}{1-x^2}\textrm{d}x}_{\displaystyle \text{Trivial}}+\underbrace{\frac{1}{16}\color{blue}{\int_0^1\frac{\log^2(x)\log(1+x)}{\sqrt{x}(1-x)}\textrm{d}x}}_{\displaystyle \text{Reducible to Derivatives form of Beta function}}-\underbrace{\frac{1}{16}\int_0^1\frac{\log^2(x)\log(1-x)}{\sqrt{x}(1-x)}\textrm{d}x}_{\displaystyle \text{Derivatives form of Beta function}}$$
$$=G^2.$$
A first note: For the blue integral one might observe that
$$\color{blue}{\int_0^1\frac{\log^2(x)\log(1+x)}{\sqrt{x}(1-x)}\textrm{d}x}=$$
$$=\int_0^1\frac{\log^2(x)(\log(1-x^2)-\log(1-x))}{\sqrt{x}(1-x)}\textrm{d}x$$
$$=\int_0^1\frac{(1+x)\log^2(x)\log(1-x^2)}{\sqrt{x}(1-x^2)}\textrm{d}x-\int_0^1\frac{\log^2(x)\log(1-x)}{\sqrt{x}(1-x)}\textrm{d}x,$$
and at this point it is crystal clear how the resulting integrals are expressible in terms of the derivatives of the Beta function.
A second note: The third equality is obtained by the use of this integral (very nicely and easily calculated), which is already well-known on the site, given in a trigonometric form.
More precisely, we have that
$$\Re\biggr\{\int_{-1}^0 \frac{\log^2(x)}{\sqrt{x}(1-x)}\log\left(\frac{1-x}{2(\sqrt{x}-i)^2}\right)\textrm{d}x\biggr\}$$
$$=-8\log(2)\pi \underbrace{\int_0^1\frac{\log(x)}{1+x^2}\textrm{d}x}_{\displaystyle-G}+8\pi \int_0^1\frac{\log(x)}{1+x^2}\log\left(\frac{1+x^2}{(1-x)^2}\right)\textrm{d}x$$
$$\overset{x\mapsto \tan(x)}{=}8\log(2)\pi G-16\pi\underbrace{\int_0^{\pi/4}\log(\cos(x)-\sin(x))\log(\tan(x))\textrm{d}x}_{\displaystyle \log(2)G/2}=0,$$
where the last integral is given at the previously mentioned link.
End of story
