Your landlord can use the security deposit to pay for the cost of cleaning left undone, repair damages caused by you or your roommates, and any additional fees, outstanding rent, and unpaid utilities. If your deposit is not sufficient to cover these costs, your landlord can sue you in small claims court to recover the balance.
MSU's Student Legal Services program is managed by the Associated Students of Montana State University (ASMSU). Please thank your student government for prioritizing legal services for MSU students!