<s>[INST] If $(A-B)^2=O_2$ then $\det(A^2 - B^2)=(\det(A) - \det(B))^2$ 
Let $A,B \in M_2(\mathbb{R})$ be two matrices such that $(A-B)^2=O_2$.
Prove $\det(A^2 - B^2)=(\det(A) - \det(B))^2$.

OBS. $O_2$ is the zero matrix

Let $D=A-B$ then $D^2=O_2$ therefore, using Cayley Hamilton theorem, we get $tr(D)=\det(D)=0$. It follows $tr(A)=tr(B)=t$ and, from here, $A^2 -B^2=t(A-B) + (\det(A) - \det(B))I_2$
This is all I could get.
UPDATE
The matrices are from $M_2(\mathbb{R})$. Sorry for misleading you.
 [/INST] Let's rewrite the - correct - identity you obtained as follows:
\begin{align*}& A^2 -B^2=t(A-B) + (\det(A) - \det(B))I_2\\
\iff& t(A-B)=A^2 -B^2- (\det(A) - \det(B))I_2\end{align*}
Squaring both sides of your original identity gives
$$(A^2 -B^2)^2=t^2\underbrace{(A-B)^2}_{=0} + 2(\det(A) - \det(B))t(A-B) + (\det(A) - \det(B))^2I_2.$$
Now substitute $t(A-B)$ given by the second equation:
\begin{align*}(A^2 -B^2)^2& =2(\det(A) - \det(B))[(A^2 -B^2)- (\det(A) - \det(B))I_2] + (\det(A) - \det(B))^2I_2\\
& = 2(\det(A) - \det(B))(A^2 -B^2)- (\det(A) - \det(B))^2I_2
\end{align*}
and lastly apply Cayley Hamilton to $A^2-B^2$ and compare the coefficients.
Note that no cancellation takes place, as, using that $tr(A)=tr(B)=t$, one can prove that 
$$2(\det(A) - \det(B))=-(tr(A^2+B^2))$$
Indeed this is again a consequence of Cayley Hamilton, taking its trace:
$$A^2-tr(A)A+\det(A)I_2=0\Rightarrow tr(A^2)-tr(A)^2+2\det(A)=0$$
</s>