improve importStyles implementation
introduce $Document type
fix issues on context method, dom -> global