Why it behaves this way
Explanation
The dot product becomes much easier to trust when it stays geometric. This bench keeps two vectors, the angle between them, the signed projection of B onto A, and the scalar A dot B visible together so alignment reads like a picture before it becomes a formula.
The key move is to separate what points along A from what stays perpendicular to A. When B leans with A, the projection is positive. When B turns to ninety degrees, that along-A part collapses. When B leans past ninety degrees, the projection flips and the dot product turns negative for a geometric reason instead of a memorized case.