Condensed Consolidated Statements of Changes in Redeemable Common Stock and Stockholders' Equity (Deficit) (Unaudited) - USD ($) $ in Thousands | Total | Series A Common Stock | Series B Common Stock | Conversion of Redeemable Common Stock | Common Stock Series A Common Stock | Common Stock Series B Common Stock | Common Stock Conversion of Redeemable Common Stock Series A Common Stock | Common Stock Conversion of Redeemable Common Stock Series B Common Stock | Additional Paid-In Capital | Accumulated Deficit |
Beginning balance (in shares) at Dec. 31, 2022 | 64,046,223 | | | | | | | | | |
Beginning balance at Dec. 31, 2022 | $ 1,531,853 | | | | | | | | | |
Redeemable Common Stock | | | | | | | | | | |
Accretion of redeemable common stock to redemption value | $ 93,972 | | | | | | | | | |
Ending balance (in shares) at Jun. 30, 2023 | 64,046,223 | | | | | | | | | |
Ending balance at Jun. 30, 2023 | $ 1,625,825 | | | | | | | | | |
Beginning balance (in shares) at Dec. 31, 2022 | | | | | 0 | 170,855,313 | | | | |
Beginning balance at Dec. 31, 2022 | (1,036,183) | | | | $ 0 | $ 171 | | | $ 1,249,065 | $ (2,285,419) |
Increase (Decrease) in Stockholders' Equity [Roll Forward] | | | | | | | | | | |
Issuance of common stock upon exercise of common stock options (in shares) | | | | | | 1,135,482 | | | | |
Issuance of common stock upon exercise of common stock options | 2,341 | | | | | $ 1 | | | 2,340 | |
Accretion of redeemable common stock to redemption value | (93,972) | | | | | | | | (93,972) | |
Issuance of common stock upon exercise of collaboration agreement warrants (in shares) | | | | | | 1,180,742 | | | | |
Issuance of common stock upon exercise of collaboration agreement warrants | 12 | | | | | $ 1 | | | 11 | |
Vested warrants related to collaboration agreement | 27,770 | | | | | | | | 27,770 | |
Stock-based compensation expense | 2,342 | | | | | | | | 2,342 | |
Vesting of restricted stock common stock (in shares) | | | | | | 17,863 | | | | |
Vesting of restricted common stock | 50 | | | | | | | | 50 | |
Vesting of restricted stock units (in shares) | | | | | | 33,333 | | | | |
Vesting of restricted stock units | 0 | | | | | | | | | |
Net (loss) income | 15,165 | | | | | | | | | |
Ending balance (in shares) at Jun. 30, 2023 | | | | | 0 | 173,222,733 | | | | |
Ending balance at Jun. 30, 2023 | $ (1,082,475) | | | | $ 0 | $ 173 | | | 1,187,606 | (2,270,254) |
Beginning balance (in shares) at Mar. 31, 2023 | 64,046,223 | | | | | | | | | |
Beginning balance at Mar. 31, 2023 | $ 1,567,856 | | | | | | | | | |
Redeemable Common Stock | | | | | | | | | | |
Accretion of redeemable common stock to redemption value | $ 57,969 | | | | | | | | | |
Ending balance (in shares) at Jun. 30, 2023 | 64,046,223 | | | | | | | | | |
Ending balance at Jun. 30, 2023 | $ 1,625,825 | | | | | | | | | |
Beginning balance (in shares) at Mar. 31, 2023 | | | | | 0 | 171,791,662 | | | | |
Beginning balance at Mar. 31, 2023 | (1,051,828) | | | | $ 0 | $ 172 | | | 1,229,141 | (2,281,141) |
Increase (Decrease) in Stockholders' Equity [Roll Forward] | | | | | | | | | | |
Issuance of common stock upon exercise of common stock options (in shares) | | | | | | 831,772 | | | | |
Issuance of common stock upon exercise of common stock options | 2,000 | | | | | $ 1 | | | 1,999 | |
Accretion of redeemable common stock to redemption value | (57,969) | | | | | | | | (57,969) | |
Issuance of common stock upon exercise of collaboration agreement warrants (in shares) | | | | | | 590,368 | | | | |
Issuance of common stock upon exercise of collaboration agreement warrants | 6 | | | | | | | | 6 | |
Vested warrants related to collaboration agreement | 13,885 | | | | | | | | 13,885 | |
Stock-based compensation expense | 519 | | | | | | | | 519 | |
Vesting of restricted stock common stock (in shares) | | | | | | 8,931 | | | | |
Vesting of restricted common stock | 25 | | | | | | | | 25 | |
Net (loss) income | 10,887 | | | | | | | | | |
Ending balance (in shares) at Jun. 30, 2023 | | | | | 0 | 173,222,733 | | | | |
Ending balance at Jun. 30, 2023 | $ (1,082,475) | | | | $ 0 | $ 173 | | | 1,187,606 | (2,270,254) |
Beginning balance (in shares) at Dec. 31, 2023 | 0 | | | | | | | | | |
Beginning balance at Dec. 31, 2023 | $ 0 | | | | | | | | | |
Ending balance (in shares) at Jun. 30, 2024 | 0 | | | | | | | | | |
Ending balance at Jun. 30, 2024 | $ 0 | | | | | | | | | |
Beginning balance (in shares) at Dec. 31, 2023 | | 40,841,834 | 218,524,009 | | 40,841,834 | 218,524,009 | | | | |
Beginning balance at Dec. 31, 2023 | 914,777 | | | | $ 41 | $ 219 | | | 1,713,560 | (799,043) |
Increase (Decrease) in Stockholders' Equity [Roll Forward] | | | | | | | | | | |
Issuance of common stock upon exercise of common stock options (in shares) | | | | | | 4,384,377 | | | | |
Issuance of common stock upon exercise of common stock options | 4,677 | | | | | $ 4 | | | 4,673 | |
Issuance of common stock upon vesting of restricted stock units (in shares) | | | | | 322,527 | 2,100,174 | | | | |
Issuance of common stock upon vesting of restricted stock units | 0 | | | | $ 1 | $ 2 | | | (3) | |
Issuance of common stock upon exercise of collaboration agreement warrants (in shares) | | | | | | 688,763 | | | | |
Issuance of common stock upon exercise of collaboration agreement warrants | 7 | | | | | | | | 7 | |
Issuance of common stock under the employee stock purchase plan (in shares) | | | | | 206,156 | | | | | |
Issuance of common stock under the employee stock purchase plan | 4,362 | | | | | | | | 4,362 | |
Vested warrants related to collaboration agreement | 16,200 | | | | | | | | 16,200 | |
Stock-based compensation expense | 71,070 | | | | | | | | 71,070 | |
Tax withholdings on settlement of stock-based awards (in shares) | | | | | (43,185) | (432,888) | | | | |
Tax withholdings on settlement of stock-based awards | (13,769) | | | | | | | | (13,769) | |
Conversion of common stock (in shares) | | | | | | | 31,183,406 | (31,183,406) | | |
Conversion of common stock | | | | $ 0 | | | $ 31 | $ (31) | | |
Net (loss) income | (17,824) | | | | | | | | | (17,824) |
Ending balance (in shares) at Jun. 30, 2024 | | 72,510,738 | 194,081,029 | | 72,510,738 | 194,081,029 | | | | |
Ending balance at Jun. 30, 2024 | $ 979,500 | | | | $ 73 | $ 194 | | | 1,796,100 | (816,867) |
Beginning balance (in shares) at Mar. 31, 2024 | 0 | | | | | | | | | |
Beginning balance at Mar. 31, 2024 | $ 0 | | | | | | | | | |
Ending balance (in shares) at Jun. 30, 2024 | 0 | | | | | | | | | |
Ending balance at Jun. 30, 2024 | $ 0 | | | | | | | | | |
Beginning balance (in shares) at Mar. 31, 2024 | | | | | 70,065,833 | 193,969,875 | | | | |
Beginning balance at Mar. 31, 2024 | 937,452 | | | | $ 70 | $ 194 | | | 1,749,113 | (811,925) |
Increase (Decrease) in Stockholders' Equity [Roll Forward] | | | | | | | | | | |
Issuance of common stock upon exercise of common stock options (in shares) | | | | | | 669,295 | | | | |
Issuance of common stock upon exercise of common stock options | 1,113 | | | | | $ 1 | | | 1,112 | |
Issuance of common stock upon vesting of restricted stock units (in shares) | | | | | 286,854 | 1,126,186 | | | | |
Issuance of common stock upon vesting of restricted stock units | 0 | | | | $ 1 | $ 1 | | | (2) | |
Issuance of common stock upon exercise of collaboration agreement warrants (in shares) | | | | | | 344,381 | | | | |
Issuance of common stock upon exercise of collaboration agreement warrants | 3 | | | | | | | | 3 | |
Issuance of common stock under the employee stock purchase plan (in shares) | | | | | 206,156 | | | | | |
Issuance of common stock under the employee stock purchase plan | 4,362 | | | | | | | | 4,362 | |
Vested warrants related to collaboration agreement | 8,100 | | | | | | | | 8,100 | |
Stock-based compensation expense | 35,316 | | | | | | | | 35,316 | |
Tax withholdings on settlement of stock-based awards (in shares) | | | | | (28,017) | (48,796) | | | | |
Tax withholdings on settlement of stock-based awards | (1,904) | | | | | | | | (1,904) | |
Conversion of common stock (in shares) | | | | | | | 1,979,912 | (1,979,912) | | |
Conversion of common stock | | | | $ 0 | | | $ 2 | $ (2) | | |
Net (loss) income | (4,942) | | | | | | | | | (4,942) |
Ending balance (in shares) at Jun. 30, 2024 | | 72,510,738 | 194,081,029 | | 72,510,738 | 194,081,029 | | | | |
Ending balance at Jun. 30, 2024 | $ 979,500 | | | | $ 73 | $ 194 | | | $ 1,796,100 | $ (816,867) |