Quantum symmetric Kac–Moody pairs