Hi Banks,
I suggest you watching this video on electron orbitals (electron hybridization) to get a better understanding of energy levels in the atom. Electron configuration depends on the number of orbitals, determining the number of so-called electron shells. The number of electron shells is determined by the given period number. Valence only shows how many electrons are on the outer shell, or more precisely, on the outer orbital of the atom, determining how many electrons the atom can give over to an oxidant in a chemical reaction.
As another member has already mentioned, chemical elements are categorized into blocks, based on the shape of their outer orbital, namely there are s, p, d and f elements. Orbital shapes are as follows: s, p, d, and f. Now imagine a x, y and z coordinates as in a 3-dimensional space. Each orbital carries sub-orbitals; the s- orbital is alone, there are 3 p-orbitals respectively residing on the x, y, and z coordinates; there are 5 d-orbitals... and so on (Do watch the video for a graphic representation). The number before the symbol for the corresponding orbital shape, say, 1s, determines the number of the electron shell, in this instance it is 1. (will provide with an example below). For example, on the 1st electron shell, the maximum allowed number of electrons is 2, and the first electron shell consists of only one orbital - a spherical s orbital, which itself can accumulate only 2 electrons (note that the two electrons form A PAIR, and a pair is formed with TWO electrons of opposite direction! if the number of electrons doesn't divide evenly by the number of sub-orbitals in an orbital, then the uneven electrons have higher energy and are alone one one orbital. They have higher energy because a stabile state would be that of 2 maximum electrons on a sub-orbital); On the 2nd electron shell, the maximum allowed number of electrons is 8, however, the number of orbitals (!) (or the shape of electron movement), will be different.
With each electron shell, the number of orbitals increases by 2.
Each orbital has their own level of energy (which is responsible for formation of the orbitals).
Energy increases in the following order, which is also the order of electronic fulfillment (which orbital 'carries' the next electrons): 1s < 2s < 2p < 3s < 3p < 4s < 3d < 4p < 5s < 4d < 5p...
Now, with each electron shell, a new orbital adds up. With the first electron shell, there is just only one, s-orbital; with the second electron shell, there's already an s and a p orbital.
Let us take Barium for an example.
Barium is an s-element, because the last of his orbitals is the s-orbital of the 6th electron shell.
Barium's atomic charge is +56, so the number of electrons is also 56 which makes the atom neutral.
Barium's electron position per energy levels is 2) 8) 18) 18) 8) 2) - with 2 electrons on the first electron shell, 8 on the 2nd, etc...
Electron configuration for barium:
1s22s2p63s2p6d104s2p6d105s2p66s2 (the last orbital shows that barium is an s-element)
I will return tomorrow to explain this further if needed.
Element's reactivity depends on the activity of the element. An element is more active than another element if its atomic radius (distance from the atomic nucleus to the last electron orbital) is bigger than the other element's. Why does it show that the element is more active? Because the bigger the radius, the less energy the last orbital will carry, and so it will be easier for the atom to give over electrons than receive because the electromagnetic force is weaker.