v3.24.1.1.u2
Debt - Additional Information (Details) - USD ($)
3 Months Ended
Mar. 15, 2024
Dec. 14, 2023
May 09, 2023
Sep. 17, 2021
Mar. 31, 2024
Mar. 31, 2023
Sep. 27, 2022
Debt Instrument [Line Items]              
Term loans aggregate principal amount         $ 150,000,000    
Three Months Trailing              
Debt Instrument [Line Items]              
Financial covenants, Projected revenue percentage   25.00%     30.00%    
Financial convenants, Projected revenue   $ 120,000,000          
Loan Agreement              
Debt Instrument [Line Items]              
Financial convenants, Minimum cash convenant   20.00%          
Debt instrument, final payment fee or end of term charge   $ 9,700,000          
Minimum market capitalization amount   $ 900,000,000          
Percentage of debt funded to be issued as warrants to purchase common stock   2.50%          
Warrants exercise price   $ 33.43          
Warrants expire term   7 years          
Fair value of warrants   $ 1,300,000          
Debt issuance costs   $ 3,500,000          
Loan Agreement | Common Stock              
Debt Instrument [Line Items]              
Warrants issued to purchase shares   74,782          
Loan Agreement | Maximum              
Debt Instrument [Line Items]              
Warrants exercise price   $ 11.6783          
Loan Agreement | Term Loan              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   $ 200,000,000   $ 200,000,000      
Debt instrument, maturity date       Dec. 01, 2027      
Debt instrument, basis spread on variable rate   3.00%          
Debt instrument, interest rate   9.85%          
Debt instrument, Amendment fee   $ 250,000          
Debt instrument, final payment fee or end of term charge   1,000,000          
Loan Agreement | Term Loan | Maximum              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   $ 300,000,000          
Loan Agreement | Term Loan | Minimum              
Debt Instrument [Line Items]              
Debt instrument, interest rate   5.50%          
Loan Agreement | Term Loan | Floor Rate              
Debt Instrument [Line Items]              
Debt instrument, basis spread on variable rate   9.85%          
Debt instrument, interest rate   10.75%          
Loan Agreement | Term Loan | Floor Rate | Maximum              
Debt Instrument [Line Items]              
Debt instrument, interest rate   10.35%          
Loan Agreement | Term Loan | Prime Rate              
Debt Instrument [Line Items]              
Debt instrument, basis spread on variable rate   1.35%          
Loan Agreement | Term Loan | Prime Rate | Maximum              
Debt Instrument [Line Items]              
Debt instrument, basis spread on variable rate   9.85%          
Loan Agreement | Term Loan | Prime Rate | Minimum              
Debt Instrument [Line Items]              
Debt instrument, basis spread on variable rate   2.25%          
Loan Agreement | Term Loan | Payment In Kind PIK Interest Rate              
Debt Instrument [Line Items]              
Debt instrument, interest rate   2.15%          
Loan Agreement | Term Loan | Payment In Kind PIK Interest Rate | Maximum              
Debt Instrument [Line Items]              
Debt instrument, interest rate   2.15%          
Loan Agreement | Term Loan | Payment In Kind PIK Interest Rate | Minimum              
Debt Instrument [Line Items]              
Debt instrument, interest rate   3.35%          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches One              
Debt Instrument [Line Items]              
Term loans aggregate principal amount       $ 100,000,000      
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Two              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   $ 50,000,000   50,000,000      
Proceeds from remaining line of credit $ 10,000,000            
Loan Agreement | Term Loans, Aggregate Principal Funded Amount Tranches Two              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   40,000,000          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Three              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   25,000,000          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Four              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   25,000,000          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Five              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   50,000,000          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Six              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   $ 50,000,000          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Six | Maximum              
Debt Instrument [Line Items]              
Percentage of cash interest upon achieving milestone   9.50%          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Six | Minimum              
Debt Instrument [Line Items]              
Percentage of cash interest upon achieving milestone   0.35%          
Loan Agreement | Term Loans, Aggregate Principal Amount Tranches Three and Four              
Debt Instrument [Line Items]              
Term loans aggregate principal amount       $ 50,000,000      
Loan Agreement | Term Loans Aggregate Five Additional Tranches              
Debt Instrument [Line Items]              
Term loans aggregate principal amount   $ 200,000,000          
Loan Agreement | Term Loan Advance              
Debt Instrument [Line Items]              
Debt instrument, final payment fee percentage   7.50%          
Debt instrument, final payment fee or end of term charge         $ 7,500,000    
Loan Agreement | Term Loan Second Advance              
Debt Instrument [Line Items]              
Debt instrument, final payment fee or end of term charge         2,200,000    
Loan Agreement | Term Loan Advance Prepayment Prior to October 1, 2026 | Maximum              
Debt Instrument [Line Items]              
Debt instrument, prepayment fee percentage of outstanding principal amount   1.25%          
Loan Agreement | Term Loan Advance Prepayment on or after October 1, 2026              
Debt Instrument [Line Items]              
Debt instrument, prepayment fee percentage of outstanding principal amount   0.50%          
Loan Agreement | Prior to Three Months Trailing              
Debt Instrument [Line Items]              
Financial covenants, Projected revenue percentage   35.00%          
Trailing Net Product Revenue, Period   3 months          
Loan Agreement | Prior to Three Months Trailing | Maximum              
Debt Instrument [Line Items]              
Financial covenants, Projected revenue percentage   50.00%          
Financial convenants, Projected revenue   $ 35,000,000          
Loan Agreement | Three Months Trailing              
Debt Instrument [Line Items]              
Trailing Net Product Revenue, Period   3 months          
Hercules Term Loan              
Debt Instrument [Line Items]              
Term loans aggregate principal amount         158,900,000    
Accrued interest         1,300,000    
Hercules Loan Agreement              
Debt Instrument [Line Items]              
Interest expense         $ 5,000,000 $ 4,000,000  
Amendment to Loan Agreement              
Debt Instrument [Line Items]              
Term loans aggregate principal amount             $ 50,000,000
Tranche extension amendment fee     $ 150,000        
Covenant extension amendment fee     $ 100,000