Cougars beat Scarlets to claim spot in state baseball tournament