Fair Value Measurements - Schedule of Fair Value of Assets Measured on Recurring Basis (Details) - USD ($) $ in Thousands | Sep. 30, 2023 | Dec. 31, 2022 |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | $ 819,177 | |
Total assets at fair value | 1,088,238 | $ 979,735 |
U.S. treasuries | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 302,721 | 79,517 |
Corporate bonds | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 516,456 | 557,591 |
Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Total assets at fair value | 1,054,541 | 928,084 |
Total liabilities at fair value | 156,532 | 193,439 |
Fair Value, Recurring | 2027 Notes | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
2027 Notes | 156,532 | 193,439 |
Fair Value, Recurring | U.S. treasuries | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 302,721 | 79,517 |
Fair Value, Recurring | Corporate bonds | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 516,456 | 557,591 |
Level 1 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Total assets at fair value | 538,085 | 370,493 |
Total liabilities at fair value | 0 | 0 |
Level 1 | Fair Value, Recurring | 2027 Notes | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
2027 Notes | 0 | 0 |
Level 1 | Fair Value, Recurring | U.S. treasuries | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 302,721 | 79,517 |
Level 1 | Fair Value, Recurring | Corporate bonds | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 0 | 0 |
Level 2 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Total assets at fair value | 516,456 | 557,591 |
Total liabilities at fair value | 156,532 | 193,439 |
Level 2 | Fair Value, Recurring | 2027 Notes | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
2027 Notes | 156,532 | 193,439 |
Level 2 | Fair Value, Recurring | U.S. treasuries | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 0 | 0 |
Level 2 | Fair Value, Recurring | Corporate bonds | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 516,456 | 557,591 |
Level 3 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Total assets at fair value | 0 | 0 |
Total liabilities at fair value | 0 | 0 |
Level 3 | Fair Value, Recurring | 2027 Notes | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
2027 Notes | 0 | 0 |
Level 3 | Fair Value, Recurring | U.S. treasuries | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 0 | 0 |
Level 3 | Fair Value, Recurring | Corporate bonds | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Marketable securities, Fair Value | 0 | 0 |
Money market | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | 235,364 | 249,249 |
Money market | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | 235,364 | 249,249 |
Money market | Level 1 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | 235,364 | 249,249 |
Money market | Level 2 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | 0 | 0 |
Money market | Level 3 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | $ 0 | 0 |
Certificates of deposit | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | | 41,727 |
Certificates of deposit | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | | 41,727 |
Certificates of deposit | Level 1 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | | 41,727 |
Certificates of deposit | Level 2 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | | 0 |
Certificates of deposit | Level 3 | Fair Value, Recurring | | |
Fair Value, Assets and Liabilities Measured on Recurring and Nonrecurring Basis [Line Items] | | |
Cash and cash equivalents, fair value | | $ 0 |