removes legacy device detection, improves cookie handling