"The term "standard of performance" means a standard for emissions of air pollutants which reflects the degree of emission limitation achievable through the application of the best system of emission reduction which (taking into account the cost of achieving such reduction and any nonair quality health and environmental impact"
Note the portion that states "taking into account the cost of achieving such reduction". This is in the very first paragraph. The argument is that they have not adequately done this.
The ruling doesn't claim the EPA didn't take into the cost of achieving the reduction in pollutants; it claims that Congress didn't appropriately delegate to the EPA the authority to implement systems to reduce the pollutants.
Note the portion that states "taking into account the cost of achieving such reduction". This is in the very first paragraph. The argument is that they have not adequately done this.