/*
 * Tap-to-answer practice (the interactive pilot): the answer formats, the skill pages and the Quick practice lists. Loaded
 * only where they are used. Uses the design's colour variables and the app's own components (.button, .feedback__head).
 * Every control is at least 48px each way, and everything fits a 360px wide phone.
 */

/* ---------- choice ---------- */

.ti-choices {
	display: grid;
	gap: 0.625rem;
	margin: 0 0 1rem;
}

.ti-choices--row {
	grid-template-columns: repeat(auto-fit, minmax(5rem, 1fr));
}

.ti-choice {
	position: relative;
	min-height: 3.5rem;
	padding: 0.625rem 0.875rem;
	border: 0.125rem solid var(--blue-3);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.25rem;
	font-weight: 500;
	line-height: 1.3;
	cursor: pointer;
	touch-action: manipulation;
	transition: background-color 0.12s, border-color 0.12s;
}

.ti-choices--row .ti-choice {
	font-size: 1.5rem;
	min-height: 4.5rem;
}

.ti-choices--pictures {
	grid-template-columns: repeat(auto-fit, minmax(6rem, 1fr));
}

.ti-choices--pictures .ti-choice {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 0.25rem;
	min-height: 6rem;
	padding: 0.5rem;
}

.ti-choice svg {
	display: block;
	width: 100%;
	max-width: 7.5rem;
	height: auto;
}

.ti-choice__letter {
	font-size: 1.125rem;
}

.ti-choice:hover:not([aria-disabled="true"]) {
	background: var(--blue-4);
	border-color: var(--blue-2);
}

.ti-choice:focus-visible,
.ti-key:focus-visible,
.ti-cell:focus-visible,
.ti-tap:focus-visible,
.ti-listen__play:focus-visible,
.ti-line__track:focus-visible,
.ti-number__input:focus-visible,
.ti-part:focus-visible {
	outline: 0.1875rem solid var(--neutrals-1);
	outline-offset: 0.125rem;
}

.ti-choice.is-chosen {
	border-color: var(--blue-1);
	background: var(--blue-4);
}

.ti-choice[aria-disabled="true"] {
	cursor: default;
}

.ti-choice.is-right {
	border-color: var(--green-1);
	background: var(--green-3);
}

.ti-choice.is-wrong {
	border-color: #c8402f;
	background: #fdecea;
}

.ti-mark {
	position: absolute;
	top: 0.25rem;
	right: 0.375rem;
	font-size: 1.125rem;
	line-height: 1;
}

.ti-mark--right {
	color: #4c6a00;
}

.ti-mark--wrong {
	color: #a1281c;
}

/* ---------- listen ---------- */

.ti-listen {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem 1rem;
	margin-bottom: 1rem;
}

.ti-listen__play {
	display: inline-flex;
	align-items: center;
	gap: 0.625rem;
	min-height: 4rem;
	padding: 0.5rem 1.5rem;
	border: 0;
	border-radius: 2rem;
	background: var(--blue-1);
	color: var(--neutrals-white);
	font: inherit;
	font-size: 1.25rem;
	font-weight: 500;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-listen__play svg {
	width: 2rem;
	height: 2rem;
}

.ti-listen__show {
	min-height: 3rem;
}

.ti-listen__word {
	flex: 1 0 100%;
	margin: 0;
	font-size: 1.5rem;
	font-weight: 500;
}

/* ---------- number pad ---------- */

.ti-number {
	max-width: 20rem;
	margin: 0 0 1rem;
}

.ti-number__box {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-bottom: 0.625rem;
}

.ti-number__input {
	flex: 1 1 auto;
	min-width: 0;
	height: 4rem;
	padding: 0 1rem;
	border: 0.125rem solid var(--blue-2);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 2.25rem;
	font-weight: 500;
	text-align: center;
}

.ti-number__unit {
	font-size: 1.75rem;
	font-weight: 500;
}

.ti-number.is-right .ti-number__input {
	border-color: var(--green-1);
	background: var(--green-3);
}

.ti-number.is-wrong .ti-number__input {
	border-color: #c8402f;
	background: #fdecea;
}

.ti-pad {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 0.5rem;
}

.ti-key {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 3.5rem;
	border: 0.0625rem solid var(--blue-3);
	border-radius: 0.75rem;
	background: var(--neutrals-6);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.625rem;
	font-weight: 500;
	cursor: pointer;
	touch-action: manipulation;
	user-select: none;
}

.ti-key:hover:not(:disabled) {
	background: var(--blue-4);
}

.ti-key:active:not(:disabled) {
	background: var(--blue-3);
}

.ti-key:disabled {
	opacity: 0.5;
	cursor: default;
}

.ti-key svg {
	width: 2rem;
	height: 2rem;
}

/* ---------- ten frames ---------- */

.ti-frames {
	display: grid;
	gap: 0.875rem;
	max-width: 22rem;
	margin: 0 0 1rem;
}

.ti-frame {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	border: 0.125rem solid var(--neutrals-1);
	border-radius: 0.25rem;
	overflow: hidden;
}

.ti-cell {
	position: relative;
	min-height: 3.5rem;
	aspect-ratio: 1;
	padding: 0;
	border: 0.0625rem solid var(--neutrals-1);
	border-radius: 0;
	background: var(--neutrals-white);
	cursor: pointer;
	touch-action: manipulation;
}

.ti-cell::after {
	content: "";
	position: absolute;
	inset: 14%;
	border-radius: 50%;
	background: var(--blue-1);
	border: 0.125rem solid var(--neutrals-1);
	transform: scale(0);
	transition: transform 0.1s;
}

.ti-cell[aria-pressed="true"]::after {
	transform: scale(1);
}

.ti-cell:focus-visible {
	outline-offset: -0.25rem;
	z-index: 1;
}

.ti-cell:disabled {
	cursor: default;
}

.ti-frames.is-right .ti-frame {
	border-color: var(--green-1);
	box-shadow: 0 0 0 0.1875rem var(--green-3);
}

.ti-frames.is-wrong .ti-frame {
	border-color: #c8402f;
	box-shadow: 0 0 0 0.1875rem #fdecea;
}

/* ---------- shade ---------- */

.ti-shade {
	margin: 0 0 1rem;
}

.ti-shade svg {
	display: block;
	max-width: 100%;
	height: auto;
}

.ti-part {
	fill: var(--neutrals-white);
	stroke: var(--neutrals-1);
	stroke-width: 3;
	cursor: pointer;
	touch-action: manipulation;
	transition: fill 0.1s;
}

.ti-part:hover {
	fill: var(--blue-4);
}

.ti-part[aria-pressed="true"],
.ti-part[aria-pressed="true"]:hover {
	fill: var(--blue-2);
}

.ti-part[aria-disabled="true"] {
	cursor: default;
}

.ti-part[aria-disabled="true"]:hover {
	fill: var(--neutrals-white);
}

.ti-part[aria-disabled="true"][aria-pressed="true"]:hover {
	fill: var(--blue-2);
}

.ti-shade.is-right svg {
	outline: 0.1875rem solid var(--green-2);
	outline-offset: 0.25rem;
}

.ti-shade.is-wrong svg {
	outline: 0.1875rem solid #c8402f;
	outline-offset: 0.25rem;
}

/* ---------- number line ---------- */

.ti-line {
	margin: 0 0 1rem;
}

.ti-line__track {
	display: block;
	width: 100%;
	max-width: 44rem;
	min-height: 6.5rem;
	border-radius: 0.5rem;
	background: var(--neutrals-6);
	cursor: pointer;
	touch-action: manipulation;
}

.ti-line__track svg {
	display: block;
	width: 100%;
	height: auto;
}

.ti-line.is-locked .ti-line__track {
	cursor: default;
}

.ti-line.is-right .ti-line__track {
	box-shadow: 0 0 0 0.1875rem var(--green-2);
}

.ti-line.is-wrong .ti-line__track {
	box-shadow: 0 0 0 0.1875rem #c8402f;
}

.ti-line__nudge {
	display: flex;
	gap: 0.625rem;
	margin-top: 0.625rem;
}

.ti-line__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	min-width: 4.5rem;
	min-height: 3rem;
	max-width: none;
	font-size: 1.5rem;
	cursor: pointer;
}

/* ---------- parts: several answer slots ---------- */

.ti-parts {
	display: grid;
	gap: 0.75rem;
	margin: 0 0 1rem;
}

.ti-slot {
	padding: 0.5rem 0.75rem 0.625rem;
	border: 0.125rem solid var(--neutrals-4);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
}

.ti-slot.is-active {
	border-color: var(--blue-1);
}

.ti-slot.is-right {
	border-color: var(--green-1);
}

.ti-slot.is-wrong {
	border-color: #c8402f;
}

.ti-slot__label {
	margin-bottom: 0.375rem;
	font-size: 1.0625rem;
	font-weight: 500;
	line-height: 1.3;
}

.ti-slot .ti-choices,
.ti-slot .ti-number,
.ti-slot .ti-number__box,
.ti-slot .ti-order,
.ti-slot .ti-sort,
.ti-slot .ti-match {
	margin: 0;
}

.ti-slot .ti-number {
	max-width: none;
}

.ti-slot .ti-number__input {
	height: 3.25rem;
	font-size: 1.75rem;
}

.ti-slot .ti-choices--row .ti-choice {
	min-height: 3.25rem;
	font-size: 1.25rem;
}

/* Many-part questions: short phrases and fractions on a row. */
.exam--slotrows .ti-slot .ti-choices--row {
	grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
	grid-auto-flow: column;
}

.exam--slotrows .ti-slot .ti-choices--row .ti-choice {
	min-height: 3rem;
	padding: 0.25rem 0.375rem;
	font-size: 1rem;
	line-height: 1.2;
}

.ti-slot .ti-choice {
	min-height: 3rem;
	font-size: 1.0625rem;
}

.ti-pad--shared {
	max-width: 20rem;
}

.ti-partlist {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ti-partline {
	display: flex;
	align-items: baseline;
	gap: 0.5rem;
	padding: 0.25rem 0;
	font-size: 1.0625rem;
}

.ti-partline__icon {
	flex: 0 0 auto;
	font-weight: 700;
}

.ti-partline.is-right .ti-partline__icon {
	color: #4c6a00;
}

.ti-partline.is-wrong .ti-partline__icon {
	color: #a1281c;
}

.ti-result__icon--some {
	background: #c47a12;
}

/* ---------- order ---------- */

.ti-order {
	margin: 0 0 1rem;
}

.ti-order__ends {
	display: flex;
	justify-content: space-between;
	margin: 0 0 0.25rem;
	font-size: 0.9375rem;
	font-weight: 500;
	color: var(--neutrals-2);
}

.ti-order__places {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(5.5rem, 1fr));
	gap: 0.5rem;
	margin: 0 0 0.75rem;
	padding: 0;
	list-style: none;
}

.ti-order__place {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 0.125rem;
	width: 100%;
	min-height: 4rem;
	padding: 0.375rem;
	border: 0.125rem solid var(--blue-2);
	border-radius: 0.75rem;
	background: var(--blue-4);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.0625rem;
	font-weight: 500;
	line-height: 1.2;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-order__place svg {
	display: block;
	width: 100%;
	max-width: 5rem;
	height: auto;
}

.ti-order__place.is-empty {
	border-style: dashed;
	background: var(--neutrals-6);
	cursor: default;
}

.ti-order__num {
	font-size: 0.8125rem;
	font-weight: 400;
	color: var(--neutrals-2);
}

.ti-order__place.is-empty .ti-order__num {
	font-size: 1.25rem;
}

.ti-order__place.is-right {
	border-color: var(--green-1);
	background: var(--green-3);
}

.ti-order__place.is-wrong {
	border-color: #c8402f;
	background: #fdecea;
}

.ti-order__tray {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(5.5rem, 1fr));
	gap: 0.5rem;
}

.ti-order__item {
	font-size: 1.0625rem;
}

/* ---------- match ---------- */

.ti-match {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0.75rem;
	margin: 0 0 1rem;
}

.ti-match__col {
	display: grid;
	gap: 0.5rem;
	align-content: start;
}

.ti-match__item {
	position: relative;
	min-height: 3.5rem;
	font-size: 1.0625rem;
}

.ti-match__item svg {
	display: block;
	width: 100%;
	max-width: 5.5rem;
	height: auto;
	margin: 0 auto;
}

.ti-match__item.is-joined {
	background: var(--blue-4);
	border-color: var(--blue-2);
}

.ti-match__tag {
	position: absolute;
	top: -0.375rem;
	right: -0.375rem;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 1.5rem;
	height: 1.5rem;
	border-radius: 50%;
	background: var(--blue-1);
	color: var(--neutrals-white);
	font-size: 0.875rem;
	font-weight: 700;
}

/* ---------- sort ---------- */

.ti-sort {
	margin: 0 0 1rem;
}

.ti-sort__tray {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-bottom: 0.75rem;
}

.ti-sort__item {
	flex: 0 1 auto;
	min-width: 3rem;
	min-height: 3rem;
	padding: 0.25rem 0.625rem;
	font-size: 1.0625rem;
}

.ti-sort__item svg {
	display: block;
	width: 3rem;
	height: 3rem;
}

.ti-sort__groups {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
	gap: 0.5rem;
}

.ti-sort__group {
	display: flex;
	flex-direction: column;
	border: 0.125rem solid var(--blue-2);
	border-radius: 0.75rem;
	background: var(--neutrals-6);
	overflow: hidden;
}

.ti-sort__head {
	min-height: 3rem;
	padding: 0.25rem 0.5rem;
	border: 0;
	background: var(--blue-4);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.0625rem;
	font-weight: 500;
	cursor: pointer;
	touch-action: manipulation;
}

.has-picked .ti-sort__head {
	background: var(--blue-3);
}

.ti-sort__inner {
	display: flex;
	flex-wrap: wrap;
	align-content: flex-start;
	gap: 0.375rem;
	min-height: 4rem;
	padding: 0.375rem;
}

/* Two hoops, each across two columns, so that the middle column is where they cross. Everything else goes in Neither. */
.ti-sort--venn .ti-sort__groups {
	position: relative;
	grid-template-columns: 1fr 1fr 1fr;
	gap: 0;
}

.ti-sort--venn .ti-sort__groups::before,
.ti-sort--venn .ti-sort__groups::after {
	content: "";
	position: absolute;
	inset: 0;
	grid-row: 1 / 2;
	border: 0.1875rem solid var(--blue-2);
	border-radius: 3rem;
	pointer-events: none;
}

.ti-sort--venn .ti-sort__groups::before {
	grid-column: 1 / span 2;
}

.ti-sort--venn .ti-sort__groups::after {
	grid-column: 2 / span 2;
}

.ti-sort--venn .ti-sort__group {
	min-width: 0;
	border: 0;
	border-radius: 0;
	background: none;
	overflow: visible;
}

.ti-sort--venn .ti-sort__group--1 {
	order: 3;
}

.ti-sort--venn .ti-sort__group--2 {
	order: 2;
	border-radius: 3rem;
	background: var(--blue-4);
}

.ti-sort--venn .ti-sort__group--3 {
	order: 4;
	grid-column: 1 / -1;
	margin-top: 0.5rem;
	border: 0.125rem solid var(--blue-2);
	border-radius: 0.75rem;
	background: var(--neutrals-6);
}

.ti-sort--venn .ti-sort__head {
	padding-inline: 0.125rem;
	font-size: 0.9375rem;
	background: none;
}

.ti-sort--venn .ti-sort__inner {
	justify-content: center;
	padding-bottom: 0.875rem;
}

/* ---------- place value ---------- */

.ti-pv {
	max-width: 22rem;
	margin: 0 0 1rem;
}

.ti-pv__show {
	display: flex;
	gap: 1rem;
	align-items: flex-end;
	min-height: 6.5rem;
	margin-bottom: 0.625rem;
	padding: 0.5rem;
	border: 0.0625rem solid var(--neutrals-4);
	border-radius: 0.625rem;
	background: var(--neutrals-white);
}

.ti-pv.is-right .ti-pv__show {
	box-shadow: 0 0 0 0.1875rem var(--green-2);
}

.ti-pv.is-wrong .ti-pv__show {
	box-shadow: 0 0 0 0.1875rem #c8402f;
}

.ti-pv__tens {
	display: flex;
	flex-wrap: wrap;
	gap: 0.25rem;
	flex: 1 1 auto;
}

.ti-pv__ones {
	display: grid;
	grid-template-columns: repeat(3, 1rem);
	gap: 0.25rem;
	flex: 0 0 auto;
	align-content: end;
}

.ti-pv__stick {
	width: 1rem;
	height: 5.5rem;
	border: 0.125rem solid var(--neutrals-1);
	border-radius: 0.1875rem;
	background: repeating-linear-gradient(to bottom, var(--blue-2) 0, var(--blue-2) calc(10% - 0.125rem), var(--neutrals-1) calc(10% - 0.125rem), var(--neutrals-1) 10%);
}

.ti-pv__cube {
	width: 1rem;
	height: 1rem;
	border: 0.125rem solid var(--neutrals-1);
	border-radius: 0.1875rem;
	background: #f5943a;
}

.ti-pv__row {
	display: grid;
	grid-template-columns: 1fr 4.5rem 4.5rem;
	align-items: center;
	gap: 0.5rem;
	margin-top: 0.5rem;
}

.ti-pv__name {
	font-size: 1.125rem;
	font-weight: 500;
}

/* ---------- coins ---------- */

.ti-coins {
	margin: 0 0 1rem;
}

.ti-coins__tray {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-bottom: 0.75rem;
}

.ti-coin {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 3.75rem;
	height: 3.75rem;
	padding: 0;
	border: 0.1875rem solid var(--neutrals-1);
	border-radius: 50%;
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.125rem;
	font-weight: 700;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-coin--copper {
	background: #d99a68;
}

.ti-coin--silver {
	background: #d6dae0;
}

.ti-coin--gold {
	background: #f1cf56;
}

.ti-coins__purse {
	min-height: 6rem;
	padding: 0.5rem;
	border: 0.125rem dashed var(--blue-2);
	border-radius: 1rem;
	background: var(--neutrals-6);
}

.ti-coins.is-right .ti-coins__purse {
	border: 0.125rem solid var(--green-1);
	background: var(--green-3);
}

.ti-coins.is-wrong .ti-coins__purse {
	border: 0.125rem solid #c8402f;
	background: #fdecea;
}

.ti-coins__name {
	display: block;
	margin-bottom: 0.25rem;
	font-weight: 500;
}

.ti-coins__in {
	display: flex;
	flex-wrap: wrap;
	gap: 0.375rem;
}

/* ---------- clock ---------- */

.ti-clock {
	max-width: 20rem;
	margin: 0 0 1rem;
}

.ti-clock__which {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0.5rem;
	margin-bottom: 0.625rem;
}

.ti-clock__hand {
	min-height: 3rem;
	border: 0.125rem solid var(--blue-3);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font: inherit;
	font-weight: 500;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-clock__hand[aria-pressed="true"] {
	border-color: var(--blue-1);
	background: var(--blue-4);
}

.ti-clock__face {
	position: relative;
	width: 100%;
	aspect-ratio: 1;
}

.ti-clock__face svg {
	display: block;
	width: 100%;
	height: 100%;
}

.ti-clock.is-right svg circle:first-child {
	stroke: var(--green-1);
}

.ti-clock.is-wrong svg circle:first-child {
	stroke: #c8402f;
}

.ti-clock__num {
	position: absolute;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 3rem;
	height: 3rem;
	margin: -1.5rem 0 0 -1.5rem;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.375rem;
	font-weight: 700;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-clock__num:hover:not(:disabled) {
	background: var(--blue-4);
}

.ti-clock__num:focus-visible,
.ti-clock__hand:focus-visible,
.ti-coin:focus-visible,
.ti-order__place:focus-visible,
.ti-sort__head:focus-visible {
	outline: 0.1875rem solid var(--neutrals-1);
	outline-offset: 0.125rem;
}

.ti-coin--note {
	border-radius: 0.375rem;
	min-width: 4.25rem;
	background: #cfe8d2;
}

/* ---------- scale: thermometer, jug, ruler, dial ---------- */

.ti-scale {
	margin: 0 0 1rem;
}

.ti-scale__track {
	display: block;
	width: 100%;
	border-radius: 0.5rem;
	background: var(--neutrals-6);
	cursor: pointer;
	touch-action: manipulation;
}

.ti-scale__track:focus-visible {
	outline: 0.1875rem solid var(--neutrals-1);
	outline-offset: 0.125rem;
}

.ti-scale__track svg {
	display: block;
	width: 100%;
	height: auto;
	margin: 0 auto;
}

.ti-scale--thermometer .ti-scale__track {
	max-width: 15rem;
}

.ti-scale--jug .ti-scale__track {
	max-width: 17.5rem;
}

.ti-scale--dial .ti-scale__track {
	max-width: 18.75rem;
}

.ti-scale--ruler .ti-scale__track {
	max-width: 40rem;
}

.ti-scale.is-locked .ti-scale__track {
	cursor: default;
}

.ti-scale.is-right .ti-scale__track {
	box-shadow: 0 0 0 0.1875rem var(--green-2);
}

.ti-scale.is-wrong .ti-scale__track {
	box-shadow: 0 0 0 0.1875rem #c8402f;
}

/* ---------- chart: tally chart, pictogram, block diagram ---------- */

.ti-chart {
	max-width: 40rem;
	margin: 0 0 1rem;
}

.ti-chart__key {
	display: flex;
	align-items: center;
	gap: 0.25rem;
	margin: 0 0 0.5rem;
	font-weight: 500;
}

.ti-chart__row {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	min-height: 3.25rem;
	padding: 0.25rem 0.5rem;
	border: 0.125rem solid var(--neutrals-5);
	border-bottom-width: 0;
	background: var(--neutrals-white);
}

.ti-chart__row:last-child {
	border-bottom-width: 0.125rem;
}

.ti-chart__row.is-given {
	background: var(--neutrals-6);
}

.ti-chart__row.is-right {
	background: #eef7d8;
}

.ti-chart__row.is-wrong {
	background: #fdecea;
}

.ti-chart__name {
	flex: 0 0 4.5rem;
	font-weight: 500;
	overflow-wrap: anywhere;
}

.ti-chart__marks {
	display: flex;
	flex: 1 1 auto;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.125rem;
	min-width: 0;
}

.ti-chart__marks svg {
	flex: none;
	max-width: 100%;
}

.ti-chart__btns {
	display: flex;
	flex: none;
	gap: 0.25rem;
}

.ti-chart__btn {
	width: 3rem;
	height: 3rem;
	min-height: 3rem;
	padding: 0;
	font-size: 1.5rem;
}

/* A block diagram stands up: a column of blocks, its name and its buttons, side by side. */
.ti-chart--block .ti-chart__area {
	display: flex;
	gap: 0.25rem;
	justify-content: space-between;
}

.ti-chart--block .ti-chart__row {
	display: flex;
	flex: 1 1 0;
	flex-direction: column;
	align-items: stretch;
	justify-content: flex-end;
	gap: 0.25rem;
	min-width: 0;
	padding: 0;
	border: 0;
	background: none;
	text-align: center;
}

.ti-chart--block .ti-chart__marks {
	flex: none;
	flex-direction: column-reverse;
	flex-wrap: nowrap;
	align-items: stretch;
	justify-content: flex-start;
	gap: 0;
	height: calc(var(--chart-max, 10) * 1.25rem + 0.125rem);
	border-bottom: 0.1875rem solid var(--neutrals-1);
	background-image: repeating-linear-gradient(to top, transparent 0 calc(1.25rem - 1px), #e2e3eb calc(1.25rem - 1px) 1.25rem);
}

.ti-chart__axis {
	position: relative;
	order: -1;
	flex: 0 0 1.25rem;
	align-self: flex-start;
	height: calc(var(--chart-max, 10) * 1.25rem + 0.125rem);
	font-size: 0.75rem;
	line-height: 1;
	color: var(--neutrals-2);
	text-align: right;
}

.ti-chart__axis span {
	position: absolute;
	right: 0;
	transform: translateY(50%);
}

.ti-chart__block {
	display: block;
	flex: none;
	height: 1.25rem;
	margin: 0 0.5rem;
	border: 0.0625rem solid var(--neutrals-1);
	background: #7fb3ea;
}

.ti-chart--block .is-given .ti-chart__block {
	background: var(--neutrals-4);
}

.ti-chart--block .is-right .ti-chart__marks {
	background-color: #eef7d8;
}

.ti-chart--block .is-wrong .ti-chart__marks {
	background-color: #fdecea;
}

.ti-chart--block .ti-chart__name {
	flex: none;
	font-size: 0.9375rem;
}

.ti-chart--block .ti-chart__btns {
	flex-direction: column;
	align-items: center;
}

.ti-chart--block .is-given::after {
	content: "";
	display: block;
	height: 6.25rem;
}

/* ---------- plain boxes for a typed answer ---------- */

.ti-typed__box {
	display: block;
	width: 100%;
	border: 0.125rem solid var(--blue-2);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font: inherit;
}

.ti-typed__box--words {
	min-height: 3.25rem;
	padding: 0.625rem 0.875rem;
	font-size: 1.25rem;
	line-height: 1.35;
}

.ti-typed.is-locked .ti-typed__box {
	background: var(--neutrals-5);
}

/* ---------- results ---------- */

.ti-result {
	gap: 0.75rem;
}

.ti-result__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 2.5rem;
	width: 2.5rem;
	height: 2.5rem;
	border-radius: 50%;
	color: var(--neutrals-white);
	font-size: 1.375rem;
	font-weight: 700;
}

.ti-result__icon--right {
	background: #5f8100;
}

.ti-result__icon--wrong {
	background: #c8402f;
}

.ti-result .feedback__verdict {
	font-size: 1.375rem;
}

.ti-result__answer {
	margin: 0;
	font-size: 1.125rem;
}

.ti-result__why {
	margin-top: 0.5rem;
}

.ti-result__why p + p {
	margin-top: 0.5rem;
}

/* ---------- a round's answer area when a question uses a format ---------- */

.instant-box {
	margin-bottom: 1rem;
}

/* The buttons around the answer are big enough for small fingers too. This file only loads on Years 1 and 2 and skill pages. */
.feedback__actions .button,
.box-quiz__actions .button,
.skill-q__actions .button,
.skill-mastered ~ .feedback__actions .button {
	min-height: 3rem;
}

.feedback__actions .quiz-link,
.box-quiz__actions .quiz-link {
	display: inline-flex;
	align-items: center;
	min-height: 3rem;
}

.quiz-card .speak-btn:not(.speak-btn--icon) {
	min-height: 3rem;
}

/* ---------- tappable multiple choice (no spec, still AI-marked) ---------- */

.q-choices--tap li {
	padding: 0;
	border: 0;
	background: none;
}

.ti-tap {
	display: block;
	width: 100%;
	min-height: 3.25rem;
	padding: 0.625rem 0.875rem;
	border: 0.125rem solid var(--blue-3);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.125rem;
	line-height: 1.35;
	text-align: left;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-tap:hover:not(:disabled) {
	background: var(--blue-4);
}

.ti-tap[aria-pressed="true"] {
	border-color: var(--blue-1);
	background: var(--blue-4);
	font-weight: 500;
}

.ti-tap:disabled {
	cursor: default;
}

/* ---------- a skill page ---------- */

.skill-page__course {
	display: inline-block;
	margin-top: 0.375rem;
	font-size: 0.875rem;
	color: var(--blue-1);
}

/* On a phone the question comes first: the title gets small and the rest goes, so a number pad fits on the screen. */
@media (max-width: 61.99875em) {
	.exam--skill .quiz-card__header {
		margin-bottom: 0.5rem;
	}

	.exam--skill .quiz-card__title {
		font-size: 1.125rem;
		line-height: 1.3;
	}

	.exam--skill .side-progress__line,
	.exam--skill .side-progress__block,
	.skill-page__blurb,
	.skill-page__course {
		display: none;
	}

	.exam--skill .skill-score {
		margin-bottom: 0.75rem;
		padding: 0.375rem 0.75rem;
	}

	.exam--skill .skill-q__prompt {
		font-size: 1.25rem;
	}

	.exam--skill .skill-q__big {
		margin-bottom: 0.5rem;
		font-size: 1.875rem;
	}

	.exam--skill .ti-number__input {
		height: 3.25rem;
		font-size: 1.875rem;
	}

	.exam--skill .ti-number__box {
		margin-bottom: 0.5rem;
	}

	.exam--skill .ti-key {
		min-height: 3rem;
		font-size: 1.5rem;
	}

	.exam--skill .ti-pad {
		gap: 0.25rem;
	}
}

.skill-page__blurb {
	margin: 0 0 1rem;
	line-height: 1.5;
	color: var(--neutrals-2);
}

.skill-score {
	display: grid;
	grid-template-columns: auto auto minmax(0, 1fr);
	align-items: center;
	gap: 0.625rem;
	margin: 0 0 1.25rem;
	padding: 0.625rem 0.875rem;
	border-radius: 0.625rem;
	background: var(--neutrals-5);
}

.skill-score__label {
	font-weight: 500;
}

.skill-score__circle .donut-chart {
	width: 2.25rem;
	height: 2.25rem;
}

.skill-score__value {
	font-size: 1.5rem;
	font-weight: 500;
	line-height: 1;
}

.skill-score__value small {
	font-size: 0.875rem;
	font-weight: 400;
	color: var(--neutrals-2);
}

.skill-score__flag {
	grid-column: 1 / -1;
	font-weight: 500;
	color: #4c6a00;
}

.skill-q__top {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 0.75rem;
	margin-bottom: 0.75rem;
}

.skill-q__prompt {
	margin: 0;
	font-size: 1.375rem;
	font-weight: 500;
	line-height: 1.35;
}

.skill-q__listen {
	flex: 0 0 auto;
}

.skill-q__listen .speak-btn {
	min-height: 3rem;
}

.skill-q__big {
	margin: 0 0 1rem;
	font-size: 2.25rem;
	font-weight: 500;
	line-height: 1.2;
}

.skill-q__figure {
	margin: 0 0 1rem;
	padding: 0.5rem;
	border-radius: 0.625rem;
	background: var(--neutrals-white);
	box-shadow: inset 0 0 0 0.0625rem var(--neutrals-4);
}

.skill-q__figure svg {
	display: block;
	max-width: 100%;
	height: auto;
	margin: 0 auto;
}

.skill-q__actions .button {
	margin: 0;
	max-width: none;
	min-width: 9.375rem;
	min-height: 3.25rem;
}

.skill-note {
	margin: 0.75rem 0 0;
	padding: 0.75rem 1rem;
	border-radius: 0.625rem;
	background: var(--green-3);
	font-size: 1.125rem;
}

.skill-note--warn {
	background: var(--orange-2);
	font-size: 1rem;
}

.skill-mastered {
	margin-top: 1rem;
	padding: 1.25rem 1rem;
	border-radius: 0.75rem;
	background: var(--green-3);
	text-align: center;
	line-height: 1.5;
}

.skill-mastered h2 {
	margin: 0.75rem 0 0.25rem;
	font-size: 1.75rem;
	font-weight: 500;
}

.skill-mastered .round-summary__ring {
	margin: 0 auto;
}

/* ---------- Quick practice lists: course page, progress page, topic pages ---------- */

.quick-practice {
	margin-top: 0.25rem;
}

.quick-practice__intro {
	margin: 0 0 0.75rem;
	line-height: 1.5;
	color: var(--neutrals-2);
}

.quick-unit {
	margin-top: 0.5rem;
	border: 0.0625rem solid var(--neutrals-4);
	border-radius: 0.625rem;
	background: var(--neutrals-6);
}

.quick-unit[open] {
	padding-bottom: 0.75rem;
}

.quick-unit__head {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.25rem 0.75rem;
	min-height: 3rem;
	padding: 0.5rem 0.875rem;
	cursor: pointer;
}

.quick-unit__name {
	font-weight: 500;
}

.quick-unit__count {
	font-size: 0.875rem;
	color: var(--neutrals-2);
}

.quick-unit .quick-practice__unit,
.quick-unit .quick-practice__list {
	margin-inline: 0.75rem;
}

.quick-practice__unit {
	margin: 1rem 0 0.5rem;
	font-size: 0.9375rem;
	font-weight: 500;
}

.quick-practice__list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
	gap: 0.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.quick-skill {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: center;
	gap: 0.25rem 0.75rem;
	min-height: 3rem;
	padding: 0.625rem 0.875rem;
	border: 0.0625rem solid var(--neutrals-4);
	border-radius: 0.625rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	line-height: 1.35;
	text-decoration: none;
}

.quick-skill:hover {
	border-color: var(--blue-2);
	background: var(--blue-4);
}

.quick-skill__score {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	font-size: 0.875rem;
	font-weight: 500;
	white-space: nowrap;
}

.quick-skill__score--mastered {
	color: #4c6a00;
}

.skill-links {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.375rem 0.5rem;
	margin: 0 0 1rem;
	font-size: 0.875rem;
}

.skill-links__label {
	font-weight: 500;
}

.skill-links a {
	display: inline-flex;
	align-items: center;
	min-height: 2.25rem;
	padding: 0.25rem 0.75rem;
	border-radius: 2rem;
	background: var(--blue-4);
	color: var(--neutrals-1);
	text-decoration: none;
}

.skill-links a:hover {
	background: var(--blue-3);
}

/* On a phone the links are one row that scrolls sideways, so the question stays near the top. */
@media (max-width: 61.99875em) {
	.skill-links {
		flex-wrap: nowrap;
		overflow-x: auto;
		margin-bottom: 0.75rem;
		padding-bottom: 0.25rem;
	}

	.skill-links__label,
	.skill-links a {
		flex: 0 0 auto;
		white-space: nowrap;
	}

	.skill-links a {
		min-height: 3rem;
	}
}

@media (max-width: 22.5em) {
	.skill-q__big {
		font-size: 1.875rem;
	}

	.ti-choices--row .ti-choice {
		font-size: 1.375rem;
	}
}

/* Years 1 and 2, in a round, at any width: the question comes first, with the skill links under it, and the number pad (two rows of keys)
   and Check stay in sight however long the question. */
.exam--plainbox #quiz {
	display: flex;
	flex-direction: column;
}

.exam--plainbox #quiz > * {
	min-width: 0;
}

.exam--plainbox #quiz > .skill-links {
	order: 1;
	margin: 0.5rem 0 0;
}

.exam--plainbox #quiz .ti-number,
.exam--plainbox #quiz .ti-pad--shared {
	max-width: 30rem;
}

.exam--plainbox #quiz .ti-slot .ti-number {
	max-width: none;
}

.exam--plainbox #quiz .ti-pad {
	position: sticky;
	bottom: 3.75rem;
	z-index: 2;
	grid-template-columns: repeat(6, 1fr);
	gap: 0.25rem;
	padding-block: 0.25rem;
	background: var(--neutrals-white);
}

.exam--plainbox #quiz .ti-number.is-locked .ti-pad {
	position: static;
}

.exam--plainbox #quiz .ti-key {
	min-height: 3rem;
	font-size: 1.5rem;
}

.exam--plainbox #quiz .ti-key--del {
	grid-column: 6;
	grid-row: 1 / span 2;
}

/* A time box's ":" key takes the lower half of the delete key's column, so the pad keeps its two rows. */
.exam--plainbox #quiz .ti-pad--colon .ti-key--del {
	grid-row: 1;
}

.exam--plainbox #quiz .ti-key--next {
	grid-column: 6;
	grid-row: 2;
}

/* Year 4: a decimal box's point key, or a negative number's minus key, takes the lower half of the delete key's column, as ":" does. */
.exam--plainbox #quiz .ti-pad--point .ti-key--del,
.exam--plainbox #quiz .ti-pad--minus .ti-key--del {
	grid-row: 1;
}

.exam--plainbox #quiz .ti-key--point,
.exam--plainbox #quiz .ti-key--minus {
	grid-column: 6;
	grid-row: 2;
}

/* Two or three extra keys (the point, the minus, a time box's ":"): delete keeps its column and they share a third row, so every
   key stays 48 px wide on a 360 px phone. (Seven columns made them 41 px, and once put the minus key under ":".) */
.exam--plainbox #quiz .ti-pad--point.ti-pad--minus .ti-key--del,
.exam--plainbox #quiz .ti-pad--colon.ti-pad--point .ti-key--del,
.exam--plainbox #quiz .ti-pad--colon.ti-pad--minus .ti-key--del {
	grid-row: 1 / span 2;
}

.exam--plainbox #quiz .ti-pad--point.ti-pad--minus .ti-key--point,
.exam--plainbox #quiz .ti-pad--colon.ti-pad--point .ti-key--point {
	grid-column: 1 / span 3;
	grid-row: 3;
}

.exam--plainbox #quiz .ti-pad--colon.ti-pad--minus .ti-key--minus {
	grid-column: 1 / span 3;
	grid-row: 3;
}

.exam--plainbox #quiz .ti-pad--point.ti-pad--minus .ti-key--minus,
.exam--plainbox #quiz .ti-pad--colon.ti-pad--point .ti-key--next,
.exam--plainbox #quiz .ti-pad--colon.ti-pad--minus .ti-key--next {
	grid-column: 4 / span 3;
	grid-row: 3;
}

.exam--plainbox #quiz .ti-pad--colon.ti-pad--point.ti-pad--minus .ti-key--point {
	grid-column: 1 / span 2;
}

.exam--plainbox #quiz .ti-pad--colon.ti-pad--point.ti-pad--minus .ti-key--minus {
	grid-column: 3 / span 2;
}

.exam--plainbox #quiz .ti-pad--colon.ti-pad--point.ti-pad--minus .ti-key--next {
	grid-column: 5 / span 2;
}

/* Year 4: Roman numeral keys stay with their box, two rows of three: a question may have the number pad pinned as well. */
.exam--plainbox #quiz .ti-pad--roman {
	position: static;
	grid-template-columns: repeat(3, 1fr);
}

.exam--plainbox #quiz .ti-pad--roman .ti-key--del {
	grid-column: auto;
	grid-row: auto;
}

.exam--plainbox #quiz-actions {
	position: sticky;
	bottom: 0;
	z-index: 2;
	flex-wrap: nowrap;
	padding-block: 0.375rem;
	background: var(--neutrals-white);
}

.exam--plainbox #quiz .ti-slot,
.exam--plainbox #quiz .ti-number__input {
	scroll-margin-block: 0.5rem 11rem;
}

/* Years 1 and 2 on a phone: the Study Helper starts as a small bar, and the header and title give way, so the answer buttons are in
   sight without scrolling. Show chat opens it as usual. */
@media (max-width: 61.99875em) {
	.exam--plainbox.exam--topic .side-progress__line,
	.exam--plainbox.exam--topic .side-progress__block,
	.exam--plainbox.exam--smart .side-progress__line,
	.exam--plainbox.exam--smart .side-progress__block {
		display: none;
	}

	.exam--plainbox .side-progress {
		padding-block: 0.25rem;
	}

	.exam--plainbox .right-side {
		min-height: 0;
		padding: 0.25rem 1rem;
	}

	.exam--plainbox .right-side:not(.is-chat-open) .right-side__body {
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		display: flex;
	}

	.exam--plainbox .right-side:not(.is-chat-open) .tutor-log,
	.exam--plainbox .right-side:not(.is-chat-open) .right-side__area,
	.exam--plainbox .right-side:not(.is-chat-open) .chat__item:not([data-toggle-chat]) {
		display: none;
	}

	.exam--plainbox .right-side:not(.is-chat-open) .tutor-head,
	.exam--plainbox .right-side:not(.is-chat-open) .right-side__chat {
		margin: 0;
		padding: 0;
		overflow: visible;
	}

	.exam--plainbox .right-side:not(.is-chat-open) .chat__item[data-toggle-chat] {
		min-height: 2.75rem;
	}

	.exam--plainbox #quiz .quiz-card__header {
		margin-bottom: 0.5rem;
	}

	.exam--plainbox #quiz .quiz-card__title {
		font-size: 1.125rem;
		line-height: 1.3;
	}

	.exam--plainbox #quiz {
		padding: 0.75rem 1rem 1.5rem;
	}

	.exam--plainbox #quiz .quiz-card__result {
		margin-bottom: 0.5rem;
	}

	.exam--plainbox .quiz-figure {
		margin-bottom: 0.625rem;
		padding: 0.25rem;
	}

	.exam--plainbox .quiz-figure img {
		max-height: var(--figure-max, 11rem);
		width: auto;
		margin-inline: auto;
	}

	.exam--plainbox .skill-links {
		margin-bottom: 0.5rem;
	}

	/* The title, notes and question count share a line. */
	.exam--plainbox #quiz .quiz-card__header,
	.exam--plainbox #quiz .quiz-card__heading {
		display: flex;
		flex-direction: row;
		flex-wrap: wrap;
		align-items: center;
		justify-content: flex-start;
		gap: 0.25rem 0.75rem;
	}

	.exam--plainbox #quiz .quiz-card__heading > * {
		margin: 0;
	}

	.exam--plainbox .quiz-card__text p + p {
		margin-top: 0.375rem;
	}

	.exam--plainbox .instant-box {
		margin-bottom: 0.5rem;
	}

	.exam--plainbox .ti-parts {
		gap: 0.5rem;
		margin-bottom: 0.5rem;
	}

	.exam--plainbox .ti-slot {
		padding: 0.25rem 0.5rem 0.5rem;
	}

	.exam--plainbox .ti-slot__label {
		margin-bottom: 0.25rem;
	}

	/* A number's label and box share a line. */
	.exam--plainbox .ti-slot--number {
		display: flex;
		align-items: center;
		gap: 0.625rem;
		padding: 0.25rem 0.5rem;
	}

	.exam--plainbox .ti-slot--number .ti-slot__label {
		flex: 1 1 0;
		min-width: 0;
		margin: 0;
	}

	.exam--plainbox .ti-slot--number .ti-slot__body,
	.exam--plainbox .ti-slot--number > .ti-typed__box {
		flex: 0 0 7.5rem;
		width: 7.5rem;
	}

	.exam--plainbox .ti-slot .ti-number__input {
		height: 3rem;
		padding: 0 0.25rem;
		font-size: 1.5rem;
	}

	.exam--plainbox .ti-number__input {
		height: 3.25rem;
	}

	.exam--plainbox .ti-number__box {
		margin-bottom: 0.375rem;
	}

	/* Two rows of keys, not four, on the skill pages too. */
	.ti-number,
	.ti-pad--shared {
		max-width: 30rem;
	}

	.ti-pad {
		grid-template-columns: repeat(6, 1fr);
		gap: 0.25rem;
	}

	.ti-key {
		min-height: 3rem;
		font-size: 1.5rem;
	}

	.ti-key--del {
		grid-column: 6;
		grid-row: 1 / span 2;
	}

	.ti-pad--colon .ti-key--del {
		grid-row: 1;
	}

	.ti-key--next {
		grid-column: 6;
		grid-row: 2;
	}
}

/* ---------- Quick practice skills in the side menu ----------
   Each topic's own skills sit under it as sub-topics (examskillmenu in exam-skills.inc), folded except under the
   current topic or skill. The design script's spollers slide them, as it does the units; it toggles --spoller-active
   on the summary. Rows are as tall as the topic rows above them. */
.topic-skills {
	padding-left: 1.625rem;
}

.topic-group__label ~ .topic-skills {
	padding-left: 2.375rem;
}

/* hidden with its topic by the menu's filters */
.topic-item[hidden] + .topic-skills {
	display: none;
}

.topic-skills__head {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	min-height: 2.25rem;
	padding: 0.25rem 0.875rem 0.25rem 0;
	cursor: pointer;
	font-size: 0.8125rem;
	font-weight: 500;
	color: var(--blue-1);
}

.topic-skills__head::before {
	content: "";
	flex: 0 0 auto;
	width: 0.375rem;
	height: 0.375rem;
	margin: 0 0.125rem 0 0.125rem;
	border-right: 0.125rem solid currentColor;
	border-bottom: 0.125rem solid currentColor;
	transform: rotate(-45deg);
	transition: transform 0.3s;
}

.topic-skills__head.--spoller-active::before {
	transform: rotate(45deg);
}

.topic-skills__count {
	margin-left: auto;
	font-size: 0.75rem;
	font-weight: 400;
	color: var(--neutrals-3);
	white-space: nowrap;
}

.topic-skills__list {
	margin: 0 0 0.375rem 0.3125rem;
	padding: 0;
	list-style: none;
	border-left: 0.125rem solid var(--neutrals-4);
}

.topic-skill {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	min-height: 2.5rem;
	padding: 0.375rem 0.875rem 0.375rem 0.75rem;
	font-size: 0.875rem;
	font-weight: 300;
	line-height: 1.4;
	color: var(--neutrals-2);
	transition: color 0.3s, background-color 0.3s;
}

.topic-skill:hover,
.topic-skill:focus-visible {
	color: var(--blue-1);
}

.topic-skill--active {
	background: var(--neutrals-4);
	color: var(--neutrals-1);
	font-weight: 400;
}

.topic-skill__score {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 0.25rem;
	font-size: 0.75rem;
	font-weight: 500;
	color: var(--neutrals-3);
}

/* ---------- "About this skill" on a skill page ----------
   Under the practice: the topic landing styles (exam-app.css), with example questions from the generators
   (skill-examples/<skill>.html). */
.skill-about {
	margin-top: 3rem;
	padding-top: 2rem;
	border-top: 0.0625rem solid var(--neutrals-4);
}

.skill-example__figure svg {
	display: block;
	max-width: 100%;
	height: auto;
	margin: 0 auto;
}

.skill-example__figure--answer svg {
	max-width: 10rem;
	margin: 0.5rem 0 0;
}

.skill-example__say {
	margin: 0.5rem 0;
	font-style: italic;
}

/* The sum or count a skill question shows large (big), or a column sum's numbers, which are only in the grid on the skill page. */
.skill-example__big {
	margin: 0.5rem 0;
	font-size: 1.5rem;
	font-weight: 500;
	line-height: 1.3;
}

.skill-example__list {
	margin: 0.75rem 0;
}

.skill-example__list h4 {
	margin-bottom: 0.375rem;
	font-size: 0.875rem;
	font-weight: 500;
	color: var(--neutrals-2);
}

.skill-example__list ul {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.skill-example__list li {
	padding: 0.375rem 0.75rem;
	border: 0.0625rem solid var(--neutrals-4);
	border-radius: 0.5rem;
	background: var(--neutrals-white);
	line-height: 1.4;
}

.skill-example__list li.skill-example__pic {
	padding: 0.25rem;
}

.skill-example__pic svg {
	display: block;
	width: 4.5rem;
	height: auto;
}

.skill-about__links {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.25rem;
	margin: 0.5rem 0 0;
	padding: 0;
	list-style: none;
}

.skill-about__links a {
	font-weight: 500;
	color: var(--blue-1);
}

/* Year 2 on a computer: questions have several number boxes, and the pad stays in sight. A box and its label share a line, so that
   fewer boxes go behind the pad, and the pad is the full width, so that none shows round its edge. */
@media (min-width: 62em) {
	.exam--slotrows .ti-slot--number {
		display: flex;
		align-items: center;
		gap: 0.625rem;
		padding: 0.25rem 0.5rem;
	}

	.exam--slotrows .ti-slot--number .ti-slot__label {
		flex: 1 1 0;
		min-width: 0;
		margin: 0;
	}

	.exam--slotrows .ti-slot--number .ti-slot__body,
	.exam--slotrows .ti-slot--number > .ti-typed__box {
		flex: 0 0 9rem;
		width: 9rem;
	}

	.exam--slotrows .ti-slot .ti-number__input {
		height: 3rem;
		padding: 0 0.25rem;
		font-size: 1.5rem;
	}

	.exam--slotrows #quiz .ti-pad--shared {
		max-width: none;
	}
}

/* Year 2: a word such as "minutes" after a box leaves the box room to tap, and six or more short options take two rows. */
.exam--slotrows .ti-slot--number .ti-slot__body:has(.ti-number__unit),
.exam--slotrows .ti-slot--number > .ti-typed__box:has(.ti-number__unit) {
	flex: 0 1 auto;
	width: auto;
}

.exam--slotrows .ti-slot--number .ti-number__input {
	flex: 0 0 4.5rem;
	width: 4.5rem;
}

.exam--slotrows .ti-slot--number .ti-slot__body:not(:has(.ti-number__unit)) .ti-number__input {
	flex: 1 1 auto;
	width: auto;
}

.exam--slotrows .ti-slot .ti-number__unit {
	font-size: 1.25rem;
}

.exam--slotrows .ti-slot .ti-choices--row.ti-choices--many {
	grid-template-columns: repeat(4, minmax(0, 1fr));
	grid-auto-flow: row;
}

/* ---------- Year 3: boxes that share a pad ---------- */

.ti-box {
	flex: none;
	width: 3.5rem;
	padding: 0;
}

.ti-box.is-active {
	border-color: var(--blue-1);
	box-shadow: 0 0 0 0.125rem var(--blue-3);
}

.ti-fraction__row,
.ti-time__row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem;
	margin-bottom: 0.625rem;
}

.ti-fraction__stack {
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	gap: 0.25rem;
}

.ti-fraction__bar {
	display: block;
	width: 100%;
	height: 0.1875rem;
	border-radius: 0.125rem;
	background: var(--neutrals-1);
}

.ti-fraction .ti-box {
	height: 3rem;
	font-size: 1.625rem;
}

.ti-time .ti-box {
	width: 4rem;
	height: 3.25rem;
	font-size: 1.75rem;
}

.ti-time__colon {
	font-size: 2rem;
	font-weight: 700;
	line-height: 1;
}

.ti-ampm {
	display: inline-flex;
	gap: 0.25rem;
	margin-left: 0.25rem;
}

.ti-ampm__btn {
	min-width: 3.25rem;
	min-height: 3.25rem;
	border: 0.125rem solid var(--blue-2);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.25rem;
	font-weight: 500;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-ampm__btn[aria-pressed="true"] {
	border-color: var(--blue-1);
	background: var(--blue-1);
	color: var(--neutrals-white);
}

.ti-ampm__btn:focus-visible {
	outline: 0.1875rem solid var(--blue-1);
	outline-offset: 0.125rem;
}

.ti-column__grid {
	display: grid;
	grid-template-columns: repeat(var(--columns), 3rem);
	align-items: center;
	justify-items: center;
	gap: 0.125rem;
	margin-bottom: 0.625rem;
	font-size: 1.625rem;
	font-weight: 500;
}

.ti-column__note {
	align-self: center;
	font-size: 0.6875rem;
	font-weight: 400;
	line-height: 1.1;
	color: var(--neutrals-2);
	text-align: center;
}

.ti-column__digit,
.ti-column__op {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 2.25rem;
}

.ti-column__rule {
	grid-column: 1 / -1;
	width: 100%;
	height: 0.1875rem;
	border-radius: 0.125rem;
	background: var(--neutrals-1);
}

.ti-column .ti-box {
	width: 3rem;
	height: 3rem;
	font-size: 1.625rem;
}

.ti-column .ti-box--small {
	border-width: 0.0625rem;
	border-style: dashed;
	background: var(--neutrals-6);
	font-size: 1rem;
}

.ti-number.is-right .ti-box--small,
.ti-number.is-wrong .ti-box--small {
	border-color: var(--blue-3);
	background: var(--neutrals-6);
}

.ti-slot .ti-fraction__row,
.ti-slot .ti-time__row,
.ti-slot .ti-column__grid {
	margin: 0;
}

/* A clock set to the minute, and Roman numerals. */
.ti-clock__nudge {
	display: flex;
	justify-content: center;
	gap: 0.5rem;
	margin-bottom: 0.5rem;
}

.ti-clock__nudge .ti-line__btn {
	min-height: 3rem;
	padding: 0 1rem;
	font-size: 1rem;
}

.ti-clock__num--roman {
	font-size: 1rem;
	font-family: Georgia, "Times New Roman", serif;
}

/* A bar chart: one bar that goes up in the scale's steps. */
.ti-chart__bar {
	margin: 0 0.625rem;
}

.ti-chart--bar .ti-chart__axis {
	flex-basis: 1.75rem;
}

/* Phones: the boxes keep their 48 px, and the pad is close by. */
@media (max-width: 26rem) {
	.exam--plainbox #quiz .ti-column__grid {
		gap: 0;
	}

	.exam--plainbox #quiz .ti-column__digit,
	.exam--plainbox #quiz .ti-column__op {
		height: 1.875rem;
	}
}

/* Fractions and times in a many-part question: a label and its boxes share a line, and a fraction lies on its side on a phone. */
.ti-slot--cells {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.25rem 0.625rem;
}

.ti-slot--cells .ti-slot__label {
	flex: 1 1 6rem;
	min-width: 0;
	margin: 0;
}

.ti-slot--cells .ti-slot__body {
	flex: none;
}

.ti-slot .ti-time__row,
.ti-slot .ti-fraction__row {
	flex-wrap: nowrap;
}

.ti-slot .ti-box {
	width: 3.25rem;
}

@media (max-width: 47.99875em) {
	.ti-slot .ti-fraction__stack {
		flex-direction: row;
		gap: 0.375rem;
	}

	.ti-slot .ti-fraction__bar {
		flex: none;
		width: 0.1875rem;
		height: 2.25rem;
		transform: rotate(18deg);
	}

	.exam--plainbox .ti-slot--cells {
		padding: 0.25rem 0.5rem;
	}
}

/* Only the slot being typed in shows its active box. */
.ti-slot:not(.is-active) .ti-box.is-active {
	border-color: var(--blue-2);
	box-shadow: none;
}

/* ---------- Year 4: decimals, money and negative numbers, short multiplication, coordinates, Roman numerals, squares to colour ---------- */

.ti-key--point,
.ti-key--minus {
	font-weight: 700;
}

/* A decimal box holds a few more characters than a whole number's. */
.ti-decimal .ti-number__input {
	min-width: 7rem;
}

/* In a slot a decimal box keeps its own width, so its pound and pence buttons stay beside it on a phone. */
.ti-slot .ti-decimal .ti-number__input {
	flex: none;
	width: 7.5rem;
	min-width: 0;
}

.ti-money {
	flex: none;
	margin-left: 0.375rem;
}

/* On a phone the pad keeps its two rows: the point or minus key takes the place of the colon key, under delete. */
@media (max-width: 61.99875em) {
	.ti-pad--point .ti-key--del,
	.ti-pad--minus .ti-key--del {
		grid-row: 1;
	}

	.ti-key--point,
	.ti-key--minus {
		grid-column: 6;
		grid-row: 2;
	}

	/* two or three extra keys share a third row, as in a round's plain boxes above */
	.ti-pad--point.ti-pad--minus .ti-key--del,
	.ti-pad--colon.ti-pad--point .ti-key--del,
	.ti-pad--colon.ti-pad--minus .ti-key--del {
		grid-row: 1 / span 2;
	}

	.ti-pad--point.ti-pad--minus .ti-key--point,
	.ti-pad--colon.ti-pad--point .ti-key--point,
	.ti-pad--colon.ti-pad--minus .ti-key--minus {
		grid-column: 1 / span 3;
		grid-row: 3;
	}

	.ti-pad--point.ti-pad--minus .ti-key--minus,
	.ti-pad--colon.ti-pad--point .ti-key--next,
	.ti-pad--colon.ti-pad--minus .ti-key--next {
		grid-column: 4 / span 3;
		grid-row: 3;
	}

	.ti-pad--colon.ti-pad--point.ti-pad--minus .ti-key--point {
		grid-column: 1 / span 2;
	}

	.ti-pad--colon.ti-pad--point.ti-pad--minus .ti-key--minus {
		grid-column: 3 / span 2;
	}

	.ti-pad--colon.ti-pad--point.ti-pad--minus .ti-key--next {
		grid-column: 5 / span 2;
	}
}

/* Coordinates read into ( , ). */
.ti-coord__row {
	display: flex;
	align-items: center;
	gap: 0.375rem;
	margin-bottom: 0.625rem;
}

.ti-coord__mark {
	font-size: 2rem;
	font-weight: 500;
	line-height: 1;
}

.ti-coord .ti-box {
	width: 3.25rem;
	height: 3.25rem;
	font-size: 1.75rem;
}

.ti-slot .ti-coord__row {
	margin: 0;
}

/* Points to plot on a grid: one target that snaps to the nearest point, with arrow buttons to move the marker. */
.ti-plot__grid {
	display: block;
	max-width: 100%;
	border-radius: 0.5rem;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-plot__grid svg {
	display: block;
	max-width: 100%;
	height: auto;
}

.ti-plot__grid:focus-visible {
	outline: 0.1875rem solid var(--blue-1);
	outline-offset: 0.125rem;
}

.ti-plot__line {
	stroke: #c5cfdb;
	stroke-width: 1;
}

.ti-plot__axis {
	stroke: var(--neutrals-1);
	stroke-width: 2;
}

.ti-plot__num {
	font-size: 15px;
	fill: var(--neutrals-1);
}

.ti-plot__point {
	fill: var(--blue-1);
}

.ti-plot__given {
	fill: #6f7f92;
}

.ti-plot__ring {
	fill: none;
	stroke: var(--blue-1);
	stroke-width: 2.5;
	stroke-dasharray: 4 3;
}

.ti-plot__nudge {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0.5rem 0 0.625rem;
}

.ti-plot__nudge .ti-line__btn {
	min-width: 3rem;
	padding: 0 0.75rem;
	font-size: 1.375rem;
}

.ti-plot__nudge .ti-plot__mark {
	font-size: 1rem;
}

.ti-plot.is-right .ti-plot__grid {
	box-shadow: 0 0 0 0.1875rem var(--green-1);
}

.ti-plot.is-wrong .ti-plot__grid {
	box-shadow: 0 0 0 0.1875rem #c8402f;
}

/* A Roman numeral: its own five letter keys and delete. */
.ti-roman .ti-number__input {
	min-width: 9rem;
	font-family: Georgia, "Times New Roman", serif;
	letter-spacing: 0.08em;
}

.ti-pad--roman {
	grid-template-columns: repeat(3, 1fr);
	max-width: 20rem;
}

.ti-key--roman {
	font-family: Georgia, "Times New Roman", serif;
}

/* Two rows of three on a phone too: six in a row would be under 48 px inside a slot. */
@media (max-width: 61.99875em) {
	.ti-pad--roman .ti-key--del {
		grid-column: auto;
		grid-row: auto;
	}
}

/* Squares to colour, named by column letter and row number, with mirror lines drawn over them. */
.ti-cells__grid,
.ti-cells__cols {
	position: relative;
	display: grid;
	grid-template-columns: 1.25rem repeat(var(--cols), minmax(2.75rem, 3rem));
	gap: 0;
	width: max-content;
	max-width: 100%;
}

.ti-cells__cols {
	margin-bottom: 0.625rem;
	padding-top: 0.25rem;
}

.ti-cells__cell {
	aspect-ratio: 1;
	min-height: 2.75rem;
	margin: 0;
	padding: 0;
	border: 0.0625rem solid #9aa8b8;
	background: var(--neutrals-white);
	cursor: pointer;
	touch-action: manipulation;
}

.ti-cells__cell[aria-pressed="true"] {
	background: var(--blue-1);
}

.ti-cells__cell.is-given {
	background: #6f7f92;
	cursor: default;
}

.ti-cells__cell:focus-visible {
	position: relative;
	z-index: 2;
	outline: 0.1875rem solid #e8833a;
	outline-offset: -0.1875rem;
}

.ti-cells__row,
.ti-cells__col {
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 0.9375rem;
	color: var(--neutrals-1);
}

.ti-cells__lines {
	position: absolute;
	top: 0;
	left: 1.25rem;
	width: calc(100% - 1.25rem);
	height: 100%;
	pointer-events: none;
	overflow: visible;
}

.ti-cells__lines line {
	stroke: #c8402f;
	stroke-width: 0.06;
	stroke-dasharray: 0.18 0.12;
}

.ti-cells.is-right .ti-cells__grid {
	box-shadow: 0 0 0 0.1875rem var(--green-1);
}

.ti-cells.is-wrong .ti-cells__grid {
	box-shadow: 0 0 0 0.1875rem #c8402f;
}

/* Year 4: a fraction in hundredths takes three digits above and below the line. */
.ti-fraction--big .ti-box,
.ti-slot .ti-fraction--big .ti-box {
	width: 4.5rem;
}

/* Part D (Year 4): a timed question's timer: a bar that shrinks over the time, the seconds left, and the switch that turns it off. */
.skill-timer {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem 0.75rem;
	margin: 0 0 0.75rem;
}

.skill-timer[hidden] {
	display: none;
}

.skill-timer__bar {
	flex: 1 1 8rem;
	height: 0.75rem;
	border-radius: 0.375rem;
	background: var(--neutrals-5);
	overflow: hidden;
}

.skill-timer__fill {
	display: block;
	width: 100%;
	height: 100%;
	background: var(--blue-1);
}

.skill-timer__left {
	min-width: 5.5rem;
	font-weight: 600;
}

.skill-timer__switch {
	min-height: 3rem;
}

/* ---------- Year 5 (newcourses/interactive-year5/DESIGN.md section 3) ---------- */

/* A column grid of 7 columns or more (a 6-digit sum, long multiplication of 3 or 4 digits): the boxes shrink to fit a phone, down to 40 px. */
.ti-column--wide .ti-column__grid {
	grid-template-columns: repeat(var(--columns), minmax(2.5rem, 3rem));
	max-width: 100%;
}

.ti-column--wide .ti-box {
	width: 100%;
	max-width: 3rem;
}

/* Long multiplication: the carry boxes over each row are shorter, as they are the child's own notes. */
.ti-longmult .ti-box--small {
	height: 2rem;
}

/* Short division, the bus stop: the divisor, the bracket over the number's digits, a small carry box before each digit after the first,
   and the answer's boxes above them, then r and the remainder. */
.ti-busstop__grid {
	display: grid;
	grid-template-columns: 2.5rem repeat(var(--digits), 3.25rem) 1.5rem 3rem;
	align-items: center;
	justify-items: center;
	row-gap: 0.25rem;
	margin-bottom: 0.625rem;
	font-size: 1.625rem;
	font-weight: 500;
}

.ti-busstop .ti-box {
	width: 3rem;
	height: 3rem;
	font-size: 1.625rem;
}

.ti-busstop__divisor {
	justify-self: end;
	padding-right: 0.375rem;
}

.ti-busstop__digit {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: flex-end;
	width: 100%;
	height: 3.25rem;
	padding-right: 0.5rem;
	border-top: 0.1875rem solid var(--neutrals-1);
}

.ti-busstop__digit--first {
	border-left: 0.1875rem solid var(--neutrals-1);
	border-top-left-radius: 0.75rem;
}

.ti-busstop .ti-box--small.ti-busstop__carry {
	position: absolute;
	top: 0.25rem;
	left: 0.125rem;
	width: 1.625rem;
	height: 2rem;
	border-width: 0.0625rem;
	border-style: dashed;
	background: var(--neutrals-6);
	font-size: 1rem;
}

.ti-busstop__r {
	font-size: 1.25rem;
}

.ti-slot .ti-busstop__grid {
	margin: 0;
}

/* Roman numerals to M: the seven letter keys and delete, in two rows of four. */
.ti-pad--roman7,
.exam--plainbox #quiz .ti-pad--roman7 {
	grid-template-columns: repeat(4, 1fr);
}

/* A grid to plot on, with the shape a reflection or translation starts from, and mirror lines. */
.ti-plot__shape {
	fill: rgba(80, 134, 219, 0.18);
	stroke: var(--neutrals-1);
	stroke-width: 2.5;
	stroke-linejoin: round;
}

.ti-plot__mirror {
	stroke: #c8402f;
	stroke-width: 2.5;
	stroke-dasharray: 8 5;
}

/* Squares to colour, more than 6 columns: 48 px squares, the grid scrolling sideways in its own box on a narrow phone. */
.ti-cells--wide {
	overflow-x: auto;
	padding-bottom: 0.25rem;
}

.ti-cells--wide .ti-cells__grid,
.ti-cells--wide .ti-cells__cols {
	grid-template-columns: 1.25rem repeat(var(--cols), 3rem);
	max-width: none;
}

/* A protractor to set an angle on. */
.ti-scale--protractor .ti-scale__track {
	max-width: 30rem;
	background: var(--neutrals-white);
}

/* ---------- Year 6 (newcourses/interactive-year6/DESIGN.md section 3) ---------- */

/* Short division by 10 to 99: the carry boxes take two digits, so the digit sits a little further right. */
.ti-busstop--wide .ti-busstop__digit {
	padding-right: 0.25rem;
}

.ti-busstop--wide .ti-box--small.ti-busstop__carry {
	width: 1.875rem;
	font-size: 0.875rem;
}

/* Long division: under the number, for each step, a row to take away (after a minus sign, ruled off) and a row for what is left. */
.ti-longdiv__op {
	justify-self: end;
	padding-right: 0.375rem;
	font-size: 1.5rem;
}

.ti-longdiv__cell {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 3.25rem;
}

.ti-longdiv__cell--sub {
	border-bottom: 0.125rem solid var(--neutrals-1);
}

/* Coordinates in four quadrants: room for a minus sign in each box. */
.ti-coord--sign .ti-box {
	width: 3.75rem;
}

/* Years 4 to 6 in a round (EXAM_PAD_CARD_STAGES, exam--padcard): the answer box and the box around it lay their children out on the
   question card itself, so the number pad, moved to the end of the answer box (js/exam-instant.js padToCard), is pinned to the card
   and stays above the Check bar however low a long question starts its answer. */
.exam--padcard #quiz .quiz-card__box,
.exam--padcard #quiz .instant-box:not([hidden]) {
	display: contents;
}

.exam--padcard #quiz .instant-box:not([hidden]) > :not(.ti-pad) {
	margin-bottom: 1rem;
}

.exam--plainbox #quiz .ti-pad--card.is-locked {
	position: static;
}

/* Review 1 (5.2 Q18): a question that starts with choices and has a box later keeps its card pad in place at the end of the card,
   not pinned over the choices, until a box it types in is tapped or one of its keys is pressed (js/exam-instant.js partsWidget). */
.exam--plainbox #quiz .ti-pad--card.ti-pad--wait {
	position: static;
}

@media (max-width: 61.99875em) {
	.exam--padcard #quiz .instant-box:not([hidden]) > :not(.ti-pad) {
		margin-bottom: 0.5rem;
	}
}

/* ---------- Year 7 (interactive-year7/DESIGN.md section 3): the expression box, the inequality line, lists, tables, lines ---------- */

.ti-expr {
	max-width: 24rem;
	margin: 0 0 1rem;
}

.ti-expr__box {
	position: relative;
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-bottom: 0.25rem;
}

/* the real input, for the keyboard and screen readers, sits under the maths shown in the box */
.ti-expr__input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	font-size: 1rem;
	cursor: text;
}

.ti-expr__show {
	flex: 1 1 auto;
	min-width: 0;
	min-height: 4rem;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	padding: 0.25rem 1rem;
	border: 0.125rem solid var(--blue-2);
	border-radius: 0.75rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font-size: 1.875rem;
	font-weight: 500;
	line-height: 1.2;
	text-align: center;
	word-break: break-all;
	pointer-events: none;
}

.ti-expr__show i {
	font-family: "Times New Roman", Georgia, serif;
	font-size: 1.15em;
	padding: 0 0.04em;
}

.ti-expr__show sup,
.ti-pad--expr sup {
	position: relative;
	top: -0.55em;
	font-size: 0.62em;
	line-height: 0;
	vertical-align: baseline;
}

/* the delete key takes one cell here (the number pad's own takes two rows) */
.ti-pad.ti-pad--expr .ti-key--del,
.ti-pad.ti-pad--list .ti-key--del {
	grid-row: auto;
	grid-column: auto;
}

.ti-expr__hint {
	color: var(--neutrals-3, #6b7280);
	font-size: 1.125rem;
	font-weight: 400;
}

.ti-expr__caret {
	display: none;
	width: 0.125rem;
	height: 1.9rem;
	margin-left: 0.1rem;
	background: var(--blue-1);
	animation: ti-expr-blink 1s step-end infinite;
}

.ti-expr.is-focus .ti-expr__caret {
	display: inline-block;
}

.ti-expr.is-focus .ti-expr__show {
	box-shadow: 0 0 0 0.1875rem var(--blue-3);
}

@keyframes ti-expr-blink {
	50% {
		opacity: 0;
	}
}

.ti-expr__msg {
	min-height: 1.4rem;
	margin: 0 0 0.375rem;
	color: #a1301f;
	font-size: 0.9375rem;
}

.ti-expr.is-right .ti-expr__show {
	border-color: var(--green-1);
	background: var(--green-3);
}

.ti-expr.is-wrong .ti-expr__show {
	border-color: #c8402f;
	background: #fdecea;
}

/* five keys a row: on a 360 px phone, inside the page's and the card's gutters, each key is about 52 px. (The selectors name .ti-pad
   twice, so they win over exam-instant.css's phone rules, ".ti-pad { six a row }" and ".exam--skill .ti-pad", wherever this block
   is put: Review 1, K 23.) */
.ti-pad.ti-pad--expr,
.ti-pad.ti-pad--list {
	grid-template-columns: repeat(5, 1fr);
	gap: 0.375rem;
}

.ti-pad.ti-pad--expr .ti-key,
.ti-pad.ti-pad--list .ti-key {
	min-height: 3.25rem;
	min-width: 0;
	font-size: 1.375rem;
}

.ti-key--letter i {
	font-family: "Times New Roman", Georgia, serif;
	font-size: 1.25em;
}

.ti-key--op,
.ti-key--rel {
	background: var(--blue-4);
}

.ti-key--rel {
	grid-column: span 1;
}

.ti-pad.ti-pad--list .ti-key--lnext {
	grid-column: span 2;
	font-size: 1.125rem;
}

.ti-key--lsign {
	background: var(--blue-4);
}

/* the inequality line */

.ti-ineq {
	max-width: 40rem;
	margin: 0 0 1rem;
}

.ti-ineq__modes,
.ti-ineq__tools {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0 0 0.5rem;
}

.ti-ineq__mode {
	min-height: 3rem;
}

.ti-ineq__mode[aria-pressed="true"] {
	background: var(--blue-1);
	color: var(--neutrals-white);
}

.ti-ineq__fill {
	min-height: 3rem;
}

/* what to do next, for a child who can see the line (a tap before choosing where the line goes puts a circle there) */
.ti-ineq__hint {
	min-height: 1.4rem;
	margin: 0 0 0.25rem;
	color: var(--neutrals-2, #4b5563);
	font-size: 0.9375rem;
}

.ti-ineq.is-locked .ti-ineq__hint {
	display: none;
}

/* drawn at its own width in pixels (js: 24 to 44 px between marks), so it is never shrunk; a line too long for its box scrolls */
.ti-ineq__line {
	min-width: 0;
	overflow-x: auto;
	padding: 0.25rem 0;
	border-radius: 0.5rem;
	cursor: pointer;
	touch-action: manipulation;
}

.ti-ineq__line:focus-visible {
	outline: 0.1875rem solid var(--blue-2);
}

.ti-ineq__line svg {
	display: block;
	max-width: none;
}

.ti-ineq__axis,
.ti-ineq__tick {
	stroke: #2e3d52;
	stroke-width: 3;
}

.ti-ineq__num {
	fill: #2e3d52;
	font-size: 15px;
}

.ti-ineq__ray {
	stroke: var(--blue-1, #1f5fbf);
	stroke-width: 7;
	stroke-linecap: round;
}

.ti-ineq__head {
	fill: var(--blue-1, #1f5fbf);
}

.ti-ineq__circle {
	fill: #ffffff;
	stroke: #2e3d52;
	stroke-width: 3.5;
}

.ti-ineq__circle.is-filled {
	fill: #2e3d52;
}

.ti-ineq__ring {
	fill: none;
	stroke: #f0a020;
	stroke-width: 3;
}

.ti-ineq.is-right .ti-ineq__line {
	background: var(--green-3);
}

.ti-ineq.is-wrong .ti-ineq__line {
	background: #fdecea;
}

/* a list of entries */

.ti-list {
	max-width: 24rem;
	margin: 0 0 1rem;
}

.ti-list__rows {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 0.5rem;
	margin: 0 0 0.625rem;
	padding: 0;
	list-style: none;
	counter-reset: ti-list;
}

.ti-list__row {
	display: flex;
	align-items: center;
	gap: 0.375rem;
	counter-increment: ti-list;
}

.ti-list__row::before {
	content: counter(ti-list) ".";
	min-width: 1.4rem;
	color: var(--neutrals-3, #6b7280);
	font-size: 0.9375rem;
	text-align: right;
}

.ti-list__input {
	flex: 1 1 auto;
	min-width: 0;
	height: 3rem;
	padding: 0 0.5rem;
	border: 0.125rem solid var(--blue-3);
	border-radius: 0.625rem;
	background: var(--neutrals-white);
	color: var(--neutrals-1);
	font: inherit;
	font-size: 1.5rem;
	font-weight: 500;
	text-align: center;
}

.ti-list__row.is-active .ti-list__input {
	border-color: var(--blue-1);
	box-shadow: 0 0 0 0.1875rem var(--blue-3);
}

.ti-list.is-right .ti-list__input {
	border-color: var(--green-1);
	background: var(--green-3);
}

.ti-list.is-wrong .ti-list__input {
	border-color: #c8402f;
	background: #fdecea;
}

/* a row left unfinished (a lone minus sign or point) */
.ti-list__msg {
	min-height: 1.4rem;
	margin: 0 0 0.375rem;
	color: #a1301f;
	font-size: 0.9375rem;
}

/* slots in a table, in a box that scrolls sideways only if a table is ever too wide for it, never the page */

.ti-table-wrap {
	max-width: 32rem;
	margin: 0 0 0.75rem;
	overflow-x: auto;
}

.ti-table {
	width: 100%;
	margin: 0;
	border-collapse: collapse;
	font-size: 1.0625rem;
}

.ti-table th,
.ti-table td {
	padding: 0.375rem 0.5rem;
	border: 0.0625rem solid var(--blue-3);
	text-align: center;
	vertical-align: middle;
}

.ti-table thead th {
	background: var(--blue-4);
}

.ti-table tbody th {
	text-align: left;
}

/* (.ti-table is named first so that these win over the round's slot rules, exam-instant.css .exam--slotrows .ti-slot--number, which
   lay a box beside its label at 9rem on a computer) */
.ti-table .ti-slot.ti-slot--intable {
	display: block;
	margin: 0;
	padding: 0;
	border: 0;
}

.ti-slot--intable .ti-slot__label {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

.ti-table .ti-slot--intable .ti-slot__body {
	flex: none;
	width: auto;
}

.ti-slot--intable .ti-number {
	margin: 0;
}

/* Review 1 (K 2): a number box in a table keeps almost none of the box's own side padding (1rem each side), so the digits typed
   are seen in a five-column table on a phone (13.5 Q19, 13.2 Q28): the box fills its cell, 3rem at the least (room for three digits).
   (Its width as a percentage gives the table nothing to grow for, so the table stays the width of the card: in a round,
   exam-instant.css's .exam--slotrows rules give the box width auto, and the table grew to 921 px. The selector is long so that it
   wins over those rules, 5 classes.) */
.ti-table .ti-table__slot .ti-slot.ti-slot--intable .ti-number .ti-number__input {
	flex: 1 1 auto;
	width: 100%;
	min-width: 3rem;
	height: 3rem;
	padding: 0 0.125rem;
	font-size: 1.375rem;
}

/* Review 1: Year 7 is a slot-row stage without the plain boxes (DESIGN section 10). There, exam-instant.css's .exam--slotrows rules
   declare a number or decimal slot's box "width: auto", which Chrome then sizes to the box's own default width, not to the slot
   (measured in proto/formats.html at 390 px: a 375 px box in a 342 px card, so the whole page widened to 451 px and every tap missed).
   The box fills its slot instead. No other stage is a slot-row stage without the plain boxes, so no other year changes. */
.exam--slotrows:not(.exam--plainbox) .ti-slot--number .ti-slot__body:not(:has(.ti-number__unit)) .ti-number__input {
	width: 100%;
}

@media (max-width: 26rem) {
	.ti-table th,
	.ti-table td {
		padding: 0.25rem 0.125rem;
	}

	.ti-table {
		font-size: 1rem;
	}
}

/* a straight line through plotted points */

.ti-plot__drawnline {
	stroke: var(--blue-1, #1f5fbf);
	stroke-width: 4;
	stroke-linecap: round;
}

/* (Part 2) A tile's typeset maths does not take taps: KaTeX's boxes for a stacked fraction reach about 45 px above the text, into the
   tile above, and a touch at the middle of that tile went to this one (Chrome's touch adjustment): 4.3 Q8 chose 32/5 for a tap on 17/5.
   With this, a tap goes to the tile drawn there. Every year's tiles that hold maths gain it (Years 4 to 6's fractions too). */
.ti-choice .katex {
	pointer-events: none;
}

/* Review 1 (13 November 2026): a wrapped line of stacked fractions in a question's text touched the line above (4.2 Q13 on a
   phone). The spacing exam-app.css already gives model answers and notes, for Year 7 Maths only (the one stage with slot rows and
   no plain boxes), so no other year's page changes. */
.exam--slotrows:not(.exam--plainbox) .quiz-card__text .katex .base {
	margin-block: 0.2em;
}
