A simple voltage divider using two resistors could just use the following formula for the midpoint voltage:
$$V_{_\text{TH}}=\frac{V_2\cdot R_1+V_1\cdot R_2}{R_1+R_2}$$
That's where \$V_2\$ is the voltage tied to \$R_2\$ and \$V_1\$ is the voltage tied to \$R_1\$.
It may (among other ways) follow this approach:
$$\require{cancel}\begin{align*}
I_{_\text{TOT}} &=\frac{V_1-V_2}{R_1+R_2}
\\\\
V_{_\text{TH}} &= V_2+I_{_\text{TOT}}\cdot R_2
\\\\
&=V_2+\frac{V_1-V_2}{R_1+R_2}\cdot R_2
\\\\
&=V_2\cdot \frac{R_1+R_2}{R_1+R_2}+\frac{V_1-V_2}{R_1+R_2}\cdot R_2
\\\\
&= \frac{V_2\cdot\left(R_1+R_2\right)}{R_1+R_2}+\frac{\left(V_1-V_2\right)\cdot R_2}{R_1+R_2}
\\\\
&= \frac{V_2\cdot\left(R_1+R_2\right)+\left(V_1-V_2\right)\cdot R_2}{R_1+R_2}
\\\\
&= \frac{V_2\cdot R_1\cancel{+V_2\cdot R_2}+V_1\cdot R_2\cancel{-V_2\cdot R_2}}{R_1+R_2}
\\\\
&=\frac{V_2\cdot R_1+V_1\cdot R_2}{R_1+R_2}
\end{align*}$$
Note that the voltage difference is used to work out the current through the two resistors, in series. Not the voltage sum.
In the final equation the voltages are summed, but not before first multiplying them by the resistance opposite to them.