Nearly 10,000 detained in Kazakhstan following protests