Hybrid phosphorus-doped silica architectures derived from a multistep sol-gel process for improving thermal stability and flame retardancy of cotton fabrics