layout: Implement a subset of CSS linear gradients per the CSS-IMAGES specification.

This implements a subset of the CSS `linear-gradient` property per the
CSS-IMAGES specification:

    http://dev.w3.org/csswg/css-images-3/

The full syntax is parsed, but only the beginning and end color stops
are used, and gradients are clamped to the nearest 90 degrees. It should
not be architecturally difficult to add the remaining pieces, but in the
interests of bounding the size of this patch that work has been left to
follow-ups.

Improves GitHub.

r? @glennw
Taking the modulo seems to be a no-op if you’re only gonna use the angle with `sin()` and `cos()`.