Let t = |sin x|. For x in [0, pi], we have t = sin x in [0, 1]. The equation becomes t^2 + t + b = 0. For each value of t in (0, 1), there are exactly two distinct values of x in [0, pi] satisfying sin x = t. Thus, for the original equation to have exactly two distinct real roots in [0, pi], the quadratic in t must have exactly one root in the interval (0, 1). Since the vertex of the parabola f(t) = t^2 + t + b is at t = -1/2, the function is strictly increasing on [0, 1], meaning we must have f(0) < 0 and f(1) > 0, which simplifies to -2 < b < 0.