Applying CSS to the HTML5 Canvas
CSS can be applied to the HTML5 canvas and you can do pretty much same things with canvas as with images and other standard html elements. You can set canvas borders, margins, and other attributes.
There exists inheritance between content of the canvas and canvas itself. Good example of this inheritance is font. CSS font of the canvas is inherited by text.