Like any good accounting system, cryptocurrency involves a series of transactions between accounts. In other words you add or subtract a number from the original number. The goal is to do this accurately, in a manner such that once the transaction has been entered it cannot be changed -- only new transactions can be added.
The mechanism used for encryption is called hashing. Any sequence of bits can be used to generate a single 256-bit number (or whatever length is desired) which is mathematically related to that sequence. Any peer can check whether this number matches by regenerating it from the same starting conditions. This makes it practically impossible to fake a transaction.
Bitcoin also has a mechanism to prevent inflation -- no currency can possibly be added without the approval of all peers (i.e. other bitcoin clients), and they are all programmed to only add currency under strict mathematical conditions. Specifically, where a transaction hash is discovered that is below a certain predetermined target value. The lower the value the harder it will be to find, and the clients all .
Originally, the idea was that everyone would contribute CPU time to discovering these unique hashes while simultaneously encrypting account histories. However, someone discovered that you can get a lot more bang for your buck using a the GPU (graphical processing unit) of a graphics card. The reason for this is because they let you attempt many hashes in parallel instead of one after another.
However not all graphics cards are created equal. My computer has an NVIDIA 9500 card, and gets about 5494 khash/s. This might sound like a lot of hashes (and is far faster than a CPU), but it takes 235 days, 5 hours, 38 minutes to find one matching hash at the current difficulty rate. For my trouble, the peers are programmed to grant me 50 additional bitcoins (a number that will drop over time, being cut in half every 4 years). A more powerful card is the Radeon ATi 5970 with dual Cypress XT GPU chips. This insanely overpowered gaming device costs about $600 and can solve a block in about 2 days!