It's completely counterintuitive, but that's how it works experimentally. For example:
Measure the spin of electrons in direction X (that's done with a weirdly shaped magnet). You'll get either +1 or -1 in a conveniently chosen unit system. That's already weird, you'll never measure +0.5 for example. Keep only the +1 electrons. You can measure them again and again, you'll always get +1 in the X direction.
Now measure those electrons in the Y direction, you'll also get either +1 or -1.
But now, if you measure in the X direction again, you'll get +1 or -1 with 50% probability; although before measuring in the Y direction, these electrons always had spin +1 in the X direction.
Measure the spin of electrons in direction X (that's done with a weirdly shaped magnet). You'll get either +1 or -1 in a conveniently chosen unit system. That's already weird, you'll never measure +0.5 for example. Keep only the +1 electrons. You can measure them again and again, you'll always get +1 in the X direction.
Now measure those electrons in the Y direction, you'll also get either +1 or -1.
But now, if you measure in the X direction again, you'll get +1 or -1 with 50% probability; although before measuring in the Y direction, these electrons always had spin +1 in the X direction.