OP AMP level shifter circuit
The following should work.



simulate this circuit &ndash; Schematic created using CircuitLab
R1 and R2 divide down the input voltage by a factor of about 1/4 (0.2492) to make voltage X.  X = 2.492V when +12V_BAT is 10V.  X = 2.991V when +12V_BAT is 12V.
The difference between X and 3V_REF is amplified by a factor of about 5.9.
The overall equation for the output is...
VOUT = 3V - (3V - V_BAT * 0.2492) * 5.9.
You can of course scale up the resistors by some factor to reduce current if needed.  Also, I would recommend using 0.1% resistors.
DETAILED MATH:
The equation for the circuit is...
VOUT = REF - (REF - G1 * VIN) * G2
Where...
G1 =  R2 / (R2 + R1)
G2 = R4 / R10
REF is the 3V reference voltage.
To solve for G1 we first choose a maximum input voltage (lets call it VIN1) for which the output = REF.  This leads to the following equation...
REF = REF - (REF - G1 * VIN1) * G2
Rearranging and solving for G1 gives....
G1= REF / VIN1 
In your case VIN1 = 12V and REF = 3V, so G1 = 3V / 12V = 1/4.  Picking R1 = 100K and R2 = 33.2K gives this ratio (0.2492).
Knowing G1 we can now solve for G2.  To do this, we pick some minimum input voltage (lets call it Vin2) for which we want the output to be 0V.  This leads to the following equation...
0V = REF - (REF - G1 * VIN2) * G2
Rearranging and solving for G2 gives....
G2 = REF /(REF - G1 * VIN2)
In your case REF = 3V, VIN2 = 10V, and G1 = 0.2492.
Therefore G2 = 3V / (3V - 10V * 0.2492) = 5.911.
Picking R10 = 10K and R4 = 59K gives the required G2 (5.90).