/*
 * Multiplication Chart pages. Every rule starts with `body.mtc-page`.
 *
 * ruki-child styles `.t33-page-main .entry-content a`, `h1..h6`, `ul/ol/li`,
 * `img` (border-radius 14px), `table`, `td` (display:block at 390px), `button`
 * and `fieldset` at (0,2,1)-(0,3,1), which beat a bare class and would render
 * this page's text in the theme's link and heading styles. Rules here reach
 * (0,3,x) or deeper and name the element where the theme styles that element.
 * No `!important` outside the print block at the end, no url() (Autoptimize
 * aggregates this file and relative paths break), no <code>.
 *
 * Roots: every block has `.mtc-r`; blocks after the first are `.mtc-b`. The
 * generator is `.mtc` (the shell's lift root, `.entry-content > .mtc:first-child`,
 * specificity (0,5,1): put [mtc_tool] first in the page content and it is lifted
 * over the hero band). Anything that must override the lift (the border colour
 * below, the print reset) is written at exactly that specificity and placed after
 * the shell block.
 *
 * The shell block in the middle of this file is generated by
 * _shared/sync-shell.js; the rules after it are this page's overrides.
 */

body.mtc-page {
	--mtc-ink: var(--t33-ink, #1b2233);
	--mtc-soft: #4a5368;
	--mtc-line: #e3e7ef;
	--mtc-line-strong: #c4cde0;
	--mtc-panel: #f5f8fc;
	--mtc-teal: #0a7e9c;
	--mtc-teal-dark: #086680;
	--mtc-teal-soft: #e7f6fa;
	--mtc-coral: #b3261e;
	--mtc-navy: #26365f;
	--mtc-radius: var(--t33-radius, 14px);
}

body.mtc-page .entry-content .mtc-r {
	box-sizing: border-box;
	max-width: 100%;
	margin-left: 0;
	margin-right: 0;
}

body.mtc-page .entry-content .mtc-r *,
body.mtc-page .entry-content .mtc-r *::before,
body.mtc-page .entry-content .mtc-r *::after {
	box-sizing: border-box;
}

body.mtc-page .entry-content .mtc-r.mtc-b {
	margin-bottom: 2em;
}

body.mtc-page .entry-content .mtc-r [hidden][hidden] {
	display: none;
}

body.mtc-page .entry-content .mtc-r p {
	margin: 0;
	padding: 0;
}

body.mtc-page .entry-content .mtc-r .mtc-sr {
	clip: rect(0 0 0 0);
	height: 1px;
	overflow: hidden;
	position: absolute;
	white-space: nowrap;
	width: 1px;
}

body.mtc-page .entry-content .mtc-r button:focus-visible,
body.mtc-page .entry-content .mtc-r a:focus-visible,
body.mtc-page .entry-content .mtc-r .mtc-in:focus-visible,
body.mtc-page .entry-content .mtc-r .mtc-sel:focus-visible,
body.mtc-page .entry-content .mtc-r .mtc-box:focus-visible,
body.mtc-page .entry-content .mtc-r .mtc-tw:focus-visible,
body.mtc-page .entry-content .mtc-r .mtc-chip input:focus-visible {
	outline: 3px solid var(--t33-cyan, #2bc8e8);
	outline-offset: 2px;
}

/* ------------------------------------------------------- the generator --- */

body.mtc-page .entry-content .mtc-r.mtc-tool {
	display: grid;
	gap: 22px;
	grid-template-columns: minmax(0, 1fr);
	align-items: start;
	margin-bottom: 2em;
	padding: 20px;
	background: var(--t33-paper, #fff);
	border: 1px solid var(--mtc-line);
	border-radius: var(--mtc-radius);
}

body.mtc-page .entry-content .mtc-r .mtc-view {
	min-width: 0;
}

body.mtc-page .entry-content .mtc-r .mtc-viewbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 12px;
	min-height: 44px;
	margin-bottom: 10px;
}

body.mtc-page .entry-content .mtc-r .mtc-pager {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

body.mtc-page .entry-content .mtc-r .mtc-pg-t {
	font-size: 0.9rem;
	font-weight: 700;
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r button.mtc-pg {
	appearance: none;
	min-width: 40px;
	height: 40px;
	margin: 0;
	padding: 0 12px;
	border: 1px solid var(--mtc-line-strong);
	border-radius: 8px;
	background: #fff;
	box-shadow: none;
	color: var(--mtc-ink);
	font: inherit;
	font-size: 1.1rem;
	line-height: 1;
	cursor: pointer;
}

body.mtc-page .entry-content .mtc-r button.mtc-pg:disabled {
	opacity: 0.4;
	cursor: default;
}

/* The box scrolls sideways when a wide chart would make its cells unreadable. */
body.mtc-page .entry-content .mtc-r .mtc-box {
	max-width: 100%;
	padding: 12px;
	overflow: auto;
	background: #e9edf5;
	border: 1px solid var(--mtc-line);
	border-radius: 10px;
}

body.mtc-page .entry-content .mtc-r .mtc-stage {
	width: min(100%, calc(min(78vh, 800px) * var(--mtc-ar, 0.7727)));
	aspect-ratio: var(--mtc-ar, 0.7727);
	margin: 0 auto;
	background: #fff;
	box-shadow: 0 0 0 1px rgba(7, 11, 26, 0.14), 0 8px 22px rgba(7, 11, 26, 0.16);
}

body.mtc-page .entry-content .mtc-r .mtc-stage svg {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	margin: 0;
	border-radius: 0;
	cursor: pointer;
	touch-action: manipulation;
	-webkit-user-select: none;
	user-select: none;
}

body.mtc-page .entry-content .mtc-r .mtc-hover {
	min-height: 1.7em;
	margin-top: 10px;
	font-size: 1rem;
	font-weight: 800;
	font-variant-numeric: tabular-nums;
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r .mtc-note {
	margin-top: 2px;
	font-size: 0.9rem;
	color: var(--mtc-soft);
}

body.mtc-page .entry-content .mtc-r .mtc-err {
	margin-top: 6px;
	font-size: 0.92rem;
	font-weight: 700;
	color: var(--mtc-coral);
}

body.mtc-page .entry-content .mtc-r .mtc-msg {
	min-height: 1.5em;
	margin-top: 8px;
	font-size: 0.9rem;
	color: var(--mtc-soft);
}

body.mtc-page .entry-content .mtc-r .mtc-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 14px;
}

body.mtc-page .entry-content .mtc-r .mtc-actions .mtc-btn-lg {
	flex: 1 1 100%;
}

body.mtc-page .entry-content .mtc-r .mtc-actions .mtc-btn-alt {
	flex: 1 1 120px;
}

/* ------------------------------------------------------------- buttons --- */

body.mtc-page .entry-content .mtc-r .mtc-btn,
body.mtc-page .entry-content .mtc-r .mtc-open {
	display: inline-block;
	appearance: none;
	margin: 0;
	padding: 10px 16px;
	border: 1px solid var(--mtc-teal);
	border-radius: 8px;
	background: var(--mtc-teal);
	box-shadow: none;
	color: #fff;
	font: inherit;
	font-size: 0.95rem;
	font-weight: 800;
	line-height: 1.25;
	letter-spacing: 0;
	text-align: center;
	text-decoration: none;
	text-transform: none;
	cursor: pointer;
}

body.mtc-page .entry-content .mtc-r .mtc-btn:hover,
body.mtc-page .entry-content .mtc-r .mtc-btn:visited {
	background: var(--mtc-teal-dark);
	border-color: var(--mtc-teal-dark);
	color: #fff;
}

body.mtc-page .entry-content .mtc-r .mtc-btn-lg {
	padding: 14px 22px;
	border-radius: 10px;
	font-size: 1.1rem;
}

body.mtc-page .entry-content .mtc-r .mtc-btn-ic {
	display: inline-block;
	margin-right: 8px;
	font-size: 1.1em;
	line-height: 1;
}

body.mtc-page .entry-content .mtc-r .mtc-btn.mtc-btn-alt {
	border-color: var(--mtc-line-strong);
	background: #fff;
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r .mtc-btn.mtc-btn-alt:hover,
body.mtc-page .entry-content .mtc-r .mtc-btn.mtc-btn-alt:visited {
	background: var(--mtc-panel);
	border-color: var(--mtc-teal);
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r .mtc-btn[aria-busy="true"] {
	opacity: 0.7;
	cursor: progress;
}

body.mtc-page .entry-content .mtc-r button.mtc-linkbtn {
	appearance: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	box-shadow: none;
	color: var(--mtc-teal-dark);
	font: inherit;
	font-weight: 700;
	text-decoration: underline;
	text-transform: none;
	cursor: pointer;
}

/* ------------------------------------------------------------ controls --- */

body.mtc-page .entry-content .mtc-r .mtc-controls {
	display: grid;
	gap: 12px;
	min-width: 0;
	margin: 0;
}

body.mtc-page .entry-content .mtc-r fieldset.mtc-fs {
	min-width: 0;
	margin: 0;
	padding: 12px 14px 14px;
	background: var(--mtc-panel);
	border: 1px solid var(--mtc-line);
	border-radius: 12px;
}

body.mtc-page .entry-content .mtc-r fieldset.mtc-fs legend {
	float: none;
	width: auto;
	margin: 0;
	padding: 0 6px 0 0;
}

body.mtc-page .entry-content .mtc-r .mtc-lg,
body.mtc-page .entry-content .mtc-r .mtc-fl,
body.mtc-page .entry-content .mtc-r .mtc-sub,
body.mtc-page .entry-content .mtc-r .mtc-bar-l {
	font-size: 0.78rem;
	font-weight: 800;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--mtc-navy);
}

body.mtc-page .entry-content .mtc-r .mtc-lg {
	font-size: 0.86rem;
}

body.mtc-page .entry-content .mtc-r .mtc-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 8px;
}

body.mtc-page .entry-content .mtc-r .mtc-grp {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0 10px;
}

body.mtc-page .entry-content .mtc-r .mtc-grp .mtc-sub {
	min-width: 6.5em;
	margin-top: 8px;
}

body.mtc-page .entry-content .mtc-r label.mtc-chip,
body.mtc-page .entry-content .mtc-r span.mtc-chip {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 40px;
	margin: 0;
	padding: 7px 13px 7px 11px;
	border: 1px solid var(--mtc-line-strong);
	border-radius: 999px;
	background: #fff;
	color: var(--mtc-ink);
	font-size: 0.92rem;
	font-weight: 700;
	line-height: 1.2;
	cursor: pointer;
}

body.mtc-page .entry-content .mtc-r label.mtc-chip input,
body.mtc-page .entry-content .mtc-r .mtc-tb-l input {
	flex: none;
	width: 16px;
	height: 16px;
	margin: 0;
	accent-color: var(--mtc-teal);
}

body.mtc-page .entry-content .mtc-r label.mtc-chip:has(input:checked) {
	border-color: var(--mtc-teal);
	background: var(--mtc-teal-soft);
}

body.mtc-page .entry-content .mtc-r span.mtc-chip-tb {
	gap: 8px;
	padding: 3px 4px 3px 11px;
	cursor: default;
}

body.mtc-page .entry-content .mtc-r span.mtc-chip-tb:has(input:checked) {
	border-color: var(--mtc-teal);
	background: var(--mtc-teal-soft);
}

body.mtc-page .entry-content .mtc-r .mtc-tb-l {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	cursor: pointer;
}

body.mtc-page .entry-content .mtc-r select.mtc-sel {
	width: auto;
	min-width: 64px;
	height: 32px;
	margin: 0;
	padding: 2px 8px;
	border: 1px solid var(--mtc-line-strong);
	border-radius: 999px;
	background: #fff;
	color: var(--mtc-ink);
	font: inherit;
	font-size: 0.92rem;
	font-weight: 700;
	box-shadow: none;
}

body.mtc-page .entry-content .mtc-r select.mtc-sel:disabled {
	opacity: 0.55;
}

body.mtc-page .entry-content .mtc-r .mtc-sw {
	display: inline-block;
	flex: none;
	width: 26px;
	height: 16px;
	border: 1px solid rgba(7, 11, 26, 0.25);
	border-radius: 3px;
}

body.mtc-page .entry-content .mtc-r .mtc-sw-color {
	background: linear-gradient(to bottom, #c62828 0 25%, #4d7c0f 25% 50%, #0e7490 50% 75%, #7e22ce 75%);
}

body.mtc-page .entry-content .mtc-r .mtc-sw-colorcol {
	background: linear-gradient(to right, #c62828 0 25%, #4d7c0f 25% 50%, #0e7490 50% 75%, #7e22ce 75%);
}

body.mtc-page .entry-content .mtc-r .mtc-sw-pastel {
	background: linear-gradient(to bottom, #f4cfcf 0 25%, #d9e6c8 25% 50%, #cfe3e8 50% 75%, #e3d3f1 75%);
}

body.mtc-page .entry-content .mtc-r .mtc-sw-bw {
	border-color: #000;
	background: linear-gradient(to bottom, #d9d9d9 0 35%, #fff 35%);
}

body.mtc-page .entry-content .mtc-r .mtc-sw-ink {
	background: repeating-linear-gradient(90deg, #bdbdbd 0 1px, #fff 1px 6px);
}

body.mtc-page .entry-content .mtc-r .mtc-custom {
	margin-top: 12px;
	padding-top: 12px;
	border-top: 1px dashed var(--mtc-line-strong);
}

body.mtc-page .entry-content .mtc-r .mtc-pairs {
	display: grid;
	gap: 10px;
}

body.mtc-page .entry-content .mtc-r .mtc-pair {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 8px 10px;
}

body.mtc-page .entry-content .mtc-r label.mtc-num,
body.mtc-page .entry-content .mtc-r label.mtc-f {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
	margin: 0;
	font-size: 0.86rem;
	font-weight: 700;
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r label.mtc-num input.mtc-in {
	width: 92px;
}

body.mtc-page .entry-content .mtc-r label.mtc-f-title {
	margin-top: 12px;
}

body.mtc-page .entry-content .mtc-r .mtc-in {
	display: block;
	width: 100%;
	height: 44px;
	margin: 0;
	padding: 8px 12px;
	border: 1px solid var(--mtc-line-strong);
	border-radius: 8px;
	background: #fff;
	color: var(--mtc-ink);
	font: inherit;
	font-size: 1rem;
	font-weight: 400;
	line-height: 1.3;
	box-shadow: none;
}

body.mtc-page .entry-content .mtc-r .mtc-in[aria-invalid="true"] {
	border-color: var(--mtc-coral);
}

body.mtc-page .entry-content .mtc-r .mtc-small {
	margin-top: 10px;
	font-size: 0.88rem;
	color: var(--mtc-soft);
}

body.mtc-page .entry-content .mtc-r .mtc-grp + .mtc-grp,
body.mtc-page .entry-content .mtc-r .mtc-grp + .mtc-chips {
	margin-top: 4px;
}

/* ------------------------------------------------------------ practice --- */

body.mtc-page .entry-content .mtc-r .mtc-practice {
	margin-top: 12px;
	padding: 14px;
	background: var(--mtc-panel);
	border: 1px solid var(--mtc-line);
	border-radius: 12px;
}

body.mtc-page .entry-content .mtc-r .mtc-q {
	min-height: 1.4em;
	font-size: 1.5rem;
	font-weight: 800;
	font-variant-numeric: tabular-nums;
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r .mtc-ans {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 10px 0 0;
}

body.mtc-page .entry-content .mtc-r .mtc-ans label.mtc-f-ans {
	flex: 1 1 110px;
	max-width: 160px;
}

body.mtc-page .entry-content .mtc-r .mtc-score {
	margin-top: 10px;
	font-size: 0.98rem;
	font-weight: 800;
	color: var(--mtc-navy);
}

body.mtc-page .entry-content .mtc-r .mtc-hint {
	margin-top: 4px;
	font-size: 0.86rem;
	color: var(--mtc-soft);
}

/* ------------------------------------------------------------ downloads --- */

body.mtc-page .entry-content .mtc-r.mtc-dl {
	padding: 20px;
	background: var(--mtc-panel);
	border: 1px solid var(--mtc-line);
	border-radius: var(--mtc-radius);
}

body.mtc-page .entry-content .mtc-r .mtc-bar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 12px;
}

body.mtc-page .entry-content .mtc-r .mtc-seg {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 2px;
	padding: 3px;
	background: #fff;
	border: 1px solid var(--mtc-line);
	border-radius: 999px;
}

body.mtc-page .entry-content .mtc-r button.mtc-seg-btn {
	appearance: none;
	margin: 0;
	padding: 8px 16px;
	border: 0;
	border-radius: 999px;
	background: transparent;
	box-shadow: none;
	color: var(--mtc-soft);
	font: inherit;
	font-size: 0.92rem;
	font-weight: 700;
	line-height: 1.2;
	text-transform: none;
	letter-spacing: 0;
	cursor: pointer;
}

body.mtc-page .entry-content .mtc-r button.mtc-seg-btn:hover {
	color: var(--mtc-ink);
	background: transparent;
}

body.mtc-page .entry-content .mtc-r button.mtc-seg-btn[aria-pressed="true"] {
	background: var(--mtc-ink);
	color: #fff;
}

body.mtc-page .entry-content .mtc-r .mtc-grid {
	display: grid;
	gap: 14px;
	margin-top: 16px;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
}

body.mtc-page .entry-content .mtc-r .mtc-card {
	display: flex;
	flex-direction: column;
	min-width: 0;
	padding: 14px;
	background: #fff;
	border: 1px solid var(--mtc-line);
	border-radius: 12px;
	box-shadow: 0 1px 2px rgba(7, 11, 26, 0.06);
}

/* The frame has the tallest variant's ratio (Letter), so a Letter/A4 swap moves nothing. */
body.mtc-page .entry-content .mtc-r .mtc-thumb {
	position: relative;
	width: 62%;
	margin: 0 auto 12px;
	aspect-ratio: var(--mtc-ar, 480 / 621);
	overflow: hidden;
	background: #fff;
	border-radius: 3px;
	box-shadow: 0 0 0 1px rgba(7, 11, 26, 0.14), 0 5px 12px rgba(7, 11, 26, 0.12);
}

body.mtc-page .entry-content .mtc-r .mtc-thumb img {
	position: absolute;
	top: 0;
	left: 0;
	display: block;
	width: 100%;
	height: 100%;
	margin: 0;
	border-radius: 0;
	object-fit: contain;
	object-position: top center;
}

body.mtc-page .entry-content .mtc-r .mtc-card-body {
	display: flex;
	flex-direction: column;
	min-width: 0;
	flex: 1 1 auto;
}

body.mtc-page .entry-content .mtc-r h3.mtc-card-title {
	margin: 0 0 4px;
	padding: 0;
	font-size: 1.02rem;
	font-weight: 800;
	line-height: 1.25;
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r .mtc-facts {
	margin-bottom: 6px;
	font-size: 0.82rem;
	color: var(--mtc-soft);
}

body.mtc-page .entry-content .mtc-r .mtc-blurb {
	font-size: 0.88rem;
	line-height: 1.5;
	color: var(--mtc-soft);
}

body.mtc-page .entry-content .mtc-r .mtc-card-foot {
	margin-top: 12px;
}

body.mtc-page .entry-content .mtc-r .mtc-actions-s {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

body.mtc-page .entry-content .mtc-r .mtc-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 12px;
	margin-top: 10px;
	padding-top: 10px;
	border-top: 1px dashed var(--mtc-line-strong);
	font-size: 0.86rem;
}

body.mtc-page .entry-content .mtc-r .mtc-keyrow .mtc-row-l {
	color: var(--mtc-coral);
}

body.mtc-page .entry-content .mtc-r .mtc-row-l {
	font-weight: 800;
	color: var(--mtc-navy);
}

body.mtc-page .entry-content .mtc-r a.mtc-link {
	font-weight: 700;
	color: var(--mtc-teal-dark);
}

body.mtc-page .entry-content .mtc-r a.mtc-num-link {
	display: inline-block;
	min-width: 28px;
	padding: 3px 6px;
	border: 1px solid var(--mtc-line-strong);
	border-radius: 6px;
	text-align: center;
	text-decoration: none;
}

body.mtc-page .entry-content .mtc-r .mtc-row-m {
	color: var(--mtc-soft);
}

body.mtc-page .entry-content .mtc-r .mtc-license {
	margin-top: 18px;
	font-size: 0.88rem;
	color: var(--mtc-soft);
}

/* --------------------------------------------------------------- table --- */

body.mtc-page .entry-content .mtc-r.mtc-tw {
	overflow-x: auto;
	border: 1px solid var(--mtc-line);
	border-radius: 12px;
	background: #fff;
}

body.mtc-page .entry-content .mtc-r table.mtc-table {
	width: 100%;
	margin: 0;
	border: 0;
	border-collapse: collapse;
	font-size: 0.92rem;
	line-height: 1.3;
	text-align: center;
	font-variant-numeric: tabular-nums;
}

body.mtc-page .entry-content .mtc-r table.mtc-table caption {
	padding: 10px 12px;
	text-align: left;
	font-size: 0.86rem;
	font-weight: 700;
	color: var(--mtc-soft);
	caption-side: top;
}

/*
 * ruki turns every `.entry-content td` into display:block at max-width 390px (a
 * stacked-table layout). This table scrolls sideways inside .mtc-tw instead, so
 * the cell keeps its table-cell display.
 */
body.mtc-page .entry-content .mtc-r table.mtc-table td {
	display: table-cell;
}

body.mtc-page .entry-content .mtc-r table.mtc-table th,
body.mtc-page .entry-content .mtc-r table.mtc-table td {
	min-width: 2.7em;
	padding: 6px 8px;
	border: 0;
	border-bottom: 1px solid var(--mtc-line);
	text-align: center;
	vertical-align: middle;
	color: var(--mtc-ink);
}

body.mtc-page .entry-content .mtc-r table.mtc-table thead th {
	background: var(--mtc-navy);
	border-bottom: 0;
	color: #fff;
	font-weight: 800;
}

body.mtc-page .entry-content .mtc-r table.mtc-table tbody th {
	background: var(--mtc-teal-soft);
	color: var(--mtc-ink);
	font-weight: 800;
}

body.mtc-page .entry-content .mtc-r table.mtc-table tbody tr:nth-child(even) td {
	background: var(--mtc-panel);
}

body.mtc-page .entry-content .mtc-r table.mtc-table td.mtc-sq {
	background: #fde68a;
	font-weight: 800;
}

/* --------------------------------------------------------------- links --- */

body.mtc-page .entry-content .mtc-r.mtc-links {
	padding: 16px 18px;
	background: var(--mtc-panel);
	border: 1px solid var(--mtc-line);
	border-radius: var(--mtc-radius);
}

body.mtc-page .entry-content .mtc-r .mtc-links-t {
	margin-bottom: 8px;
	font-size: 0.82rem;
	font-weight: 800;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--mtc-navy);
}

body.mtc-page .entry-content .mtc-r ul.mtc-links-l {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 18px;
	margin: 0;
	padding: 0;
	list-style: none;
}

body.mtc-page .entry-content .mtc-r ul.mtc-links-l li {
	margin: 0;
	padding: 0;
}

body.mtc-page .entry-content .mtc-r .mtc-links-now {
	font-weight: 800;
	color: var(--mtc-ink);
}

/* --------------------------------------------------------------- phone --- */

/*
 * The theme's article column is about 730px wide at every desktop width, so two
 * columns means a preview about 350px wide next to the controls. The preview
 * stays in view while the controls scroll when the window is tall enough.
 */
@media (min-width: 1000px) {

	body.mtc-page .entry-content .mtc-r.mtc-tool {
		grid-template-columns: minmax(0, 1.06fr) minmax(0, 1fr);
	}
}

@media (min-width: 1000px) and (min-height: 780px) {

	body.mtc-page .entry-content .mtc-r .mtc-view {
		position: sticky;
		top: 16px;
	}
}

@media (max-width: 600px) {

	body.mtc-page .entry-content .mtc-r.mtc-tool,
	body.mtc-page .entry-content .mtc-r.mtc-dl {
		padding: 12px;
	}

	body.mtc-page .entry-content .mtc-r .mtc-box {
		padding: 8px;
	}

	body.mtc-page .entry-content .mtc-r fieldset.mtc-fs {
		padding: 10px 10px 12px;
	}

	body.mtc-page .entry-content .mtc-r .mtc-card {
		padding: 12px;
	}

	body.mtc-page .entry-content .mtc-r .mtc-grp .mtc-sub {
		min-width: 100%;
		margin-top: 4px;
	}
}

/* >>> t33 tool-page shell v1 (generated - edit _shared/toolpage-shell.css) */

/*
 * Makes the lift the card's own. Without a block formatting context the card's
 * negative margin collapses out through `.entry-content`, `article` and
 * `.t33-page-main` -- none of which has top padding -- and lands on `.wrap`,
 * moving the entire column instead of the one element. Measured on the live
 * page before this line existed: `.wrap` top and card top were both 300px, so
 * the declared -72px was in effect on the wrong element and no gate could see
 * the difference.
 */
body.mtc-page .t33-page-main .entry-content {
	display: flow-root;
}

/*
 * The prose measure. Enumerated by tag rather than written as
 * `> *:not(.mtc)`, which is what the word search shipped first: a
 * :not() selector also narrows MEDIAVINE'S INJECTED CONTAINERS to 760px,
 * quietly shrinking every in-content unit on the page. Ad units, the tool and
 * the tool strip are divs and navs, so enumerating prose tags leaves them at
 * full column width.
 *
 * `:is()` takes the specificity of its heaviest argument -- a type selector,
 * (0,0,1) -- so this lands at (0,3,2) and beats ruki-child's (0,3,1).
 */
body.mtc-page .t33-page-main .entry-content > :is(p, h2, h3, h4, h5, h6, ul, ol, dl, blockquote, figure, pre) {
	max-width: 760px;
	margin-left: auto;
	margin-right: auto;
}

/*
 * Room for the card to land in. The theme ships `padding: 170px 0 90px`; the
 * extra bottom padding here is spent by the lift below, so the title keeps the
 * breathing room it has today and the tool does not move down the page.
 */
body.mtc-page .t33-page-hero {
	padding-bottom: 132px;
}

/*
 * The lift. Mirrors `.t33-article-media`, which is what the theme already does
 * with a featured image on every other page of the site.
 *
 * The hero is a sibling of `.wrap`, not an ancestor, so its `overflow: hidden`
 * cannot clip this; and it carries no `z-index`, so `z-index: 5` here paints
 * over it. Both of those are the theme's own assumptions -- `.t33-article-media`
 * relies on exactly the same two facts.
 *
 * The ring in the first shadow is load-bearing, not decoration. The word
 * search board's background is #070b1a, byte-identical to the band's bottom
 * gradient stop (--t33-navy-1), so without a hairline the lifted panel would
 * dissolve into the band instead of sitting on it.
 *
 * `border-radius` is deliberately NOT set: each tool keeps its own (18px for
 * the board, 10px for the drill card), and the word search flattens it to 0
 * when the board goes full-bleed on a phone.
 *
 * `:first-child` is a safety catch, not tidiness. If Journey ever inserts a
 * unit at the very top of `.entry-content`, the tool stops being the first
 * child and the lift drops -- which is the right failure. Without it the tool
 * would keep its -72px and ride up over the ad unit.
 */
body.mtc-page .t33-page-main .entry-content > .mtc:first-child {
	position: relative;
	z-index: 5;
	margin-top: -72px;
	box-shadow:
		0 0 0 1px rgba(232, 238, 252, 0.18),
		0 26px 60px rgba(7, 11, 26, 0.45);
}

/*
 * The first paragraph after the tool carries the page. It is still a top-level
 * child of `.entry-content` -- only its type scale changed.
 */
body.mtc-page .t33-page-main .entry-content > .mtc + p {
	font-size: 1.18rem;
	line-height: 1.7;
	color: var(--t33-ink-soft, #5a6378);
}

/*
 * Section headings get an accent marker instead of being a bare bold line.
 * `::before` is used rather than a wrapper element precisely because a wrapper
 * would swallow an ad slot.
 */
body.mtc-page .t33-page-main .entry-content > h2 {
	position: relative;
	padding-top: 22px;
	margin-top: 2.4em;
}

body.mtc-page .t33-page-main .entry-content > h2::before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	width: 54px;
	height: 4px;
	border-radius: 999px;
	background: linear-gradient(90deg, var(--t33-cyan, #2bc8e8), var(--t33-coral, #f67280));
}

/*
 * FAQ pairs, styled through an adjacent-sibling selector. A `<details>` or a
 * wrapper would read better in isolation and cost an ad slot per question.
 */
body.mtc-page .t33-page-main .entry-content > h3 {
	margin-top: 1.8em;
	font-size: 1.22rem;
}

body.mtc-page .t33-page-main .entry-content > h3 + p {
	border-left: 3px solid rgba(43, 200, 232, 0.35);
	padding-left: 16px;
	color: var(--t33-ink-soft, #5a6378);
}

/*
 * Opt-in callout, applied to a top-level <p> in the content/*.html articles.
 * content-check.js balances tags and never inspects attributes, so adding a
 * class to those files is safe.
 */
body.mtc-page .t33-page-main .entry-content > p.t33-callout {
	background: var(--t33-paper-soft, #fff7f3);
	border-left: 4px solid var(--t33-coral, #f67280);
	border-radius: 0 var(--t33-radius, 14px) var(--t33-radius, 14px) 0;
	padding: 18px 22px;
	font-size: 1.02rem;
}

body.mtc-page .t33-page-main .entry-content > ul > li::marker,
body.mtc-page .t33-page-main .entry-content > ol > li::marker {
	color: var(--t33-cyan, #2bc8e8);
}

/* -------------------------------------------------- more science tools --- */

/*
 * Appended by a `the_content` filter, so it is a top-level child of
 * `.entry-content` like any other -- it ADDS an ad boundary rather than
 * removing one, and it reaches pages that do not exist yet.
 */
body.mtc-page .t33-page-main .entry-content > .t33-toolstrip {
	margin-top: 3em;
	padding-top: 1.6em;
	border-top: 1px solid #e3e7ef;
}

body.mtc-page .entry-content .t33-toolstrip-title {
	margin: 0 0 1em;
	font-size: 0.82rem;
	font-weight: 800;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--t33-ink-soft, #5a6378);
}

body.mtc-page .entry-content .t33-toolstrip-list {
	display: grid;
	gap: 14px;
	grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
	margin: 0;
	padding: 0;
	list-style: none;
}

body.mtc-page .entry-content .t33-toolstrip-list li {
	margin: 0;
}

body.mtc-page .entry-content .t33-toolstrip-card {
	display: block;
	height: 100%;
	padding: 16px 18px;
	background: var(--t33-paper, #fff);
	border: 1px solid #e3e7ef;
	border-radius: var(--t33-radius, 14px);
	box-shadow: var(--t33-shadow, 0 10px 30px rgba(7, 11, 26, 0.10));
	color: var(--t33-ink, #1b2233);
	text-decoration: none;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

body.mtc-page .entry-content .t33-toolstrip-card:hover {
	color: var(--t33-ink, #1b2233);
	transform: translateY(-2px);
	box-shadow: var(--t33-shadow-lift, 0 18px 44px rgba(7, 11, 26, 0.16));
}

body.mtc-page .entry-content .t33-toolstrip-name {
	display: block;
	font-weight: 800;
	font-size: 1.02rem;
	margin-bottom: 4px;
}

body.mtc-page .entry-content .t33-toolstrip-what {
	display: block;
	font-size: 0.92rem;
	line-height: 1.5;
	color: var(--t33-ink-soft, #5a6378);
}

/* ------------------------------------------------------------- phone ---- */

/* 600px is the theme's own hero breakpoint, not a new one. */
@media (max-width: 600px) {

	/*
	 * The phone gutter, reclaimed. The theme gutters this column twice -- the
	 * parent theme's bare `.entry-content { padding: 0 30px }` plus
	 * `.t33-page-main`'s own 18px -- so on a 390px phone the tool had 314px to
	 * work with and lost 76px, a fifth of the screen, to empty margin. Measured,
	 * not guessed.
	 *
	 * 12px rather than 0: the prose inside this column still needs an edge, and
	 * every tool card carries its own padding on top of this. Ad containers are
	 * children of `.entry-content` too, so they get the width back as well.
	 */
	body.mtc-page .t33-page-main {
		padding-left: 8px;
		padding-right: 8px;
	}

	body.mtc-page .t33-page-main .entry-content {
		padding-left: 12px;
		padding-right: 12px;
	}

	body.mtc-page .t33-page-hero {
		padding-bottom: 88px;
	}

	body.mtc-page .t33-page-main .entry-content > .mtc:first-child {
		margin-top: -44px;
	}

	body.mtc-page .t33-page-main .entry-content > .mtc + p {
		font-size: 1.1rem;
	}
}

@media (prefers-reduced-motion: reduce) {

	body.mtc-page .entry-content .t33-toolstrip-card {
		transition: none;
	}

	body.mtc-page .entry-content .t33-toolstrip-card:hover {
		transform: none;
	}
}

/* <<< t33 tool-page shell */

/* ------------------------------------------- after the shell: overrides --- */

/*
 * The lifted generator is a white panel over the navy hero band; its own border
 * must not show against the band. Same specificity as the shell's lift rule,
 * (0,5,1), later in the file.
 */
body.mtc-page .t33-page-main .entry-content > .mtc:first-child {
	border-color: transparent;
}

/* ------------------------------------------------------- print block --- */

/*
 * Print in the generator injects a copy of every page into `.mtc-print-root` (a
 * direct child of <body>), adds `mtc-printing` to <body> and an @page rule, and
 * calls window.print(). Everything else on the page is hidden. The !important
 * flags are limited to this block: they have to beat ad containers and inline
 * styles that third-party scripts add to <body>'s children.
 */
body.mtc-page .mtc-print-root {
	display: none;
}

@media print {

	body.mtc-page.mtc-printing {
		margin: 0 !important;
		padding: 0 !important;
		background: #fff !important;
	}

	body.mtc-page.mtc-printing > :not(.mtc-print-root) {
		display: none !important;
	}

	body.mtc-page.mtc-printing .t33-page-hero {
		display: none !important;
	}

	/* The lift is inside .entry-content, which is hidden wholesale; reset it at its own specificity anyway. */
	body.mtc-page .t33-page-main .entry-content > .mtc:first-child {
		margin-top: 0;
		box-shadow: none;
	}

	body.mtc-page.mtc-printing .mtc-print-root {
		display: block;
		margin: 0;
		padding: 0;
	}

	body.mtc-page .mtc-print-root .mtc-print-page {
		overflow: hidden;
		break-after: page;
		page-break-after: always;
	}

	body.mtc-page .mtc-print-root .mtc-print-page:last-child {
		break-after: auto;
		page-break-after: auto;
	}

	body.mtc-page .mtc-print-root .mtc-print-page svg {
		display: block;
		width: 100%;
		height: 100%;
	}
}

/*
 * Mediavine Grow inline subscribe widgets. The single-post body class (needed
 * for in-content ad units) makes grow-for-wp insert them; each shifts the page
 * by about 0.09 as it renders. They earn nothing, and the other 33science tools
 * leave Grow out. Ad units are untouched.
 */
body.mtc-page [id^="grow-me-inline-subscribe"] {
	display: none;
}
