/*
 * Print styles.
 *
 * A student printing a molar mass page wants the compound, the number and the
 * working. Everything else is furniture.
 *
 * EVERY HIDE RULE IS THREE CLASSES DEEP. The screen sheet's rules sit at
 * `body.mm-page .mm .mm-form`, specificity (0,3,0), and are served on
 * `media="all"`. A print rule written as `.mm-form { display: none }` is
 * (0,1,0) and loses -- it never applies, and the page prints with a live input
 * box and a Calculate button on it. The sibling plugin shipped a worksheet with
 * a mode switcher printed on it for exactly this reason, so the rule here is to
 * match the screen sheet's depth rather than to assume `@media print` wins.
 */

@media print {
	body.mm-page .mm .mm-form,
	body.mm-page .mm .mm-hint,
	body.mm-page .mm .mm-error,
	body.mm-page .mm .mm-convert {
		display: none;
	}

	body.mm-page .mm {
		font-size: 11pt;
	}

	body.mm-page .mm .mm-answer {
		font-size: 13pt;
		margin-bottom: 0.6rem;
	}

	/* The floor exists to stop the screen layout jumping; on paper it would
	 * just be a page of white space. */
	body.mm-page .mm .mm-result {
		min-height: 0;
	}

	/* The narrow-screen rule turns the table into a scrolling block, which on
	 * paper clips every column past the edge of the sheet. */
	body.mm-page .mm .mm-table {
		display: table;
		overflow: visible;
		white-space: normal;
		page-break-inside: avoid;
	}

	body.mm-page .mm .mm-table th,
	body.mm-page .mm .mm-table td {
		border-bottom: 1px solid #999;
	}

	body.mm-page .mm .mm-sum {
		background: none;
		border: 1px solid #999;
		page-break-inside: avoid;
	}

	body.mm-page .mm .mm-caveat {
		opacity: 1;
		font-size: 9pt;
	}
}
