throw error when css string is invalid