EQUITY AND LONG-TERM INCENTIVE COMPENSATION PLANS - Share-based Compensation Expense (Details) - USD ($) $ in Thousands  | 
3 Months Ended | 9 Months Ended | |||
|---|---|---|---|---|---|
Mar. 31, 2025  | 
Mar. 31, 2024  | 
Mar. 31, 2025  | 
Mar. 31, 2024  | 
Jun. 30, 2024  | 
|
| Stock-based compensation expense | |||||
| Total stock-based compensation expense | $ 70,201 | $ 56,682 | $ 193,742 | $ 154,074 | |
| Stock-based compensation capitalized as inventory | 25,700 | 25,700 | $ 21,500 | ||
| Costs of revenues | |||||
| Stock-based compensation expense | |||||
| Total stock-based compensation expense | 12,875 | 9,803 | 33,133 | 25,554 | |
| R&D | |||||
| Stock-based compensation expense | |||||
| Total stock-based compensation expense | 20,726 | 16,430 | 55,151 | 42,211 | |
| SG&A | |||||
| Stock-based compensation expense | |||||
| Total stock-based compensation expense | $ 36,600 | $ 30,449 | $ 105,458 | $ 86,309 | |
| X | ||||||||||
- Definition Stock Based Compensation Capitalized As Inventory No definition available. 
  | 
| X | ||||||||||
- Definition Amount of expense for award under share-based payment arrangement. Excludes amount capitalized. Reference 1: http://www.xbrl.org/2003/role/disclosureRef 
  | 
| X | ||||||||||
- Definition Line items represent financial concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes to the table. No definition available. 
  | 
| X | ||||||||||
- Details 
  | 
| X | ||||||||||
- Details 
  | 
| X | ||||||||||
- Details 
  |