The most important thing to understand about online slots is that the visual animation of the reels spinning is purely for entertainment. In reality, the outcome of your spin is decided the exact millisecond you press the spin button. This is handled by a system called the Random Number Generator (RNG).
The RNG is a sophisticated piece of software that generates thousands of numbers every second, even when no one is playing. When you initiate a spin, the game picks the current number from the sequence and maps it to a specific combination of symbols on the reels. This ensures that every single spin is an independent event. This means the game does not "remember" that you just had a win or a loss; the odds of the next spin are exactly the same as they were for the previous one, regardless of what happened before.