How can I manage to create it? I mean, each card has its rarity: a legendary card is hard to find, so you have a low chance to open a pack with it. How can I simulate these percentages? Example: common cards 60% of chance to find (give item) this card.
Rare card 20% etc...
Like Andar said, it can all be done with random numbers, conditional branches, and clever use of Show Picture. I would set up the eventing by first choosing a rarity (e.g. if number is between 1 and 5 give legendary, 6 to 15 rare, 16 to 30 uncommon, 31 to 100 common), and then within each rarity you could have a second, evenly distributed random number to choose which card of that rarity to award.
In the long run - especially if you're planning to do more complex stuff like allowing re-rolls or filling out a collection of all cards that have been obtained - you will want to move onto JavaScript programming to do this. It will save you a lot of time and make it easier to scale when you start adding in more features.