This change tweaks the CSS to apply most of its styles to `.sidebar h2`,
cleaning up a few redundant rules from `.mobile-topbar .location` and
restoring useful navigation aids in mobile mode.
The W3C Web Content Accessibility Guidelines specify a minimum line
spacing of 1.5 and a minimum paragraph spacing of 1.5 times the line
spacing. Our current line spacing (implemented by line-height) is 1.4,
so it's a small bump to go up to 1.5. Similarly, we have a paragraph
spacing of 0.6em. Bump that to 0.75em (which is 1.5 times the 0.5em
distance between lines).
Also, fix all the font sizes so instead of being round-ish numbers in
rem (like 1.1rem, 1.2rem), they are round numbers in pixels. Ensure each
font size is at least 2 pixels different than the nearest other font
size, so distinctions can be clearly seen. Overall the font-sizes are
mostly staying the same, being rounded up or down as appropriate.
Remove a few unused styles.
Simplify the display of the mobile-topbar location, by setting its
margins to auto rather than trying to size it exactly to the topbar.
The dark and ayu themes have a menu-like highlight on sidebar items. The
light theme used to, but it was accidentally lost in the sidebar
unification. The change brings back the hover effect in the light theme.
It also makes the hover effect apply consistently to all links in the
sidebar, including headings.
It also simplifies the "In _path_" heading so it's one big link. The
breadcrumbs are still readily available at the top of the page.
We already have overflow: hidden on these links, but if there is a
possibility to wrap, they will wrap. This happens in particular for trait
implementations because the punctuation (`<>, `) introduces opportunities
for breaks. That produces inconsistent UI. Fix it by forcing them not to
wrap.
This switches to just use size, weight, and spacing to distinguish
headings in the sidebar. We no longer use boxes, horizontal bars, or
centering to distinguish headings. This makes it much easier to
understand the hierarchy of headings, and reduces visual noise.
I also refactored how the mobile topbar works. Previously, we tried to
shift around elements from the sidebar to make the topbar. Now, the
topbar gets its own elements, which can be styled on their own. This
makes styling and reasoning about those elements simpler.
Because the heading font sizes are bigger, increase the sidebar width
slightly.
As a very minor change, removed version from the "All types" page. It's
now only on the crate page.