Its not over until its over.
She basically sent you one txt and you are done?
Ive had same situation, even a bit worse. In short:
Me: i like you
Her: i like you too, but as a friend, ljbf, can you do that
Me: yea no problem
We hanged out a lot, had the best time with this girl.
That was the reason i decided not to give up. I acted normal, she tried to bring my "i love you" txt up (today i know she only wanted me to say it in person, afc as i was i did it over txt, facepalm

) but i didnt bite. Anyways, this was the first meeting and she actually started kinoing me more and i was like "i just fucked things up with my best friend" but all she was doing was trying to get me to make the move.
Long story short, we kissed few weeks later and even right before that she gave me te ljbf speech. I was like yea im down with that 100% and kissed her few minutes later. But i felt NOTHING (which was kind of weird as i could imagine living happily ever after with her)and from then we are best friends (not sure if she feels the same or did i just fz her.)
Why am i sayin you my story.
When a woman says ljbf there is a good possibility that she doesnt really mean that OR you are doing something wrong- usually not enough kino.
So my advice to you- as in my story, agree that you also think it's better to remain only friends because she is too good of a friend for you and you have too much fun with her to ruin it all just because of sex - women love that line, you show you have other options, at the same time appearing not needy and showing you value friendship more than sex.
Then, just be a fun person to be around, go out of her house when its fun and not when she can't wait for you to get out. Escalate, and if she still hangs out with you, you are good to go.
Do you care to tell more what happened when you "stayed longer than wanted?"
Maybe that day is your problem.