/* =========================================================================
   Mindship Toolkit: the hub (after toolkit.png) and every tool's page.
   Category colours are the handbook's, so the three read as one product.
   ========================================================================= */

/* Sampled from the designs: pastel is the card, strong is the glyph and
   the arrow on it, deep is the darker end used on a tool's own page. The
   glyph and arrow are shapes rather than text, which is why strong can be
   this bright; every word on these cards is navy on the pastel. */
.tk-cat-pdf          { --tk-strong: #EF2A46; --tk-deep: #C8283F; --tk-pastel: #FDF1F2; --tk-shadow: rgba(239, 42, 70, .22); }
.tk-cat-image        { --tk-strong: #0D74F0; --tk-deep: #1B5FCC; --tk-pastel: #E9F4FE; --tk-shadow: rgba(13, 116, 240, .22); }
.tk-cat-academic     { --tk-strong: #8B47F0; --tk-deep: #5B3CC9; --tk-pastel: #F2F0FD; --tk-shadow: rgba(139, 71, 240, .22); }
.tk-cat-ai           { --tk-strong: #0CA8AB; --tk-deep: #0A7F86; --tk-pastel: #EAFAFA; --tk-shadow: rgba(12, 168, 171, .22); }
.tk-cat-career       { --tk-strong: #ED8505; --tk-deep: #B85A07; --tk-pastel: #FEF5E8; --tk-shadow: rgba(237, 133, 5, .22); }
.tk-cat-scholarships { --tk-strong: #EE4F64; --tk-deep: #B8325F; --tk-pastel: #FEF4F6; --tk-shadow: rgba(238, 79, 100, .22); }
.tk-cat-calc         { --tk-strong: #0F6BF5; --tk-deep: #0F6FB8; --tk-pastel: #E3F1FE; --tk-shadow: rgba(15, 107, 245, .22); }

.tk-ic--teal   { background: #d3f5ef; color: #0c8f8c; }
.tk-ic--blue   { background: #dbeafe; color: #1d6fd8; }
.tk-ic--purple { background: #efe8ff; color: #7a4ce0; }
.tk-ic--orange { background: #ffeedd; color: #d9741c; }
.tk-ic--green  { background: #dcf5e7; color: #1f9a57; }

/* --- The hub (October 2026 restyle) ------------------------------------------

   The page is the dashboard's: its grid, banner, stat tiles, section
   headings and rail cards come from account.css, so the sizes match. What
   is here is the Toolkit's own - the category cards, the search row and the
   tool tiles - in the categories' deep colours rather than pastels, so a
   colourful page still has something for the eye to land on. */

/* --- The banner, after toolkit-dash.png ------------------------------------

   A pale banner with the words down the middle and the quote in the bottom
   right corner. The client supplies the picture; until then the waves are
   drawn here, so the banner is finished either way. */

.tk-banner {
	position: relative;
	display: grid;
	place-items: center;
	overflow: hidden;
	isolation: isolate;
	margin-bottom: var(--dash-gap, 20px);
	padding: 12px clamp(18px, 2.6vw, 36px) 14px;
	min-height: 116px;
	border-radius: var(--dash-radius, 14px);
	background:
		radial-gradient(120% 140% at 50% 0%, #FFFFFF 0%, #EFF8FC 42%, #DDF0F6 100%),
		#EAF6FB;
	box-shadow: inset 0 0 0 1px #D6E8F0;
	text-align: center;
}
.tk-banner.has-image {
	background: var(--tk-banner) right bottom / cover no-repeat, #EAF6FB;
	box-shadow: none;
}
@media (max-width: 800px) {
	.tk-banner.has-image {
		background:
			radial-gradient(120% 140% at 50% 0%, #FFFFFF 0%, #EFF8FC 42%, #DDF0F6 100%),
			#EAF6FB;
		box-shadow: inset 0 0 0 1px #D6E8F0;
	}
}

/* The waves, drawn when there is no picture yet. */
.tk-banner:not(.has-image)::before,
.tk-banner:not(.has-image)::after {
	content: "";
	position: absolute;
	z-index: -1;
	top: -30%;
	bottom: -30%;
	width: 26%;
	background: linear-gradient(140deg, #0B2C53 0%, #0E6E86 48%, #19A8B4 100%);
}
.tk-banner:not(.has-image)::before {
	left: -6%;
	border-radius: 0 60% 55% 0 / 0 50% 50% 0;
}
.tk-banner:not(.has-image)::after {
	right: -6%;
	border-radius: 55% 0 0 60% / 50% 0 0 50%;
}

.tk-banner__inner { position: relative; max-width: 680px; }

.tk-banner__badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	margin-bottom: 7px;
	border-radius: 50%;
	background: #D4EFF2;
	color: #0E7C86;
}

.tk-banner__title {
	margin: 0 0 7px;
	font-size: clamp(22px, 2.6vw, 32px);
	font-weight: 800;
	line-height: 1.05;
	letter-spacing: -.02em;
	color: #10226B;
}
.tk-banner__title span { color: #0E8795; }

.tk-banner__lead {
	margin: 0 0 5px;
	font-size: clamp(12.5px, 1.1vw, 14.5px);
	font-weight: 800;
	color: #15296F;
}
.tk-banner__sub {
	margin: 0 auto 13px;
	max-width: 54ch;
	font-size: 12px;
	line-height: 1.5;
	color: #4A5A8C;
}

.tk-banner__cta {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 9px 22px;
	border-radius: 999px;
	background: linear-gradient(100deg, #0E8795 0%, #0A6B7E 100%);
	box-shadow: 0 8px 20px rgba(14, 135, 149, .32);
	font-size: 13px;
	font-weight: 700;
	color: #fff;
	text-decoration: none;
}
.tk-banner__cta:hover { background: linear-gradient(100deg, #0A6B7E 0%, #08566A 100%); color: #fff; }
.tk-banner__cta:focus-visible { outline: 3px solid #10226B; outline-offset: 3px; }

/* --- The three numbers ------------------------------------------------------ */

.dash-stats--3 { grid-template-columns: minmax(0, 1fr); }
@container (min-width: 560px) {
	.dash-stats--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* The chevron sits against the card's right edge, level with the middle -
   not beside the number as it does on the main dashboard. */
.tk-dash .dash-stat { position: relative; align-items: center; padding: 12px 34px 12px 12px; }
.tk-dash .dash-stat__top { display: block; margin: 0; }
.tk-dash .dash-stat__top > svg {
	position: absolute;
	top: 50%;
	right: 12px;
	margin-top: -9px;
	color: #2B45C8;
}
.tk-dash .dash-stat__icon { width: 46px; height: 46px; border-radius: 12px; }
.tk-dash .dash-stat__value { font-size: 23px; color: var(--stat-ink, #1C24D4); }
.tk-dash .dash-stat__value--name { font-size: 15px; line-height: 1.25; color: #10226B; }
.tk-dash .dash-stat__label {
	overflow: visible;
	font-size: 13.5px;
	font-weight: 600;
	white-space: normal;
	color: #4C609D;
}
.dash-stat__note {
	display: block;
	margin-top: 1px;
	font-size: 11.5px;
	line-height: 1.35;
	color: #8893C3;
}

/* On a laptop the column is about 640px, so three tiles are each around
   200px: the icon, the number and the two lines under it all come down a
   step so the words keep their shape instead of stacking up. */
@container (max-width: 739px) {
	.tk-dash .dash-stat { min-height: 72px; padding: 10px 28px 10px 10px; }
	.tk-dash .dash-stat__icon { width: 38px; height: 38px; border-radius: 10px; }
	.tk-dash .dash-stat__icon svg { width: 22px; height: 22px; }
	.tk-dash .dash-stat__value { font-size: 18px; }
	.tk-dash .dash-stat__label { font-size: 12px; line-height: 1.25; }
	.tk-dash .dash-stat__note { font-size: 10px; line-height: 1.3; }
	.tk-dash .dash-stat__top > svg { right: 9px; }
	.tk-dash .dash-stat__value--name {
		display: -webkit-box;
		overflow: hidden;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 2;
		font-size: 13px;
	}
}

/* --- Section headings -------------------------------------------------------- */

.tk-dash .dash-section__title { font-size: 18px; color: #1B22CF; }
/* Up from 12.5px and off the pale lilac: at that size and that contrast the
   lead beside each heading was decoration rather than something anybody was
   going to read. */
.tk-dash .dash-section__title > span:not([class]) { font-size: 14px; line-height: 1.5; color: #6B76A8; }
.tk-dash .dash-section__more { font-size: 13px; color: #1B3DEF; }
.tk-section__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: #4A3FD4;
	color: #fff;
}
.tk-section__icon--star { background: #152A6E; color: #fff; }
.tk-section__icon--all { background: #0E7C86; color: #fff; }

/* --- The search row ----------------------------------------------------------- */

.tk-search__field {
	border-color: #DCE7F4;
	background: #EDF3FA;
	box-shadow: none;
}
.tk-search__field > svg { color: #1B3DEF; }
.tk-search .tk-search__field input[type="search"] { font-size: 13.5px; color: #10226B; }
.tk-search__field input::placeholder { color: #8E98C6; }
.tk-search__go {
	padding: 0 22px;
	border-radius: 12px;
	background: #0A2444;
	font-size: 13.5px;
}
.tk-search__go:hover { background: #10345E; }
.tk-chip {
	min-height: 38px;
	padding: 0 18px;
	border: 1.5px solid #C5D4F3;
	font-size: 12.5px;
	color: #1B3DEF;
}
.tk-chip:hover { border-color: #1B3DEF; background: #F2F6FE; color: #1B3DEF; }
.tk-chip.is-active { border-color: #1668E3; background: #1668E3; color: #fff; }

/* --- Tool tiles: six across, as the design lays them out ---------------------- */

.tk-card__name { color: #10226B; }
.tk-card__desc { color: #8893C1; }

/* --- Categories: seven deep-coloured cards ------------------------------------------ */

.tk-cats {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
	margin: 0;
	padding: 0;
	list-style: none;
}
@container (min-width: 520px) { .tk-cats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
/* Seven in a row, as drawn, once there is room for them (a wide screen);
   below that four. */
@container (min-width: 770px) {
	.tk-cats { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; }
	.tk-cat { min-height: 158px; padding: 13px 11px 11px; }
	/* A seventh of the column is narrow, so the names are set small enough
	   that the longest of them - "Scholarship & Opportunity Tools" - still
	   reads in full, over three lines. */
	.tk-cats .tk-cat__name { -webkit-line-clamp: 3; font-size: 12.5px; letter-spacing: -.01em; }
	.tk-cats .tk-cat__line {
		display: -webkit-box;
		flex: 0 0 auto;
		align-self: stretch;
		max-height: 4.4em;
		overflow: hidden;
		-webkit-box-orient: vertical;
		-webkit-line-clamp: 3;
		font-size: 11.5px;
	}
	.tk-cats .tk-cat { min-height: 150px; }
	.tk-cats .tk-cat__icon svg { width: 26px; height: 26px; }
}

.tk-cats > li { min-width: 0; }
.tk-cat {
	position: relative;
	overflow: hidden;
	isolation: isolate;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 6px;
	width: 100%;
	height: 100%;
	min-height: 164px;
	padding: 16px 14px 14px;
	border: 0;
	border-radius: var(--dash-radius, 14px);
	background: var(--tk-pastel);
	color: var(--dash-navy, #0B2247);
	font: inherit;
	text-align: left;
	cursor: pointer;
	transition: transform .16s ease, box-shadow .16s ease;
}
.tk-cat:hover {
	transform: translateY(-3px);
	box-shadow: var(--dash-shadow-hover);
}
.tk-cat[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--tk-strong) inset, var(--dash-shadow-hover); }
.tk-cat:focus-visible { outline: 3px solid var(--dash-navy, #0B2247); outline-offset: 3px; }
/* The glyph itself, in the category's colour - the design draws no tile
   behind it. */
.tk-cat__icon {
	display: inline-flex;
	margin-bottom: 8px;
	color: var(--tk-strong);
}
.tk-cat__name {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	font-size: 14px;
	font-weight: 800;
	line-height: 1.3;
	color: var(--dash-navy, #0B2247);
}
.tk-cat__line { flex: 1 1 auto; font-size: 12.5px; line-height: 1.5; color: #566E8B; }
.tk-cat__foot {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	width: 100%;
	margin-top: auto;
	padding-top: 6px;
}
.tk-cat__count { font-size: 11px; font-weight: 700; color: #5A7390; }
/* The eighth card: every tool. */
.tk-cat--all {
	--tk-strong: #0D3F8F;
	--tk-deep: #0B2247;
	--tk-pastel: #EAF0FA;
	--tk-shadow: rgba(11, 34, 71, .2);
	text-decoration: none;
}
.tk-cat--all:hover { color: var(--dash-navy, #0B2247); }
.tk-cat__go {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: var(--tk-strong);
	color: #fff;
}

/* --- The search row ---------------------------------------------------------------- */

.tk-search {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 12px;
	margin: 0 0 28px;
}
.tk-search__field {
	display: flex;
	flex: 1 1 320px;
	align-items: center;
	gap: 10px;
	min-width: 0;
	min-height: 44px;
	margin: 0;
	padding: 0 6px 0 14px;
	border: 1px solid #CBD6E6;
	border-radius: 12px;
	background: #fff;
	color: #2C4A78;
	box-shadow: var(--dash-shadow);
	cursor: text;
}
.tk-search__field:focus-within {
	border-color: #0B8F94;
	box-shadow: 0 0 0 3px rgba(11, 143, 148, .15);
}
.tk-search .tk-search__field input[type="search"] {
	flex: 1 1 auto;
	min-width: 0;
	height: 42px;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	font-size: 13.5px;
	color: var(--dash-navy);
	outline: none;
}
.tk-search__field input::placeholder { color: #5E7290; opacity: 1; }
.tk-search__go {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	padding: 0 18px;
	border-radius: 12px;
	background: var(--dash-navy);
	font-size: 13px;
	font-weight: 700;
	color: #fff;
	text-decoration: none;
	white-space: nowrap;
}
.tk-search__go:hover { background: #0D3F8F; color: #fff; }
.tk-search__go:focus-visible { outline: 3px solid #0B8F94; outline-offset: 2px; }
.tk-chips { display: flex; gap: 6px; }
.tk-chip {
	min-height: 36px;
	padding: 0 16px;
	border: 1px solid #CBD6E6;
	border-radius: 999px;
	background: #fff;
	font: inherit;
	font-size: 12.5px;
	font-weight: 700;
	color: var(--dash-navy);
	cursor: pointer;
}
.tk-chip:hover { border-color: #1D5FD1; color: #1D5FD1; }
.tk-chip.is-active { border-color: #1D5FD1; background: #1D5FD1; color: #fff; }
.tk-chip:focus-visible { outline: 3px solid #0B8F94; outline-offset: 2px; }

/* --- Tool tiles ---------------------------------------------------------------------- */

.tk-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 12px;
	margin: 0;
	padding: 0;
	list-style: none;
}
@container (min-width: 440px) { .tk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container (min-width: 640px) { .tk-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@container (min-width: 900px) { .tk-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.tk-card { min-width: 0; }
.tk-card[hidden] { display: none; }
.tk-card__link {
	display: flex;
	align-items: center;
	gap: 12px;
	height: 100%;
	min-height: 66px;
	padding: 12px 14px;
	border: 1px solid var(--dash-line);
	border-radius: 12px;
	background: #fff;
	box-shadow: var(--dash-shadow);
	color: inherit;
	text-decoration: none;
	transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.tk-card__link:hover {
	transform: translateY(-2px);
	border-color: var(--tk-strong);
	box-shadow: var(--dash-shadow-hover);
}
.tk-card__link:focus-visible { outline: 3px solid var(--tk-strong); outline-offset: 2px; }
.tk-card__icon {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border-radius: 10px;
	background: var(--tk-strong);
	color: #fff;
}
.tk-card__text { display: grid; gap: 2px; min-width: 0; }
.tk-card__name { font-size: 13px; font-weight: 800; line-height: 1.3; color: var(--dash-navy); }
.tk-card__desc {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	font-size: 11.5px;
	line-height: 1.4;
	color: var(--dash-slate);
}

/* "View All Tools", the last tile of Popular. */
.tk-card--all .tk-card__link {
	justify-content: center;
	border: 1.5px dashed #8FA6C6;
	background: #F7FAFE;
	box-shadow: none;
	text-align: center;
	color: #1D5FD1;
}
.tk-card--all .tk-card__link:hover { border-color: #1D5FD1; background: #fff; }
.tk-card--all .tk-card__name { color: #1D5FD1; }

/* The heading the filter rewrites, in the heading's own type. */
.dash-section__title > .tk-all__heading { display: inline; font-size: inherit; font-weight: inherit; color: inherit; }
.dash-section__title > .tk-all__heading + span { display: inline; }

.tk-empty {
	margin: 0;
	padding: 22px;
	border: 1.5px dashed #8FA6C6;
	border-radius: 12px;
	background: #F7FAFE;
	font-size: 13px;
	text-align: center;
	color: var(--dash-slate);
}

/* --- The rail ----------------------------------------------------------------------------- */

.tk-rail__title { display: flex; align-items: center; gap: 8px; }
.tk-rail__title svg { color: #1D5FD1; }

.tk-recent { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.tk-recent a {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 6px 6px;
	margin: 0 -6px;
	border-radius: 10px;
	color: inherit;
	text-decoration: none;
}
.tk-recent a:hover { background: #F3F6FB; }
.tk-recent__icon {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 30px;
	height: 30px;
	border-radius: 8px;
	background: var(--tk-strong);
	color: #fff;
}
.tk-recent__name { flex: 1 1 auto; min-width: 0; font-size: 13px; font-weight: 700; color: var(--dash-navy); }
.tk-recent__when { flex: 0 0 auto; font-size: 11.5px; color: var(--dash-slate); white-space: nowrap; }

.tk-impact { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.tk-impact li {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	column-gap: 12px;
	align-items: center;
}
.tk-impact__icon {
	grid-row: 1 / 3;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 11px;
	background: var(--tint);
	color: #fff;
}
.tk-impact strong { font-size: 18px; font-weight: 800; line-height: 1.15; color: var(--dash-navy); font-variant-numeric: tabular-nums; }
.tk-impact span:last-child { font-size: 12px; line-height: 1.35; color: var(--dash-slate); }

.tk-handbook {
	border-color: #CDEEEA;
	background: linear-gradient(160deg, #E4F7F5 0%, #EEF6FD 100%);
}

.tk-quote {
	position: relative;
	overflow: hidden;
	isolation: isolate;
	border: 0;
	background:
		radial-gradient(ellipse 70% 90% at 100% 0%, rgba(40, 130, 230, .45) 0%, transparent 60%),
		linear-gradient(150deg, #0A2A5E 0%, #051738 100%);
	color: #fff;
}
.tk-quote__globe {
	position: absolute;
	z-index: -1;
	right: -40px;
	bottom: -50px;
	width: 170px;
	height: auto;
	opacity: .35;
	pointer-events: none;
}
.tk-quote__text { margin: 0 0 4px; font-size: 17px; font-style: italic; font-weight: 700; line-height: 1.35; color: #fff; }
.tk-quote__sub { margin: 0 0 14px; font-size: 12.5px; color: rgba(255, 255, 255, .82); }

@media (prefers-reduced-motion: reduce) {
	.tk-cat,
	.tk-card__link { transition: none; }
}

/* --- A tool's page ------------------------------------------------------------

   The designs give every tool the same frame: a pale blue page, a picture
   in the header, the work in numbered steps, and the handbook's guide
   beside it. Only what is inside the steps differs from tool to tool. */

.account__content:has(.tk-tool) {
	background:
		radial-gradient(900px 320px at 100% 0%, #E4F2FE 0%, rgba(228, 242, 254, 0) 70%),
		linear-gradient(180deg, #F6FBFF 0%, #F1F8FE 100%);
}

.tk-tool { position: relative; }

.tk-crumb {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 0 0 14px;
	font-size: 13px;
	color: var(--dash-slate, #51617A);
}
.tk-crumb a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-weight: 600;
	color: #1D5FD1;
	text-decoration: none;
}
.tk-crumb a:hover { text-decoration: underline; text-underline-offset: 3px; }
.tk-crumb strong { font-weight: 700; color: var(--dash-navy, #0B2247); }

/* --- The header ------------------------------------------------------------------- */

.tk-tool__head {
	position: relative;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 16px;
	margin-bottom: 18px;
	min-height: 86px;
}
/* The icon and the words together claim the first line, which leaves the
   privacy note the second one at its own width. Done with a wrapper rather
   than a flex-basis on the note: a flex line is broken on the item's size
   after min and max are applied, so basis 100% plus max-width fit-content
   simply fits back on the first line. */
.tk-tool__lead {
	display: flex;
	align-items: center;
	gap: 16px;
	flex: 1 1 100%;
	min-width: 0;
}

.tk-tool__icon {
	display: grid;
	place-items: center;
	flex: none;
	width: 54px;
	height: 54px;
	border-radius: 14px;
	background: var(--tk-pastel);
	color: var(--tk-strong);
}
/* The rest of the first line, beside the icon. At a fixed 260px basis it
   shared the row with the privacy note and "GPA & CGPA Calculator" wrapped
   at the ampersand to make room; at 100% it did not fit beside the icon at
   all and dropped below it. Growing from auto does neither. */
.tk-tool__titles { flex: 1 1 auto; min-width: 0; }
.tk-tool__title {
	margin: 0;
	font-size: clamp(24px, 2.4vw, 32px);
	font-weight: 800;
	letter-spacing: -.02em;
	color: var(--dash-navy, #0B2247);
}
.tk-tool__desc { margin: 3px 0 0; font-size: 14px; color: var(--dash-slate, #51617A); }

/* Cropped from the design; it fades into the page on its left and bottom,
   so it needs no card around it. Decorative, and gone on a narrow screen
   where the words need the room. */
/* Sized by height, not width: these were drawn at anything from 270x125 to
   560x128, and one fixed width made the squarer ones nearly twice as tall as
   the header they sit in. A band of fixed height, never wider than the room
   the header leaves for it, and never scaled past its own pixels. */
.tk-tool__art {
	position: absolute;
	right: -8px;
	top: 50%;
	transform: translateY(-50%);
	width: auto;
	height: clamp(84px, 9vw, 116px);
	max-width: clamp(240px, 26vw, 400px);
	object-fit: contain;
	object-position: right center;
	pointer-events: none;
	user-select: none;
}
/* The newer tools draw their picture instead: one scene in
   inc/toolkit-art.php with the tool's own word on the front card. Sized
   the same way as the cropped pictures so the two kinds of header sit in
   the same band, and given an aspect ratio because width:auto on an inline
   SVG with a width attribute would letterbox the drawing inside 375px
   rather than scale it. */
.tk-tool__art--drawn {
	aspect-ratio: 375 / 130;
	right: 0;
	height: clamp(86px, 9.2vw, 120px);
	width: auto;
	overflow: visible;
}

@media (max-width: 1100px) {
	.tk-tool__art { display: none; }
}
/* The picture is out of the flow, so the header keeps its own hands off
   that corner - otherwise the privacy note slides underneath it. */
@media (min-width: 1101px) {
	.tk-tool__head { padding-right: clamp(250px, 27vw, 410px); }
}

.tk-private {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	padding: 7px 13px;
	border-radius: 999px;
	background: #E3F6F4;
	font-size: 12.5px;
	font-weight: 700;
	color: #0B6F6B;
}

/* --- The two columns ----------------------------------------------------------------- */

.tk-tool__layout { display: grid; gap: 18px; align-items: start; }
@media (min-width: 1100px) {
	.tk-tool__layout { grid-template-columns: minmax(0, 1fr) clamp(300px, 24vw, 370px); }
}

.tk-tool__body {
	min-width: 0;
	padding: clamp(16px, 2vw, 22px);
	border: 1px solid #E2EBF5;
	border-radius: 16px;
	background: #fff;
	box-shadow: 0 6px 20px rgba(11, 34, 71, .05);
}

/* --- Numbered steps -------------------------------------------------------------------- */

.tk-step { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 14px; }
.tk-step + .tk-step { margin-top: 22px; padding-top: 22px; border-top: 1px solid #EDF2F8; }
.tk-step__n {
	grid-row: 1 / 3;
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: linear-gradient(150deg, #10335F 0%, #0B2247 100%);
	font-size: 14px;
	font-weight: 800;
	color: #fff;
}
.tk-step__title {
	margin: 0;
	align-self: center;
	font-size: 17px;
	font-weight: 800;
	color: #15489C;
}
.tk-step__lead { margin: 0; font-size: 13px; line-height: 1.5; color: var(--dash-slate, #51617A); }
.tk-step__body { grid-column: 2; margin-top: 12px; min-width: 0; }
.tk-step__body > * + * { margin-top: 14px; }
@media (max-width: 600px) {
	.tk-step__body { grid-column: 1 / -1; }
}

/* Content that carries on from the step above it, lined up with its body
   rather than with the number. */
.tk-step__cont { padding-left: 48px; }
@media (max-width: 600px) {
	.tk-step__cont { padding-left: 0; }
}
.tk-step__cont > * + * { margin-top: 14px; }

/* The page preview: what the PDF will actually hold. */
.tk-pagepreview {
	margin: 0;
	padding: 14px;
	border-radius: 14px;
	background: #EFF3F8;
}
.tk-pagepreview[hidden] { display: none; }
.tk-pagepreview figcaption {
	margin-bottom: 10px;
	font-size: 13px;
	font-weight: 700;
	color: var(--dash-navy, #0B2247);
}
.tk-pagepreview__row {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 14px;
}
.tk-pagepreview canvas {
	max-width: 100%;
	height: auto;
	border-radius: 4px;
	background: #fff;
	box-shadow: 0 4px 14px rgba(11, 34, 71, .14);
}

/* The Age Calculator's answer, as the design sets it out: the age in words,
   then the three numbers people check it against. */
.tk-age {
	padding: 18px 20px;
	border: 1px solid #CFE6F5;
	border-radius: 14px;
	background: linear-gradient(160deg, #EAF6FD 0%, #EFF6FC 100%);
}
.tk-age[hidden] { display: none; }
.tk-age:focus { outline: 3px solid #0B8F94; outline-offset: 3px; }
.tk-age__head { display: flex; align-items: center; gap: 16px; }
.tk-age__icon {
	display: grid;
	place-items: center;
	flex: none;
	width: 58px;
	height: 58px;
	border-radius: 50%;
	background: #CFE7F7;
	color: #1D5FD1;
}
.tk-age__said { min-width: 0; }
.tk-age__eyebrow {
	margin: 0 0 2px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: #5E7290;
}
.tk-age__big {
	margin: 0;
	font-size: clamp(22px, 2.6vw, 33px);
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: -.02em;
	color: var(--dash-navy, #0B2247);
}
.tk-age__facts {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(190px, 100%), 1fr));
	gap: 10px 18px;
	margin: 18px 0 0;
	padding: 16px 0 0;
	border-top: 1px solid #D6E7F3;
	list-style: none;
}
.tk-age__facts li {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: 2px 12px;
	align-items: center;
}
.tk-age__fact-icon { grid-row: 1 / 3; color: #1D5FD1; }
.tk-age__fact-label { font-size: 12.5px; color: var(--dash-slate, #51617A); }
.tk-age__fact-value { font-size: 16px; font-weight: 800; color: var(--dash-navy, #0B2247); }
.tk-age__fact-note { grid-column: 2; font-size: 11.5px; color: var(--dash-slate, #51617A); }

/* A button that takes the whole width, as the design draws it. */
.tk-actions--wide { display: block; }
.tk-btn.tk-btn--wide {
	width: 100%;
	min-height: 50px;
	border-radius: 14px;
	background: linear-gradient(100deg, #0B7F86 0%, #0A6E7C 100%);
	border-color: transparent;
	font-size: 15px;
	color: #fff;
}
.tk-btn.tk-btn--wide:hover { background: linear-gradient(100deg, #0A6E7C 0%, #095C68 100%); }

/* --- The guide --------------------------------------------------------------------------- */

.tk-guide {
	padding: 18px;
	border: 1px solid #E2EBF5;
	border-radius: 16px;
	background: #fff;
	box-shadow: 0 6px 20px rgba(11, 34, 71, .05);
}
.tk-guide__title {
	display: flex;
	align-items: center;
	gap: 9px;
	margin: 0 0 14px;
	font-size: 17px;
	font-weight: 800;
	color: var(--dash-navy, #0B2247);
}
.tk-guide__title svg { color: #1D5FD1; }

.tk-guide__use {
	margin: 0 0 14px;
	padding: 12px 14px;
	border-left: 3px solid #2B8FE8;
	border-radius: 0 12px 12px 0;
	background: #EAF4FE;
}
.tk-guide__use strong {
	display: flex;
	align-items: center;
	gap: 7px;
	margin-bottom: 4px;
	font-size: 13.5px;
	font-weight: 800;
	color: #15489C;
}
.tk-guide__use p { margin: 0; font-size: 12.5px; line-height: 1.5; color: #3D5872; }

.tk-guide__steps { margin: 0 0 14px; padding: 0; list-style: none; }
.tk-guide__steps li {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: 10px;
	align-items: start;
	padding: 5px 0;
	font-size: 12.5px;
	line-height: 1.5;
	color: #3D5872;
}
.tk-guide__n {
	display: grid;
	place-items: center;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: #1D8FD1;
	font-size: 11px;
	font-weight: 800;
	color: #fff;
}

.tk-guide__box {
	margin-bottom: 12px;
	padding: 12px 14px;
	border-radius: 12px;
	font-size: 12.5px;
}
.tk-guide__box strong {
	display: flex;
	align-items: center;
	gap: 7px;
	margin-bottom: 4px;
	font-size: 13.5px;
	font-weight: 800;
}
.tk-guide__box p { margin: 0; line-height: 1.5; color: #3D5872; }
.tk-guide__box--tip { background: #E8F7F0; border: 1px solid #CEEBDF; }
.tk-guide__box--tip strong { color: #0E7A54; }
.tk-guide__box--check { background: #FFF5E6; border: 1px solid #F6E2C2; }
.tk-guide__box--check strong { color: #B4700E; }

.tk-guide__checks { margin: 0; padding: 0; list-style: none; }
.tk-guide__checks li {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: 8px;
	align-items: start;
	padding: 3px 0;
	line-height: 1.45;
	color: #3D5872;
}
.tk-guide__checks svg { margin-top: 2px; color: #D08A1E; }

.tk-guide__facts {
	margin-bottom: 12px;
	padding: 12px 14px;
	border-radius: 12px;
	background: #F3F7FC;
	border: 1px solid #E2EBF5;
}
.tk-guide__facts strong {
	display: flex;
	align-items: center;
	gap: 7px;
	margin-bottom: 6px;
	font-size: 13.5px;
	font-weight: 800;
	color: #15489C;
}
.tk-guide__facts svg { color: #1D5FD1; }
.tk-guide__facts dl { margin: 0; }
/* Each value under its own label, both left-aligned.

   These tables hold two kinds of value: short fixed ones like "400 x 400
   px", and whole sentences or citation patterns. They used to sit on the
   label's line, right-aligned, with white-space: nowrap and flex: none for
   the sake of the short ones - which meant the long ones could neither
   shrink nor wrap, and ran out of the card and across the label beside
   them.

   Stacking suits both and is the same shape every time: the label reads as
   a heading for the value under it, the value gets the full width of the
   card whatever its length, and a row of four is a list rather than a
   table with one ragged column. */
.tk-guide__facts dl > div {
	display: block;
	padding: 7px 0;
	border-top: 1px solid #E6EDF6;
}
.tk-guide__facts dl > div:first-child { border-top: 0; padding-top: 2px; }
.tk-guide__facts dl > div:last-child { padding-bottom: 2px; }
.tk-guide__facts dt {
	font-size: 11.5px;
	font-weight: 700;
	color: #6A82A0;
}
.tk-guide__facts dd {
	margin: 2px 0 0;
	font-size: 12.5px;
	font-weight: 600;
	line-height: 1.5;
	/* A DOI or a URL has nowhere to break, so it is allowed to break
	   anywhere rather than push the card open. */
	overflow-wrap: anywhere;
	color: var(--dash-navy, #0B2247);
}

.tk-guide__more {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-size: 12.5px;
	font-weight: 700;
	color: #1D5FD1;
	text-decoration: none;
}
.tk-guide__more:hover { text-decoration: underline; text-underline-offset: 3px; }

/* --- Forms inside a tool ------------------------------------------------------------ */

.tk-form > * + * { margin-top: 14px; }
.tk-form[hidden] { display: none; }
/*
 * The fields in a row line up by their tops, not their bottoms. Bottom
 * alignment meant that one field with a hint long enough to wrap pushed
 * every shorter field in the row down with it, so two date boxes side by
 * side sat at different heights.
 */
.tk-row { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: start; }
.tk-row[hidden] { display: none; }

/*
 * Where the browser can do it, a row of nothing but fields shares three
 * lines - label, control, hint - so the controls line up to the pixel even
 * when one label wraps to two lines and its neighbour does not. Rows with
 * anything else in them, a button or an inline select, stay as they are.
 */
@supports (grid-template-rows: subgrid) {
	.tk-row:not(:has(> :not(.tk-field))) {
		display: grid;
		grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
		align-items: start;
	}
	.tk-row:not(:has(> :not(.tk-field))) > .tk-field {
		grid-row: span 3;
		grid-template-rows: subgrid;
	}
	.tk-row:not(:has(> :not(.tk-field))) > .tk-field--wide { grid-column: 1 / -1; }
}
.tk-field { display: grid; gap: 5px; flex: 1 1 180px; min-width: 0; margin: 0; }
.tk-field[hidden] { display: none; }
.tk-field--wide { flex-basis: 100%; }
.tk-field label { font-size: 13px; font-weight: 700; color: var(--color-navy-900, #0c2347); }
.tk-field input,
.tk-field select,
.tk-field textarea,
.tk-table input,
.tk-table select,
.tk-inline select { width: 100%; height: 44px; padding: 8px 12px; font-size: 15px; }
.tk-field textarea { height: auto; min-height: 120px; line-height: 1.55; resize: vertical; }
.tk-field input[type="range"] { height: 28px; padding: 0; border: 0; }
.tk-help { display: block; margin: 0; font-size: 13px; color: var(--color-text-muted, #5c6b7a); line-height: 1.5; }
.tk-note { margin: 0; font-size: 13px; color: var(--color-text-muted, #5c6b7a); line-height: 1.5; }
.tk-note[hidden] { display: none; }
.tk-check { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; }
.tk-check input { width: 18px; height: 18px; }
.tk-inline { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; }
.tk-inline select { width: auto; height: 38px; }
.tk-fieldset { margin: 0; padding: 14px; border: 1px solid var(--color-border, #e2e8ec); border-radius: 12px; }
.tk-fieldset legend { padding: 0 6px; font-size: 14px; font-weight: 800; }
.tk-fieldset > * + * { margin-top: 10px; }
.tk-more summary { cursor: pointer; font-weight: 700; color: var(--color-primary, #028b93); }
.tk-more > .tk-row { margin-top: 10px; }

.tk-modes { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; border: 0; }
.tk-mode { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border: 1px solid var(--color-border, #e2e8ec); border-radius: 999px; font-size: 14px; font-weight: 600; cursor: pointer; }
.tk-mode:has(input:checked) { border-color: var(--tk-strong, #028b93); background: var(--tk-pastel, #e6f4f5); }
.tk-mode input { accent-color: var(--tk-strong, #028b93); }

.tk-table { width: 100%; border-collapse: collapse; }
.tk-table th { padding: 0 6px 6px; text-align: left; font-size: 12.5px; font-weight: 700; color: var(--color-text-muted, #5c6b7a); }
.tk-table td { padding: 4px 6px; }
.tk-table__remove { width: 44px; }
.tk-table[hidden] { display: none; }

.tk-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 44px;
	padding: 10px 18px;
	border: 1px solid var(--color-navy-900, #0c2347);
	border-radius: 12px;
	background: #fff;
	color: var(--color-navy-900, #0c2347);
	font: inherit;
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
}
.tk-btn--primary { background: var(--color-navy-900, #0c2347); color: #fff; }
.tk-btn--primary:hover { background: #12366a; }
.tk-btn--ghost { border-color: var(--color-border, #d7e1e8); }
.tk-btn:disabled { opacity: 0.55; cursor: not-allowed; }
.tk-btn[hidden] { display: none; }
.tk-btn:focus-visible { outline: 3px solid var(--tk-strong, #028b93); outline-offset: 2px; }
.tk-icon-btn { display: inline-grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--color-border, #e2e8ec); border-radius: 10px; background: #fff; color: var(--color-navy-900, #0c2347); font-size: 18px; line-height: 1; cursor: pointer; }
.tk-icon-btn:disabled { opacity: 0.35; cursor: default; }
/* The button that does the work stands clear of the last field's hint
   rather than sitting on it. */
.tk-form > .tk-actions { margin-top: 20px; }
.tk-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0; }
.tk-actions[hidden] { display: none; }
.tk-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }

.tk-result { padding: 16px 18px; border-radius: 14px; background: #eef8fb; border: 1px solid #cfe9f0; }
.tk-result[hidden] { display: none; }
.tk-result__big { margin: 0 0 6px; font-size: clamp(22px, 2.4vw, 30px); font-weight: 800; color: var(--color-navy-900, #0c2347); line-height: 1.2; }
.tk-result__line { margin: 4px 0 0; color: #3d5a72; }
.tk-result--error { background: #fdf0f1; border-color: #f2c4c8; }
.tk-result--error .tk-result__big { font-size: 17px; color: #b3261e; }
.tk-result--warning { background: #fff8ec; border-color: #f4dcae; }

.tk-status { min-height: 1.2em; margin: 12px 0 0; font-size: 14px; font-weight: 600; color: var(--color-text-muted, #5c6b7a); }
.tk-status:empty { display: none; }
.tk-status--ok { color: #1a7f55; }
.tk-status--error { color: #b3261e; }
.tk-status--warning { color: #9a6408; }
.tk-notice { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 14px; padding: 12px 14px; border-radius: 12px; background: #fff8ec; border: 1px solid #f4dcae; font-size: 14px; line-height: 1.5; }
.tk-notice svg { flex: none; margin-top: 2px; color: #b47d28; }
.tk-notice--error { background: #fdf0f1; border-color: #f2c4c8; }

.tk-counts { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; margin: 0; }
.tk-counts div { padding: 12px 14px; border-radius: 12px; background: var(--color-bg-alt, #f4f7f9); }
.tk-counts dt { font-size: 12.5px; font-weight: 700; color: var(--color-text-muted, #5c6b7a); }
.tk-counts dd { margin: 2px 0 0; font-size: 22px; font-weight: 800; color: var(--color-navy-900, #0c2347); font-variant-numeric: tabular-nums; }
.tk-limit { display: grid; gap: 6px; font-size: 14px; font-weight: 700; }
.tk-limit[hidden] { display: none; }
.tk-limit__bar { height: 8px; border-radius: 999px; background: #e6edf2; overflow: hidden; }
.tk-limit__bar span { display: block; height: 100%; border-radius: 999px; background: #10b99c; }
.tk-limit.is-over .tk-limit__bar span { background: #d93a2b; }
.tk-limit.is-over { color: #b3261e; }

/* --- The citation generators ------------------------------------------------

   Source type as tabs, then the reference and both in-text forms, each in
   its own panel with a copy button - the layout the designs set out. */

.tk-cite__edition {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin: 0 0 10px;
	padding: 4px 11px;
	border-radius: 999px;
	background: #E8F4FD;
	font-size: 12px;
	font-weight: 700;
	color: #15489C;
}

.tk-cite__tabs {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(150px, 100%), 1fr));
	gap: 6px;
	margin: 4px 0 18px;
	padding: 5px;
	border: 1px solid #E2EBF5;
	border-radius: 12px;
	background: #F4F8FC;
}
.tk-cite__tab { margin: 0; }
.tk-cite__tab input {
	position: absolute;
	width: 1px;
	height: 1px;
	opacity: 0;
}
.tk-cite__tab span {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 10px 12px;
	border-radius: 9px;
	font-size: 13.5px;
	font-weight: 700;
	color: #44607F;
	cursor: pointer;
	transition: background .15s ease, color .15s ease;
}
.tk-cite__tab span:hover { background: #E6EFF9; color: #15489C; }
.tk-cite__tab input:checked + span {
	background: linear-gradient(150deg, #10596B 0%, #0B4256 100%);
	color: #fff;
}
.tk-cite__tab input:focus-visible + span { outline: 3px solid #0B8F94; outline-offset: 2px; }

.tk-cite__out > * + * { margin-top: 14px; }
.tk-cite__panel {
	padding: 14px 16px;
	border-radius: 14px;
}
.tk-cite__panel--ref { background: #EAF7F0; border: 1px solid #CDE9DC; }
.tk-cite__panel--in { background: #F2EFFC; border: 1px solid #E0D9F6; }
.tk-cite__label {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 10px;
	font-size: 14px;
	font-weight: 800;
	letter-spacing: 0;
	text-transform: none;
	color: var(--dash-navy, #0B2247);
}
.tk-cite__panel--ref .tk-cite__label svg { color: #16815C; }
.tk-cite__panel--in .tk-cite__label svg { color: #5B45B8; }

.tk-cite__row {
	display: flex;
	align-items: flex-start;
	gap: 14px;
}
.tk-cite__row .tk-btn { flex: none; }

.tk-cite__ref,
.tk-cite__intext {
	margin: 0;
	flex: 1 1 auto;
	padding: 12px 14px;
	border-radius: 10px;
	background: #fff;
	font-family: Georgia, 'Times New Roman', serif;
	font-size: 15.5px;
	line-height: 1.6;
}
/* A reference list hangs every line after the first. */
.tk-cite__ref { padding-left: 2.6em; text-indent: -1.6em; }

.tk-cite__pair {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
	gap: 12px;
}
.tk-cite__half {
	display: grid;
	gap: 8px;
	justify-items: start;
	align-content: start;
	padding: 12px;
	border-radius: 12px;
	background: rgba(255, 255, 255, .7);
}
.tk-cite__half .tk-cite__intext { width: 100%; font-size: 15px; }
.tk-cite__half .tk-btn { min-height: 38px; padding: 8px 14px; font-size: 13px; }
.tk-cite__kind {
	font-family: inherit;
	font-size: 12.5px;
	font-weight: 800;
	color: #5B45B8;
}

.tk-cite__rule {
	padding: 10px 12px;
	border-left: 3px solid #CBD6E6;
	border-radius: 0 10px 10px 0;
	background: #F5F8FC;
}

.tk-cite__list {
	padding: 16px 18px;
	border-radius: 14px;
	background: #F4F1FF;
	border: 1px solid #E2DBFF;
}
.tk-cite__list[hidden] { display: none; }
.tk-cite__list > * + * { margin-top: 10px; }
.tk-cite__list ol {
	margin: 0;
	padding-left: 0;
	list-style: none;
	font-family: Georgia, 'Times New Roman', serif;
	line-height: 1.6;
}
.tk-cite__list li { margin-bottom: 8px; padding-left: 2.2em; text-indent: -2.2em; }

/* Files. */
.tk-drop {
	display: grid;
	justify-items: center;
	gap: 6px;
	padding: clamp(26px, 5vw, 46px) 20px;
	border: 2px dashed #b9d3df;
	border-radius: 16px;
	background: #f7fbfd;
	text-align: center;
	color: #3d6980;
	transition: border-color 0.15s ease, background 0.15s ease;
}
.tk-drop[hidden] { display: none; }
.tk-drop svg { color: var(--tk-strong, #0c8f8c); }
.tk-drop.is-over { border-color: var(--tk-strong, #0c8f8c); background: var(--tk-pastel, #e6f4f5); }
.tk-drop__text { margin: 0; font-size: 16px; }
.tk-drop__choose { display: inline-block; padding: 9px 18px; border-radius: 12px; background: var(--color-navy-900, #0c2347); color: #fff; font-weight: 700; cursor: pointer; }
.tk-drop__choose:hover { background: #12366a; }
.tk-drop:focus-within .tk-drop__choose { outline: 3px solid var(--tk-strong, #0c8f8c); outline-offset: 2px; }
.tk-drop__hint { margin: 0; font-size: 13px; color: var(--color-text-muted, #5c6b7a); }

.tk-preview { display: grid; justify-items: center; gap: 6px; }
.tk-preview canvas,
.tk-compare canvas,
.tk-compare img { max-width: 100%; height: auto; border-radius: 10px; background: repeating-conic-gradient(#eef2f5 0% 25%, #fff 0% 50%) 50% / 18px 18px; }
.tk-preview__meta { margin: 0; font-size: 13px; color: var(--color-text-muted, #5c6b7a); }
.tk-compare { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 14px; }
.tk-compare figure { display: grid; gap: 6px; margin: 0; justify-items: center; }
.tk-compare figcaption { font-size: 13px; font-weight: 700; }
.tk-compare figcaption span { font-weight: 500; color: var(--color-text-muted, #5c6b7a); }
.tk-compare img { max-height: 320px; object-fit: contain; }

.tk-crop { position: relative; margin: 0 auto; touch-action: none; user-select: none; }
.tk-crop canvas { display: block; max-width: 100%; }
.tk-crop__box { position: absolute; box-shadow: 0 0 0 9999px rgba(6, 26, 58, 0.55); outline: 2px solid #fff; cursor: move; touch-action: none; }
.tk-crop__box:focus-visible { outline: 3px solid #17d4c6; }
.tk-crop { overflow: hidden; border-radius: 10px; }
.tk-crop__handle { position: absolute; width: 18px; height: 18px; border: 2px solid #fff; border-radius: 4px; background: #0c8f8c; }
.tk-crop__handle[data-tk-handle="nw"] { top: -9px; left: -9px; cursor: nwse-resize; }
.tk-crop__handle[data-tk-handle="ne"] { top: -9px; right: -9px; cursor: nesw-resize; }
.tk-crop__handle[data-tk-handle="sw"] { bottom: -9px; left: -9px; cursor: nesw-resize; }
.tk-crop__handle[data-tk-handle="se"] { bottom: -9px; right: -9px; cursor: nwse-resize; }

.tk-passport { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; }
.tk-passport__frame { flex: none; border: 1px solid #cfd8df; border-radius: 4px; cursor: grab; touch-action: none; line-height: 0; }
.tk-passport__frame:active { cursor: grabbing; }
.tk-passport__frame:focus-visible { outline: 3px solid var(--tk-strong); outline-offset: 3px; }
.tk-passport__controls { flex: 1 1 220px; display: grid; gap: 12px; }

.tk-files { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.tk-files li { display: flex; flex-wrap: wrap; gap: 4px 12px; padding: 10px 12px; border-radius: 10px; background: var(--color-bg-alt, #f4f7f9); font-size: 14px; }
.tk-files__name { flex: 1; min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
.tk-files__size,
.tk-files__state { color: var(--color-text-muted, #5c6b7a); }

/* PDFs. */
.tk-order { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; counter-reset: tk-order; }
.tk-order__item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border: 1px solid var(--color-border, #e2e8ec); border-radius: 12px; background: #fff; counter-increment: tk-order; }
.tk-order__item::before { content: counter(tk-order); min-width: 1.6em; font-weight: 800; color: var(--tk-strong); text-align: center; }
.tk-order__thumb { flex: none; width: 52px; height: 52px; border-radius: 8px; object-fit: cover; background: var(--tk-pastel); }
.tk-order__thumb--pdf { display: grid; place-items: center; font-size: 12px; font-weight: 800; color: var(--tk-strong); }
.tk-order__name { flex: 1; min-width: 0; font-weight: 600; font-size: 14px; overflow-wrap: anywhere; }
.tk-order__meta { font-size: 13px; color: var(--color-text-muted, #5c6b7a); white-space: nowrap; }
.tk-order__btns { display: flex; gap: 4px; }

.tk-pages { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.tk-pages.is-inert { opacity: 0.45; pointer-events: none; }
.tk-page__btn { display: grid; justify-items: center; gap: 6px; width: 100%; padding: 10px 8px 8px; border: 2px solid var(--color-border, #e2e8ec); border-radius: 12px; background: #fff; font: inherit; cursor: pointer; }
.tk-page__btn:focus-visible { outline: 3px solid var(--tk-strong); outline-offset: 2px; }
.tk-page__thumb { display: grid; place-items: center; width: 100px; height: 140px; transition: transform 0.2s ease; }
.tk-page__thumb canvas { max-width: 100px; max-height: 140px; box-shadow: 0 2px 8px rgba(12, 35, 71, 0.18); }
.tk-page__num { display: grid; place-items: center; width: 90px; height: 124px; border: 1px solid #d5dee5; border-radius: 4px; background: #fafcfd; font-size: 26px; font-weight: 800; color: #9aaab7; }
.tk-page__label { font-size: 13px; font-weight: 700; color: var(--color-navy-900, #0c2347); }
.tk-pages--split .tk-page__btn[aria-pressed="true"],
.tk-pages--rotate .tk-page__btn[aria-pressed="true"] { border-color: var(--tk-strong); background: var(--tk-pastel); }
.tk-pages--remove-pages .tk-page__btn[aria-pressed="true"] { border-color: #d93a2b; background: #fdf0f1; }
.tk-pages--remove-pages .tk-page__btn[aria-pressed="true"] .tk-page__thumb { opacity: 0.35; }
.tk-pages--remove-pages .tk-page__btn[aria-pressed="true"] .tk-page__label::after { content: ' · removed'; color: #b3261e; }

.is-busy { cursor: progress; }

@media (max-width: 640px) {
	.tk-table th:first-child,
	.tk-table td:first-child { min-width: 0; }
	.tk-order__meta { display: none; }
	.tk-pages { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
	.tk-page__thumb { width: 80px; height: 112px; }
	.tk-page__thumb canvas { max-width: 80px; max-height: 112px; }
	.tk-page__num { width: 72px; height: 100px; }
}

@media (prefers-reduced-motion: reduce) {
	.tk-page__thumb { transition: none; }
}

/* --- The dense tool grid, last so it settles the column count ------------ */

.tk-grid--tight { gap: 10px; }
@container (min-width: 520px) { .tk-grid--tight { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* Five across is as many as the column holds with the name and the line
   each on one line; six only once the page is wider than a laptop. */
/* Four across on a 1280-wide laptop, where the column is about 640px. */
@container (min-width: 600px) { .tk-grid--tight { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@container (min-width: 700px) { .tk-grid--tight { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@container (min-width: 900px) { .tk-grid--tight { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

.tk-grid--tight .tk-card__link {
	gap: 8px;
	min-height: 56px;
	padding: 8px 9px;
	border-radius: 11px;
}
.tk-grid--tight .tk-card__icon { width: 28px; height: 28px; border-radius: 8px; }
.tk-grid--tight .tk-card__icon svg { width: 15px; height: 15px; }
/* Name and line each keep to one line, as the design draws them: the tile
   carries the tool's short name and a two or three word line (see the
   'tile' and 'short' entries in inc/toolkit-content.php), and anything
   longer than the column ends in an ellipsis rather than wrapping. */
.tk-grid--tight .tk-card__name,
.tk-grid--tight .tk-card__desc {
	display: block;
	overflow: hidden;
	min-width: 0;
	text-overflow: ellipsis;
	white-space: nowrap;
}
.tk-grid--tight .tk-card__name {
	font-size: 10.5px;
	letter-spacing: -.01em;
	line-height: 1.3;
	color: #10226B;
}
.tk-grid--tight .tk-card__desc {
	font-size: 9px;
	line-height: 1.35;
	color: #8893C1;
}

/* Popular ends on a full row: seventeen tools and the View All tile make
   three rows of six and six rows of three exactly. Five to a row, the last
   three tools wait in All Tools just below. */
@container (min-width: 600px) and (max-width: 699px) {
	.tk-grid--popular > .tk-card:nth-child(n+16):not(.tk-card--all) { display: none; }
}
@container (min-width: 700px) and (max-width: 899px) {
	.tk-grid--popular > .tk-card:nth-child(n+15):not(.tk-card--all) { display: none; }
}


/* --- While the search box has something in it -----------------------------

   The page becomes its answer: the banner, the three numbers, the
   categories, Popular Tools and the rail beside them are all ways of
   browsing, and none of them helps anyone who has already said what they
   are looking for. The script sets the class (assets/js/toolkit.js). */

.tk-searching .tk-banner,
.tk-searching .tk-dash .dash-stats,
.tk-searching [data-tk-cats-section],
.tk-searching [data-tk-popular-section],
.tk-searching .account-dash__rail { display: none; }

/* With the rail gone the results have the page to themselves. */
@media (min-width: 1200px) {
	.tk-searching .account-dash { grid-template-columns: minmax(0, 1fr); }
}

/* The chips filter the list, so they sit at the end of its heading. */
.dash-section__title > .tk-chips { margin-left: auto; }
@media (max-width: 599px) {
	.dash-section__title > .tk-chips { margin-left: 0; }
}


/* =========================================================================
   GPA / CGPA CALCULATOR, after the client's two designs

   Two calculators behind two tabs, each a run of numbered steps. The page
   around it is the Toolkit's own tool frame; everything here is this tool's.
   ========================================================================= */

.gpa { display: grid; gap: 14px; }

/* --- The two tabs -------------------------------------------------------- */

.gpa-tabs {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 0;
	overflow: hidden;
	border: 1px solid var(--color-border, #e2e8ec);
	border-radius: 14px;
	background: #fff;
}
@media (min-width: 620px) { .gpa-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.gpa-tab {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 16px 18px;
	border: 0;
	background: #fff;
	font: inherit;
	text-align: left;
	color: var(--color-navy-900, #0c2347);
	cursor: pointer;
	transition: background .15s ease, color .15s ease;
}
.gpa-tab__icon { display: inline-flex; flex: 0 0 auto; color: #1668E3; }
.gpa-tab__text { display: grid; gap: 2px; min-width: 0; }
.gpa-tab__text strong { font-size: 16px; font-weight: 800; }
.gpa-tab__text small { font-size: 12.5px; color: var(--color-text-muted, #5c6b7a); }
.gpa-tab.is-on { background: linear-gradient(100deg, #0C6C8C 0%, #0E8E95 100%); color: #fff; }
.gpa-tab.is-on .gpa-tab__icon { color: #fff; }
.gpa-tab.is-on .gpa-tab__text small { color: rgba(255, 255, 255, .85); }
.gpa-tab:focus-visible { outline: 3px solid #0B2A4A; outline-offset: -3px; }

/* --- A numbered step ----------------------------------------------------- */

.gpa-form[hidden] { display: none; }
.gpa-form { display: grid; gap: 14px; }

.gpa-step {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: 12px;
	padding: 16px;
	border: 1px solid var(--color-border, #e2e8ec);
	border-radius: 14px;
	background: #fff;
}
.gpa-step__n {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: #0E6E86;
	font-size: 13px;
	font-weight: 800;
	color: #fff;
}
.gpa-step__body { min-width: 0; }
.gpa-step__title {
	display: flex;
	align-items: center;
	gap: 7px;
	margin: 2px 0 2px;
	font-size: 16px;
	font-weight: 800;
	color: var(--color-navy-900, #0c2347);
}
.gpa-step__opt { font-size: 13px; font-weight: 700; color: #1668E3; }
.gpa-step__line { margin: 0 0 12px; font-size: 13px; color: var(--color-text-muted, #5c6b7a); }

/* --- The cards a member picks from --------------------------------------- */

/* auto-fit, not a viewport media query. The tool column is a good deal
   narrower than the window it is in, so a 980px viewport rule gave the three
   scales three cramped columns in a 700px space - and below it, two columns
   with the third scale alone on a row of its own. Fitting to the space that
   is actually there puts all three on one line when they fit and two when
   they do not, with no row left half empty. */
.gpa-picks {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(188px, 1fr));
	gap: 10px;
}
.gpa-picks--credits { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.gpa-pick {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	align-items: center;
	gap: 12px;
	padding: 13px 14px;
	border: 1.5px solid var(--color-border, #e2e8ec);
	border-radius: 12px;
	background: #fff;
	cursor: pointer;
}
.gpa-pick:has(.gpa-pick__icon) { grid-template-columns: auto auto minmax(0, 1fr); }
.gpa-pick input { position: absolute; opacity: 0; pointer-events: none; }
.gpa-pick__dot {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	border: 2px solid #C6D3E6;
	border-radius: 50%;
	background: #fff;
}
.gpa-pick__icon { display: inline-flex; color: #1668E3; }
.gpa-pick__text { display: grid; gap: 2px; min-width: 0; }
.gpa-pick__text strong { font-size: 14.5px; font-weight: 800; color: var(--color-navy-900, #0c2347); }
.gpa-pick__text small { font-size: 12px; line-height: 1.45; color: var(--color-text-muted, #5c6b7a); }
.gpa-pick.is-on { border-color: #1668E3; background: #F2F7FE; }
.gpa-pick.is-on .gpa-pick__dot { border-color: #1668E3; }
.gpa-pick.is-on .gpa-pick__dot::after {
	content: "";
	width: 11px;
	height: 11px;
	border-radius: 50%;
	background: #1668E3;
}
.gpa-pick:focus-within { box-shadow: 0 0 0 3px rgba(22, 104, 227, .18); }

/* --- Step 2 of the CGPA: what came before -------------------------------- */

.gpa-prev {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 14px;
	padding: 14px;
	border-radius: 12px;
	background: #F6F9FD;
}
@media (min-width: 760px) { .gpa-prev { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.gpa-field { display: grid; gap: 5px; margin: 0; min-width: 0; }
.gpa-field[hidden] { display: none; }
.gpa-field label {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	font-weight: 700;
	color: var(--color-navy-900, #0c2347);
}
.gpa-field input {
	width: 100%;
	height: 44px;
	padding: 0 12px;
	border: 1px solid var(--color-border, #e2e8ec);
	border-radius: 10px;
	background: #fff;
	font: inherit;
	font-size: 14px;
}
.gpa-field input:focus-visible { outline: 3px solid rgba(22, 104, 227, .25); outline-offset: 1px; border-color: #1668E3; }
.gpa-field__hint { font-size: 11.5px; color: var(--color-text-muted, #5c6b7a); }

/* --- Step 3: the subjects ------------------------------------------------ */

.gpa-table { display: grid; gap: 8px; }
.gpa-table__head,
.gpa-row {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(130px, 200px) 44px;
	align-items: center;
	gap: 10px;
}
.gpa-form.has-credits .gpa-table__head,
.gpa-form.has-credits .gpa-row { grid-template-columns: minmax(0, 1fr) minmax(130px, 200px) minmax(90px, 150px) 44px; }

.gpa-table__head {
	/* No horizontal padding: these are labels for the inputs below them and
	   have to start on the same edge. */
	padding: 0 0 2px;
	font-size: 12.5px;
	font-weight: 700;
	color: var(--color-text-muted, #5c6b7a);
}
.gpa-table__head > span { display: flex; align-items: center; gap: 6px; }

/* The credit column is not there at all until it is asked for. */
.gpa-table__head > .gpa-table__credits,
.gpa-row__credits { display: none; }
.gpa-form.has-credits .gpa-table__head > .gpa-table__credits,
.gpa-form.has-credits .gpa-row__credits { display: flex; }

.gpa-row__subject input,
.gpa-row__credits input,
.gpa-grade {
	width: 100%;
	height: 46px;
	padding: 0 12px;
	border: 1px solid var(--color-border, #e2e8ec);
	border-radius: 10px;
	background: #fff;
	font: inherit;
	font-size: 14px;
	color: var(--color-navy-900, #0c2347);
}
.gpa-row__subject input:focus-visible,
.gpa-row__credits input:focus-visible,
.gpa-grade:focus-visible { outline: 3px solid rgba(22, 104, 227, .25); outline-offset: 1px; border-color: #1668E3; }
.gpa-row__grade,
.gpa-row__subject,
.gpa-row__credits { min-width: 0; }

.gpa-row__drop {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 46px;
	border: 1px solid #F6D4D9;
	border-radius: 10px;
	background: #FEF3F4;
	color: #DC2B45;
	cursor: pointer;
}
.gpa-row__drop:hover { background: #FBE2E6; }

.gpa-add {
	justify-self: start;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 11px 16px;
	border: 1.5px dashed #9FBEE6;
	border-radius: 10px;
	background: #fff;
	font: inherit;
	font-size: 13.5px;
	font-weight: 700;
	color: #1668E3;
	cursor: pointer;
}
.gpa-add:hover { border-color: #1668E3; background: #F3F8FF; }

/* --- Calculate ----------------------------------------------------------- */

.gpa-go {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	width: 100%;
	padding: 17px 24px;
	border: 0;
	border-radius: 12px;
	background: linear-gradient(100deg, #0C6C8C 0%, #0E8E95 100%);
	font: inherit;
	font-size: 16.5px;
	font-weight: 700;
	color: #fff;
	cursor: pointer;
}
.gpa-go:hover { background: linear-gradient(100deg, #0A5872 0%, #0B7880 100%); }
.gpa-go:focus-visible { outline: 3px solid #0B2A4A; outline-offset: 3px; }

/* --- The answer ---------------------------------------------------------- */

.gpa-result {
	padding: 16px;
	border: 1px solid #BFE4E2;
	border-radius: 14px;
	background: linear-gradient(160deg, #EAF8F6 0%, #F4FBFD 100%);
}
.gpa-result[hidden] { display: none; }
.gpa-result:focus { outline: none; }
.gpa-result.is-error { border-color: #F6CBD2; background: #FDF1F3; }
.gpa-result__problem { margin: 0; font-size: 14px; font-weight: 600; color: #B01A33; }

.gpa-result__top { display: grid; gap: 2px; margin-bottom: 12px; }
.gpa-result__label { margin: 0; font-size: 13px; font-weight: 700; color: #0A6A74; }
.gpa-result__big { margin: 0; font-size: 42px; font-weight: 800; line-height: 1; color: var(--color-navy-900, #0c2347); }
.gpa-result__big small { font-size: 18px; font-weight: 700; color: #6B8097; }

.gpa-result__facts { display: grid; gap: 8px; margin: 0 0 10px; }
@media (min-width: 620px) { .gpa-result__facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.gpa-result__facts div { padding: 9px 11px; border-radius: 10px; background: rgba(255, 255, 255, .75); }
.gpa-result__facts dt { font-size: 11.5px; font-weight: 700; color: #6B8097; }
.gpa-result__facts dd { margin: 1px 0 0; font-size: 13px; font-weight: 600; color: var(--color-navy-900, #0c2347); }

.gpa-result__lines { display: grid; gap: 5px; margin: 0 0 10px; padding: 0 0 0 18px; }
.gpa-result__lines li { font-size: 13px; line-height: 1.5; color: #35506F; }
.gpa-result__note { margin: 0 0 12px; font-size: 12px; line-height: 1.5; color: #5c6b7a; }

.gpa-result__go { display: flex; flex-wrap: wrap; gap: 10px; }
.gpa-again,
.gpa-reset {
	padding: 10px 18px;
	border-radius: 10px;
	border: 1px solid transparent;
	font: inherit;
	font-size: 13px;
	font-weight: 700;
	cursor: pointer;
}
.gpa-again { background: #0E7281; color: #fff; }
.gpa-again:hover { background: #0A5B68; }
.gpa-reset { border-color: #CFDDEC; background: #fff; color: #41567A; }
.gpa-reset:hover { border-color: #41567A; }

.gpa-small { margin: 0; font-size: 11.5px; line-height: 1.55; color: var(--color-text-muted, #5c6b7a); }

/* --- The ⓘ bubbles ------------------------------------------------------- */

.gpa-tip {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 17px;
	height: 17px;
	flex: 0 0 auto;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #1668E3;
	font: inherit;
	font-size: 11px;
	font-weight: 700;
	font-style: italic;
	color: #fff;
	cursor: help;
}
.gpa-tip__bubble {
	position: absolute;
	bottom: calc(100% + 8px);
	left: 50%;
	z-index: 5;
	width: max-content;
	max-width: 230px;
	padding: 8px 10px;
	border-radius: 8px;
	background: #0B2A4A;
	font-size: 12px;
	font-style: normal;
	font-weight: 500;
	line-height: 1.45;
	color: #fff;
	text-align: left;
	opacity: 0;
	visibility: hidden;
	transform: translate(-50%, 4px);
	transition: opacity .12s ease, transform .12s ease, visibility .12s;
}
.gpa-tip__bubble::after {
	content: "";
	position: absolute;
	top: 100%;
	left: 50%;
	border: 5px solid transparent;
	border-top-color: #0B2A4A;
	transform: translateX(-50%);
}
.gpa-tip:hover .gpa-tip__bubble,
.gpa-tip:focus-visible .gpa-tip__bubble,
.gpa-tip.is-on .gpa-tip__bubble {
	opacity: 1;
	visibility: visible;
	transform: translate(-50%, 0);
}

/* --- The guide beside it -------------------------------------------------- */

.gpa-guide__panel[hidden],
.gpa-guide__warn[hidden] { display: none; }

.gpa-guide__steps { display: grid; gap: 10px; margin: 10px 0 14px; padding: 0; list-style: none; }
.gpa-guide__steps li { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; line-height: 1.5; color: #35506F; }
.gpa-guide__n {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	flex: 0 0 auto;
	border-radius: 50%;
	background: #1668E3;
	font-size: 12px;
	font-weight: 800;
	color: #fff;
}

.gpa-guide__tip {
	padding: 12px;
	border-radius: 11px;
	background: #EDF9F0;
}
.gpa-guide__tip strong { display: flex; align-items: center; gap: 7px; font-size: 13px; color: #16794F; }
.gpa-guide__tip strong > svg { color: #19A05F; }
.gpa-guide__tip p { margin: 5px 0 0; font-size: 12.5px; line-height: 1.5; color: #3F6552; }

.gpa-guide__table { margin-top: 16px; }
.gpa-guide__table h3 {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 8px;
	font-size: 14px;
	font-weight: 800;
	color: var(--color-navy-900, #0c2347);
}
.gpa-guide__table h3 > svg { color: #1668E3; }
.gpa-guide__table table { width: 100%; border-collapse: collapse; }
.gpa-guide__table th,
.gpa-guide__table td {
	padding: 7px 10px;
	border-bottom: 1px solid #E8EEF6;
	font-size: 12.5px;
	text-align: left;
}
.gpa-guide__table th { background: #F4F8FC; font-weight: 700; color: #41567A; }
.gpa-guide__table td { color: #35506F; }

.gpa-guide__note {
	display: flex;
	gap: 10px;
	margin-top: 14px;
	padding: 11px 12px;
	border-radius: 11px;
	background: #F1F6FD;
}
.gpa-guide__note > svg { flex: 0 0 auto; color: #1668E3; }
.gpa-guide__note p { margin: 0; font-size: 12px; line-height: 1.5; color: #41567A; }

.gpa-guide__warn {
	margin-top: 14px;
	padding: 12px;
	border-radius: 11px;
	background: #FFF6E8;
}
.gpa-guide__warn strong { display: flex; align-items: center; gap: 7px; font-size: 13px; color: #9A5B06; }
.gpa-guide__warn p { margin: 5px 0 0; font-size: 12px; line-height: 1.5; color: #7A5A2E; }

@media (prefers-reduced-motion: reduce) {
	.gpa-tip__bubble { transition: none; }
}


/* The GPA page's artwork belongs to its header card, which ends where the
   guide column begins - so it is offset by that column's width rather than
   sitting over the guide. */
@media (min-width: 1100px) {
	.tk-tool[data-tk-tool="gpa-calculator"] .tk-tool__head {
		padding-right: calc(clamp(300px, 24vw, 370px) + 230px);
	}
}


/* --- Compare: the original and the compressed under one handle -----------
   Drag left for the original, right for the compressed. Both pictures are
   in the page either way; the handle only decides how much of the second
   is shown over the first. */

/* One frame, not the two-column grid the other tools use - and none of
   that grid's sizing may reach the two layers inside it. */
.tk-compare--one { display: block; }
.tk-compare--one .tk-cmp__a,
.tk-compare--one .tk-cmp__b { width: 100%; height: 100%; max-width: none; max-height: none; }

.tk-cmp {
	position: relative;
	overflow: hidden;
	/*
	 * The frame holds the picture's own shape (the script sets --tk-ratio),
	 * and both layers fill it. A portrait photograph would run off the
	 * screen at full width, so the frame is capped - and because both
	 * layers are sized to the frame rather than to themselves, the cap
	 * shrinks them together instead of cropping one and squashing the
	 * other, which is what pulled them out of step before.
	 */
	aspect-ratio: var(--tk-ratio, 16 / 10);
	max-height: 70vh;
	margin-bottom: 14px;
	border-radius: 12px;
	background: repeating-conic-gradient(#eef2f5 0% 25%, #fff 0% 50%) 50% / 18px 18px;
	line-height: 0;
	touch-action: pan-y;
}
/* Both layers are given the frame, not their own size: the same box, the
   same letterboxing, so they line up whatever either one's pixel
   dimensions turn out to be. */
.tk-cmp__a,
.tk-cmp__b {
	position: absolute;
	inset: 0;
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}
/* Everything left of the handle is the original underneath. */
.tk-cmp__b { clip-path: inset(0 0 0 var(--tk-cmp, 50%)); }
.tk-cmp__line {
	position: absolute;
	top: 0;
	bottom: 0;
	left: var(--tk-cmp, 50%);
	width: 2px;
	background: #fff;
	box-shadow: 0 0 0 1px rgba(11, 34, 71, .25);
	pointer-events: none;
}
.tk-cmp__line > span {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 30px;
	height: 30px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 2px 8px rgba(11, 34, 71, .3);
	transform: translate(-50%, -50%);
}
.tk-cmp__slider { position: absolute; inset: 0; display: block; margin: 0; }
.tk-cmp__slider input {
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	cursor: ew-resize;
}
.tk-cmp__slider input:focus-visible { outline: 3px solid #0B2A4A; outline-offset: -3px; opacity: .01; }

.tk-cmp__tag {
	position: absolute;
	bottom: 10px;
	padding: 5px 10px;
	border-radius: 7px;
	background: rgba(7, 24, 48, .76);
	font-size: 11.5px;
	font-weight: 600;
	line-height: 1.3;
	color: #fff;
	pointer-events: none;
}
.tk-cmp__tag--a { left: 10px; }
.tk-cmp__tag--b { right: 10px; }

/* The buttons under a preview stand clear of the picture. */
.tk-preview,
.tk-compare { margin-bottom: 14px; }
.tk-image .tk-actions { margin-top: 4px; }

/* ==========================================================================
   THE TOOLS ON A PHONE

   Everything in this block is inside a max-width query, so nothing above it
   changes on a tablet or a desktop.

   The client reviews on an iPhone, and iOS Safari is where most of this
   went wrong: a date field there sizes to its own content and ignores
   width: 100% unless its appearance is reset, so it hung out of the card it
   was in while the text field beside it behaved.
   ========================================================================== */

/* A date or time field, at any width. Not in the media query: the bug is
   the control's own intrinsic width, which is there on a desktop too - it
   simply had room to hide in. */
.tk-field input[type="date"],
.tk-field input[type="time"],
.tk-field input[type="datetime-local"],
.tk-table input[type="date"],
.tk-table input[type="time"] {
	-webkit-appearance: none;
	appearance: none;
	min-width: 0;
	max-width: 100%;
}

@media (max-width: 640px) {
	/* 16px is the size below which iOS zooms the page when a field is
	   tapped, and the zoom does not undo itself. */
	.tk-field input,
	.tk-field select,
	.tk-field textarea,
	.tk-table input,
	.tk-table select { font-size: 16px; }

	/* One field to a line. Two 180px fields and a 16px gap need 376px, and
	   a phone in portrait does not have it once the card's padding is
	   taken off - so they were being squeezed rather than wrapped. */
	.tk-row > .tk-field { flex-basis: 100%; }
	.tk-row:not(:has(> :not(.tk-field))) { grid-template-columns: minmax(0, 1fr); }

	/* --- The subjects table in the GPA calculator ------------------------
	   Subject on its own line, then grade, credits and the remove button
	   sharing the one below. Four columns needed 294px before the subject
	   field got anything at all, which on a 360px screen left it about six
	   pixels wide.
	   ------------------------------------------------------------------ */
	.gpa-table__head { display: none; }
	.gpa-form .gpa-row,
	.gpa-form.has-credits .gpa-row {
		grid-template-columns: minmax(0, 1fr) auto;
		gap: 8px;
		padding: 10px;
		border: 1px solid var(--color-border, #e2e8ec);
		border-radius: 10px;
		background: #fff;
	}
	.gpa-row__subject { grid-column: 1 / -1; }
	.gpa-row__grade { grid-column: 1; }
	.gpa-form.has-credits .gpa-row__credits { grid-column: 1; }
	.gpa-form.has-credits .gpa-row__grade { grid-column: 1; }
	.gpa-row__drop { grid-column: 2; grid-row: 2 / span 2; height: auto; align-self: stretch; }
	.gpa-form:not(.has-credits) .gpa-row__drop { grid-row: 2; }

	/* The label the head row used to carry, back as a placeholder. */
	.gpa-row__subject input::placeholder { opacity: 1; }

	/* --- Authors, in the citation tools ----------------------------------
	   A three-column table of two names and a close button is a desktop
	   shape. Here each author is a small stack: first name, last name, and
	   a labelled Remove under them - a bare x at 44px wide was both hard
	   to hit and hard to understand.
	   ------------------------------------------------------------------ */
	.tk-table[data-tk-people] { display: block; }
	.tk-table[data-tk-people] thead { display: none; }
	.tk-table[data-tk-people] tbody { display: grid; gap: 10px; }
	.tk-table[data-tk-people] tr {
		display: grid;
		gap: 8px;
		padding: 10px;
		border: 1px solid var(--color-border, #e2e8ec);
		border-radius: 10px;
		background: #fff;
	}
	.tk-table[data-tk-people] td { display: block; padding: 0; }
	.tk-table[data-tk-people] .tk-table__remove { width: auto; justify-self: end; }
	.tk-table[data-tk-people] .tk-icon-btn {
		display: inline-flex;
		align-items: center;
		gap: 6px;
		width: auto;
		min-height: 36px;
		padding: 0 12px;
		border: 1px solid #F0CFCF;
		border-radius: 8px;
		background: #fff;
		font-size: 13px;
		font-weight: 700;
		color: #B3261E;
	}
	.tk-table[data-tk-people] .tk-icon-btn::after {
		content: attr(data-label);
	}
}

/* ==========================================================================
   THE CONVERTERS, THE SIGNATURE PAD AND THE REFERENCE LIST

   Added for the second wave of tools. Everything below either has no
   equivalent in the Toolkit yet (the pad, the reference rows) or is a
   variant of something that does (.tk-result--ok beside --error).
   ========================================================================== */

/* A row of actions under a step, rather than one button on its own. */
.tk-field--action {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
	margin: 12px 0 0;
}

.tk-field--action .btn { flex: 0 0 auto; }

/*
 * [hidden] has to win here.
 *
 * .btn declares display: inline-flex, and an author rule that sets display
 * beats the user-agent rule behind the hidden attribute. So "Undo the last
 * change", marked hidden in the template until there is something to undo,
 * was on screen from the first paint. The same trap as the webinar card's
 * panel - see assets/css/webinars.css.
 */
.tk-form .btn[hidden],
.tk-form [hidden] { display: none !important; }

/* A button that cannot do anything yet has to look like it. .tk-btn says
   so already; the site's own .btn did not, so "Download" sat there in full
   teal on an empty signature pad looking ready to press. */
.tk-field--action .btn:disabled,
.tk-form .btn:disabled {
	opacity: 0.45;
	cursor: not-allowed;
	box-shadow: none;
}

.tk-result--ok { background: #eff9f3; border-color: #bfe3d3; }
.tk-result--ok .tk-result__big { font-size: 17px; color: #1f6a4c; }
.tk-result--note { background: #f2f6fa; border-color: #d6e2ec; }
.tk-result--note .tk-result__big { font-size: 17px; color: var(--color-navy-900, #0c2347); }

/* The unit beside a converted figure: "17.5 Centimetres". Smaller and
   lighter, because the number is the answer and the unit is the label on
   it. */
.tk-result__unit {
	font-size: 0.52em;
	font-weight: 700;
	color: #3d5a72;
	white-space: nowrap;
}

.tk-result__label {
	margin: 0 0 6px;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: 0.07em;
	text-transform: uppercase;
	color: #4f7287;
}

.tk-result__ref {
	margin: 0;
	font-size: 15px;
	line-height: 1.65;
	color: var(--color-navy-900, #0c2347);
}

/* --- A grid of labelled choices --------------------------------------- */

.tk-choices {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
	gap: 10px;
}

.tk-choice {
	display: block;
	padding: 12px 14px;
	border: 1px solid var(--color-border, #e2e8ec);
	border-radius: 12px;
	background: #fff;
	text-align: left;
	cursor: pointer;
	/* The floor iOS expects, reached by padding rather than a height so a
	   wrapped label grows the button instead of spilling out of it. */
	min-height: 44px;
}

.tk-choice:hover,
.tk-choice:focus-visible {
	border-color: var(--color-primary, #028b93);
	background: var(--color-primary-soft, #e6f4f5);
}

.tk-choice__name {
	display: block;
	font-size: 14px;
	font-weight: 750;
	color: var(--color-navy-900, #0c2347);
}

.tk-choice__note {
	display: block;
	margin-top: 3px;
	font-size: 12px;
	line-height: 1.45;
	color: var(--color-text-muted, #5c6b7a);
}

/* --- The signature pad -------------------------------------------------- */

.tk-sign {
	position: relative;
	border: 1px dashed #b7cad8;
	border-radius: 14px;
	background: #fcfdfe;
	overflow: hidden;
}

.tk-sign__pad {
	display: block;
	width: 100%;
	height: 260px;
	/* Without this a finger drag scrolls the page instead of drawing, which
	   is the whole tool failing on the device it suits best. */
	touch-action: none;
	cursor: crosshair;
}

/* The line to sign on, drawn behind the ink. */
.tk-sign__rule {
	position: absolute;
	left: 9%;
	right: 9%;
	bottom: 33%;
	margin: 0;
	border-top: 1px solid #cbd9e4;
	pointer-events: none;
}

.tk-sign__hint {
	position: absolute;
	left: 9%;
	bottom: calc(33% + 8px);
	margin: 0;
	font-size: 13px;
	color: #9aafc0;
	pointer-events: none;
}

.tk-sign__hint[hidden] { display: none; }

@media (max-width: 600px) {
	.tk-sign__pad { height: 190px; }
}

/* --- The reference list ------------------------------------------------- */

.tk-refs {
	margin: 12px 0 0;
	padding: 0;
	list-style: none;
	display: grid;
	gap: 8px;
	counter-reset: tk-ref;
}

.tk-refs[hidden] { display: none; }

.tk-ref {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 12px 14px;
	border: 1px solid var(--color-border, #e2e8ec);
	border-radius: 12px;
	background: #fff;
}

.tk-ref__text {
	flex: 1 1 auto;
	min-width: 0;
	font-size: 14.5px;
	line-height: 1.6;
	color: var(--color-navy-900, #0c2347);
	/* A DOI or a long URL must wrap rather than widen the page. */
	overflow-wrap: anywhere;
}

.tk-ref__do {
	flex: 0 0 auto;
	display: flex;
	gap: 6px;
}

/* Words, not symbols: "Edit" and "Remove" beside a reference are two
   different destructive-looking actions and a pencil next to a bin is a
   guess every time. */
.tk-ref__do .tk-icon-btn {
	width: auto;
	min-width: 44px;
	height: 36px;
	padding: 0 11px;
	font-size: 13px;
	font-weight: 700;
}

.tk-refs__empty {
	margin: 12px 0 0;
	padding: 22px 16px;
	border: 1px dashed #b7cad8;
	border-radius: 12px;
	background: #fff;
	text-align: center;
	font-size: 14px;
	color: var(--color-text-muted, #5c6b7a);
}

.tk-refs__empty[hidden] { display: none; }

@media (max-width: 560px) {
	.tk-ref {
		flex-direction: column;
		gap: 10px;
	}

	.tk-ref__do .tk-icon-btn { flex: 1 1 auto; }
}

/* A long grouped zone list is the one <select> on the site worth widening:
   "America/Argentina/Rio_Gallegos (ART, GMT-3)" is not a short label. */
#tk-tz-from,
#tk-tz-to { min-width: min(100%, 22rem); }

/* --- The bar that says work is happening -------------------------------
   Built by assets/js/toolkit.js and put directly above the status line, so
   a tool gets one without a line of its own markup. With a fraction it
   fills and shows a percentage; without one a stripe travels across it,
   because a bar sitting at zero reads as a tool that has stopped. */

.tk-progress {
	margin: 14px 0 0;
	padding: 13px 15px;
	border: 1px solid #CFE3F2;
	border-radius: 12px;
	background: #F4FAFF;
}
.tk-progress[hidden] { display: none; }

.tk-progress__line {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	margin: 0 0 9px;
	font-size: 13px;
	font-weight: 700;
	color: #175289;
}
.tk-progress__pc { font-variant-numeric: tabular-nums; color: #3C6F9E; }

.tk-progress__track {
	position: relative;
	height: 8px;
	border-radius: 999px;
	background: #DCEAF7;
	overflow: hidden;
}
.tk-progress__fill {
	height: 100%;
	width: 0;
	border-radius: inherit;
	background: linear-gradient(90deg, #0A9B99, #0869D5);
	transition: width .18s linear;
}
/* No fraction: a stripe that travels, rather than an empty bar. */
.tk-progress.is-waiting .tk-progress__fill {
	width: 40%;
	transition: none;
	animation: tk-progress-slide 1.1s ease-in-out infinite;
}
@keyframes tk-progress-slide {
	0%   { transform: translateX(-105%); }
	100% { transform: translateX(255%); }
}
@media (prefers-reduced-motion: reduce) {
	.tk-progress.is-waiting .tk-progress__fill { animation: none; width: 100%; opacity: .55; }
	.tk-progress__fill { transition: none; }
}

/* --- Reorder PDF Pages: the draggable tiles ----------------------------
   The older page grid (.tk-pages--split and friends) is a grid of buttons,
   because there a page is picked rather than moved. Here a page is a card
   that can be dragged, with two arrows on it so the tool also works from a
   phone and from a keyboard. */

.tk-pages--reorder { grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); }
.tk-pages--reorder .tk-page { list-style: none; }

.tk-page__card {
	display: grid;
	justify-items: center;
	gap: 7px;
	padding: 10px 8px 8px;
	border: 2px solid var(--color-border, #e2e8ec);
	border-radius: 12px;
	background: #fff;
	cursor: grab;
}
.tk-pages--reorder .tk-page:active .tk-page__card { cursor: grabbing; }
.tk-pages--reorder .tk-page.is-dragging .tk-page__card { opacity: .4; border-color: var(--tk-strong, #028b93); }
.tk-page__card .tk-page__label { margin: 0; }
.tk-page__btns { display: flex; gap: 6px; margin: 0; }
.tk-page__btns .tk-icon-btn { width: 32px; height: 32px; font-size: 15px; }

@media (pointer: coarse) {
	.tk-page__btns .tk-icon-btn { width: 44px; height: 44px; }
}

/* --- Extract Text: the box only exists once there is text in it -------- */
.tk-form [data-tk-after][hidden],
.tk-form textarea[hidden] { display: none !important; }

/* --- QR Code Generator -------------------------------------------------
   The code and its settings side by side, so the thing being changed and
   the thing changing are in view together. */

.tk-qrout { display: grid; gap: 18px; align-items: start; }
@media (min-width: 620px) {
	.tk-qrout { grid-template-columns: 264px minmax(0, 1fr); }
}
.tk-qrout__code {
	display: grid;
	place-items: center;
	min-height: 264px;
	padding: 12px;
	border: 1px solid #DCE8F3;
	border-radius: 16px;
	background: #fff;
}
.tk-qrout__code svg { display: block; width: 100%; height: auto; max-width: 240px; }
/* Nothing typed yet: a frame with a reason in it, not a fake code. */
.tk-qrout__code[data-empty] { background: #F4F8FC; border-style: dashed; }
.tk-qrout__side { display: grid; gap: 14px; }
.tk-qrout__side .tk-field { flex: none; }

/* --- Image Metadata ----------------------------------------------------
   Groups of name-and-value, with the location warning given its own
   weight: it is the one finding that can matter to someone's safety. */

.tk-meta { display: grid; gap: 18px; }
.tk-meta[hidden] { display: none; }
.tk-meta__head {
	margin: 0;
	font-size: 13px;
	font-weight: 800;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: #51617A;
}
.tk-meta__head + .tk-meta__list { margin-top: -10px; }
.tk-meta__list { display: grid; gap: 1px; margin: 0; background: #E6EDF4; border: 1px solid #E6EDF4; border-radius: 12px; overflow: hidden; }
.tk-meta__list > div { display: grid; grid-template-columns: minmax(130px, 38%) minmax(0, 1fr); gap: 0; background: #fff; }
.tk-meta__list dt { padding: 9px 13px; font-size: 13px; font-weight: 700; color: #0B2247; background: #F7FAFD; }
.tk-meta__list dd { margin: 0; padding: 9px 13px; font-size: 13px; color: #324560; word-break: break-word; }

.tk-meta__warn {
	padding: 15px 17px;
	border: 1px solid #F0C9A6;
	border-left: 4px solid #B44E05;
	border-radius: 0 14px 14px 0;
	background: #FFF6EE;
}
.tk-meta__warn h3 { margin: 0 0 7px; font-size: 15px; font-weight: 800; color: #8F3E04; }
.tk-meta__warn p { margin: 0 0 7px; font-size: 13.5px; line-height: 1.55; color: #5B4230; }
.tk-meta__warn p:last-child { margin-bottom: 0; }
.tk-meta__warn a { color: #8F3E04; font-weight: 700; }

.tk-meta__extras { margin: 0; padding-left: 20px; font-size: 13px; line-height: 1.6; color: #324560; }
.tk-meta__none { margin: 0; padding: 14px 16px; border-radius: 12px; background: #EEF8F1; border: 1px solid #C7E6D2; font-size: 14px; line-height: 1.55; color: #1F5A3C; }

@media (max-width: 520px) {
	.tk-meta__list > div { grid-template-columns: 1fr; }
	.tk-meta__list dt { padding-bottom: 2px; background: #fff; }
	.tk-meta__list dd { padding-top: 0; }
}

/* --- Document Scanner --------------------------------------------------
   The photograph with its four draggable corners on the left, and what it
   will become on the right. Side by side matters here: the corners are
   being dragged to change the thing beside them. */

.tk-scan__strip { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 16px; padding: 0; list-style: none; }
.tk-scan__thumb { position: relative; }
.tk-scan__thumb > button:first-child {
	display: grid;
	gap: 4px;
	justify-items: center;
	padding: 6px 6px 4px;
	border: 2px solid var(--color-border, #e2e8ec);
	border-radius: 10px;
	background: #fff;
	cursor: pointer;
}
.tk-scan__thumb.is-on > button:first-child { border-color: var(--tk-strong, #028b93); background: var(--tk-pastel, #e6f6f7); }
.tk-scan__thumb canvas { display: block; max-width: 74px; max-height: 74px; border-radius: 4px; }
.tk-scan__n { font-size: 12px; font-weight: 800; color: #0B2247; }
.tk-scan__drop {
	position: absolute;
	top: -7px;
	right: -7px;
	width: 24px;
	height: 24px;
	border: 1px solid #D9C2C2;
	border-radius: 50%;
	background: #fff;
	color: #B3261E;
	font-size: 15px;
	line-height: 1;
	cursor: pointer;
}

.tk-scan__work { display: grid; gap: 18px; align-items: start; }
@media (min-width: 760px) {
	.tk-scan__work { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.tk-scan__stage {
	position: relative;
	/* The canvas inside decides the height, so the overlay that covers it
	   covers the picture and nothing else. */
	display: block;
	font-size: 0;
	max-width: 100%;
	border-radius: 12px;
	background: #EFF3F8;
	/* The corners are dragged across it: a drag must not scroll the page. */
	touch-action: none;
}
.tk-scan__photo { display: block; width: 100%; height: auto; border-radius: 12px; }
.tk-scan__quad { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.tk-scan__quad polygon { fill: rgba(10, 155, 153, .16); stroke: #0A9B99; stroke-width: 2; }
.tk-scan__grip {
	position: absolute;
	width: 26px;
	height: 26px;
	margin: -13px 0 0 -13px;
	padding: 0;
	border: 3px solid #fff;
	border-radius: 50%;
	background: #0A9B99;
	box-shadow: 0 2px 7px rgba(11, 34, 71, .35);
	cursor: grab;
	touch-action: none;
}
.tk-scan__grip:focus-visible { outline: 3px solid #0B2247; outline-offset: 3px; }
@media (pointer: coarse) {
	.tk-scan__grip { width: 34px; height: 34px; margin: -17px 0 0 -17px; }
}

.tk-scan__out { margin: 0; padding: 12px; border-radius: 12px; background: #EFF3F8; }
.tk-scan__out figcaption { margin-bottom: 9px; font-size: 13px; font-weight: 700; color: var(--dash-navy, #0B2247); }
.tk-scan__out canvas {
	display: block;
	max-width: 100%;
	max-height: 520px;
	height: auto;
	margin: 0 auto;
	border-radius: 4px;
	background: #fff;
	box-shadow: 0 4px 14px rgba(11, 34, 71, .14);
}

/* --- Image Background Remover ------------------------------------------
   The photograph and the cut-out side by side, because the brush is
   painted on one and judged on the other. The chequerboard is how you see
   transparency; without it a white cut-out on a white card looks solid. */

.tk-cut__stage { display: grid; gap: 16px; margin-bottom: 18px; }
@media (min-width: 720px) {
	.tk-cut__stage { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.tk-cut__pane { margin: 0; }
.tk-cut__pane figcaption { margin-bottom: 8px; font-size: 13px; font-weight: 700; color: var(--dash-navy, #0B2247); }
.tk-cut__holder {
	position: relative;
	max-width: 100%;
	border-radius: 12px;
	overflow: hidden;
	background: #EFF3F8;
	touch-action: none;
}
.tk-cut__holder canvas { display: block; width: 100%; height: auto; }
.tk-cut__brush { position: absolute; inset: 0; cursor: crosshair; }
.tk-cut__holder--check {
	background-color: #fff;
	background-image:
		linear-gradient(45deg, #DDE6EE 25%, transparent 25%),
		linear-gradient(-45deg, #DDE6EE 25%, transparent 25%),
		linear-gradient(45deg, transparent 75%, #DDE6EE 75%),
		linear-gradient(-45deg, transparent 75%, #DDE6EE 75%);
	background-size: 20px 20px;
	background-position: 0 0, 0 10px, 10px -10px, -10px 0;
}
/* Buttons at the end of a settings row.
   NOT a .tk-field: a row whose children are all fields becomes a subgrid
   of equal columns higher up this file, and a pair of buttons dropped into
   one of those columns wraps one under the other however much room the row
   has. Anything that is not a field keeps the row as a flex row. */
.tk-row > .tk-actions { align-self: end; margin-top: 0; }

/* --- Image to Text (OCR) -----------------------------------------------
   The picture beside the settings, so the member can see what is about to
   be read while choosing how to read it. */

.tk-ocr__row { display: grid; gap: 16px; align-items: start; }
@media (min-width: 680px) {
	.tk-ocr__row { grid-template-columns: minmax(0, 220px) minmax(0, 1fr); }
}
.tk-ocr__shot {
	display: block;
	width: 100%;
	max-width: 220px;
	height: auto;
	border-radius: 10px;
	background: #fff;
	box-shadow: 0 3px 12px rgba(11, 34, 71, .15);
}
.tk-ocr__shot[hidden] { display: none; }
.tk-ocr__set { display: grid; gap: 14px; min-width: 0; }

/* ==========================================================================
   TEXT TOOLS AND THE SIGNATURE PAD: KEEP WHAT IS BEING CHANGED IN SIGHT
   ========================================================================== */

/* A step that is only a heading, because what belongs under it has to be a
   child of the form to be able to stay on screen - see .tk-pin. */
.tk-step__body:empty { display: none; }
.tk-step:has(> .tk-step__body:empty) { margin-bottom: -6px; }

/* --- The line under a text box: count, and the ways to start over ----------- */

.tk-textbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 14px;
}
.tk-textbar__stats {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 4px 12px;
	margin: 0;
	font-size: 13px;
	color: var(--color-text-muted, #5c6b7a);
	font-variant-numeric: tabular-nums;
}
.tk-textbar__changed {
	font-weight: 750;
	color: #1f6a4c;
}
.tk-textbar__changed[hidden] { display: none; }
.tk-textbar__buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.tk-textbar .btn {
	min-height: 38px;
	padding: 7px 12px;
	font-size: 13px;
}
.tk-textbar .btn[hidden] { display: none; }

/* The box lights up when a button below it has changed what is in it, so the
   reader can see where to look. Not a pulse that repeats: one fade. */
.tk-form textarea.is-flash {
	animation: tk-flash 1.3s ease-out;
}
@keyframes tk-flash {
	0%   { border-color: #1f9d6b; box-shadow: 0 0 0 4px rgba(31, 157, 107, .28); background: #f1fbf6; }
	100% { box-shadow: 0 0 0 0 rgba(31, 157, 107, 0); }
}
@media (prefers-reduced-motion: reduce) {
	.tk-form textarea.is-flash { animation: none; border-color: #1f9d6b; }
}

/* --- A box that stays on screen while the page scrolls past ---------------- */

/*
 * The signature pad. 64px clears the account's sticky top bar; the soft
 * shadow underneath is what says "this is floating over the options", so
 * the Pen controls do not look as if they are being clipped by it.
 */
.tk-pin {
	position: sticky;
	top: 64px;
	z-index: 20;
	margin-inline: -6px;
	padding: 8px 6px 12px;
	background: #fff;
	box-shadow: 0 12px 14px -12px rgba(11, 34, 71, .22);
}
.tk-form > .tk-pin + .tk-note { margin-top: 12px; }
@media (max-width: 600px) {
	.tk-pin { top: 56px; }
	.tk-pin .tk-sign__pad { height: 170px; }
}

/* The pen: its value beside the label, and a stroke drawn in it. */
.tk-pen__val {
	margin-left: 6px;
	font-weight: 750;
	color: var(--color-primary-ink, #02737a);
	font-variant-numeric: tabular-nums;
}
.tk-pen {
	display: flex;
	flex-direction: column;
	gap: 4px;
	flex: 0 1 260px;
	min-width: 0;
}
.tk-pen__label {
	font-size: 13px;
	font-weight: 700;
	color: var(--color-navy-900, #0c2347);
}
.tk-pen svg {
	display: block;
	width: 100%;
	max-width: 240px;
	height: auto;
	padding: 4px 8px;
	border: 1px dashed #b7cad8;
	border-radius: 10px;
	background: #fcfdfe;
}

/* The cropped file, on the squares that say "transparent". */
.tk-sign-preview {
	margin: 0;
}
.tk-sign-preview[hidden] { display: none; }
.tk-sign-preview img {
	display: block;
	max-width: 100%;
	height: auto;
	max-height: 150px;
	padding: 10px;
	border: 1px solid #d6e2ec;
	border-radius: 12px;
	object-fit: contain;
	background:
		conic-gradient(#eef3f7 25%, #fff 0 50%, #eef3f7 0 75%, #fff 0) 0 0 / 16px 16px;
}
.tk-sign-preview figcaption {
	margin-top: 6px;
	font-size: 12px;
	color: var(--color-text-muted, #5c6b7a);
}

/* ==========================================================================
   TIME ZONE CONVERTER

   The left-hand side only, built to "time zone converter.jpeg": three
   numbered questions and an answer panel. The tool's header, its Quick Guide
   and the banner are the Toolkit's own and are drawn around this.
   ========================================================================== */

.tz { display: grid; gap: 22px; }

.tz-step {
	display: grid;
	grid-template-columns: 34px minmax(0, 1fr);
	gap: 0 14px;
	align-items: start;
}
.tz-step + .tz-step { padding-top: 0; border-top: 0; }
.tz-step__n {
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: linear-gradient(150deg, #10335F 0%, #0B2247 100%);
	font-size: 14px;
	font-weight: 800;
	color: #fff;
}
.tz-step__main { min-width: 0; }
.tz-step__title {
	margin: 0 0 2px;
	font-size: 17px;
	font-weight: 800;
	line-height: 1.3;
	color: #15489C;
}
.tz-step__lead {
	margin: 0 0 12px;
	font-size: 13px;
	line-height: 1.5;
	color: var(--dash-slate, #51617A);
}
.tz-step__lead strong { color: #0B2247; font-weight: 700; }

/* A field as drawn: an icon, the value, and a chevron on the ones that open
   a list. The real <input> or <select> fills the whole box, transparent, so
   a tap anywhere on it opens the platform's own picker. */
.tz-pair {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 12px;
}
.tz-pair--go { grid-template-columns: minmax(0, 1fr) auto; align-items: stretch; }

.tz-control {
	position: relative;
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
	height: 44px;
	padding: 0 12px;
	border: 1px solid var(--color-border, #d7e1e8);
	border-radius: var(--radius-sm, 10px);
	background: #fff;
	color: #0B2247;
	transition: border-color .15s, box-shadow .15s;
}
.tz-control:focus-within {
	border-color: #0F7F8A;
	box-shadow: 0 0 0 3px rgba(15, 127, 138, .15);
}
.tz-control__icon,
.tz-control__chev { flex: none; display: inline-flex; color: #5C6F86; pointer-events: none; }
.tz-control__icon svg { width: 18px; height: 18px; }
.tz-control__chev svg { width: 16px; height: 16px; }
.tz-control__chev { margin-left: auto; }
.tz-control__text {
	flex: 1 1 auto;
	min-width: 0;
	font-size: 15px;
	font-weight: 600;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	pointer-events: none;
}
.tz-control__text.is-empty { font-weight: 500; color: #7B8CA3; }

.tz-control input,
.tz-control select {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	min-width: 0;
	margin: 0;
	padding: 0 12px;
	border: 0;
	border-radius: var(--radius-sm, 10px);
	background: transparent;
	font: inherit;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
}
/* The date: the native control is invisible, and only its picker shows. */
.tz-control--date input { opacity: 0; }
.tz-control--date input::-webkit-calendar-picker-indicator {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	cursor: pointer;
}
/* The selects write their own value, in the design's type, indented past the
   icon and clear of the chevron. */
.tz-control select {
	padding-left: 40px;
	padding-right: 36px;
	font-size: 15px;
	font-weight: 600;
	color: #0B2247;
	text-overflow: ellipsis;
}
.tz-control--time select { font-weight: 600; }
.tz-control select:focus { outline: none; }

.tz-go {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 44px;
	padding: 10px 20px;
	border: 0;
	border-radius: 12px;
	background: #0B2247;
	font: inherit;
	font-size: 14px;
	font-weight: 700;
	color: #fff;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color .15s, transform .15s;
}
.tz-go svg { width: 18px; height: 18px; color: #3FD0C9; }
.tz-go:hover,
.tz-go:focus-visible { background: #123566; }
.tz-go:active { transform: translateY(1px); }

/* --- The answer ------------------------------------------------------------- */

.tz-answer[hidden] { display: none; }
.tz-panel {
	padding: 16px 18px 16px;
	border-radius: 14px;
	background: linear-gradient(180deg, #E5F5EC 0%, #F1FAF4 100%);
	border: 1px solid #D3EBDC;
}
.tz-panel__title {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0 0 12px;
	font-size: 17px;
	font-weight: 800;
	color: #1F6B3E;
}
.tz-panel__title svg { flex: none; width: 22px; height: 22px; }
.tz-cards {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
	gap: 10px;
	align-items: center;
}
.tz-card {
	min-width: 0;
	padding: 12px 14px;
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 6px 18px rgba(21, 60, 40, .07);
}
.tz-card__where {
	display: flex;
	align-items: center;
	gap: 9px;
	margin: 0 0 4px;
	font-size: 13.5px;
	line-height: 1.3;
	color: #1B2B44;
	overflow-wrap: anywhere;
}
.tz-card__where strong { font-weight: 800; }
.tz-flag { flex: none; display: block; width: 30px; height: 20px; border-radius: 3px; object-fit: cover; box-shadow: 0 0 0 1px rgba(11, 34, 71, .12); }
.tz-flag--globe { width: 24px; height: 24px; box-shadow: none; color: #0F4D5E; }
.tz-card__time {
	margin: 0;
	font-size: clamp(24px, 2.6vw, 30px);
	font-weight: 800;
	line-height: 1.15;
	letter-spacing: -0.02em;
	color: #0B2247;
	font-variant-numeric: tabular-nums;
}
.tz-cards .tz-card:last-child .tz-card__time { color: #1D7A2C; }
.tz-card__date { margin: 2px 0 0; font-size: 13.5px; color: #3A4A60; }
.tz-arrow { display: inline-flex; color: #14816F; }
.tz-arrow svg { width: 22px; height: 22px; }

.tz-sentence {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 12px 0 0;
	padding: 9px 12px;
	border-radius: 10px;
	background: #D6EDC8;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.35;
	color: #1A2F26;
}
.tz-sentence strong { font-weight: 800; }
.tz-sentence__tick {
	flex: none;
	display: grid;
	place-items: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	background: #1B9A4B;
	color: #fff;
}
.tz-sentence__tick svg { width: 15px; height: 15px; }
.tz-answer__day { margin: 10px 2px 0; font-size: 13px; font-weight: 700; color: #7A4A06; }

.tz-copy { margin: 0; }
.tz-copybtn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	padding: 10px 18px;
	border: 1px solid var(--color-border, #d7e1e8);
	border-radius: 12px;
	background: #fff;
	font: inherit;
	font-size: 14px;
	font-weight: 700;
	color: #0B2247;
	cursor: pointer;
}
.tz-copybtn svg { width: 18px; height: 18px; }
.tz-copybtn[hidden] { display: none; }
.tz-copybtn:hover,
.tz-copybtn:focus-visible { border-color: #0F7F8A; background: #F4FAFB; }

@media (max-width: 720px) {
	.tz-step { grid-template-columns: 30px minmax(0, 1fr); gap: 0 10px; }
	.tz-step__n { width: 30px; height: 30px; font-size: 13px; }
	.tz-pair,
	.tz-pair--go { grid-template-columns: minmax(0, 1fr); }
	.tz-go { width: 100%; }
	.tz-control__text,
	.tz-control select { font-size: 16px; }   /* 16px: iOS zooms into anything smaller */
	.tz-panel { padding: 14px 12px; }
	.tz-cards { grid-template-columns: minmax(0, 1fr); }
	.tz-arrow { justify-self: center; transform: rotate(90deg); }
	.tz-card__time { font-size: 26px; }
	.tz-sentence { font-size: 13.5px; }
}

/* ==========================================================================
   MERGE AND IMAGES TO PDF: THE FILES AS CARDS

   A picture of each file with its name under it, in the order it will be
   saved - the way iLovePDF shows a merge ("pdf-tools-preview.jpeg"). Drag a
   card to move it; the arrows on it do the same without a pointer.
   ========================================================================== */

.tk-filebar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
}
.tk-filebar__add,
.tk-filebar__sort {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	padding: 0 16px;
	border-radius: 999px;
	font: inherit;
	font-size: 14px;
	font-weight: 750;
	cursor: pointer;
}
.tk-filebar__add {
	border: 0;
	background: var(--color-primary-ink, #02737a);
	color: #fff;
}
.tk-filebar__add:hover,
.tk-filebar__add:focus-visible { background: #01565b; }
.tk-filebar__count {
	display: grid;
	place-items: center;
	min-width: 24px;
	height: 24px;
	padding: 0 6px;
	border-radius: 999px;
	background: #fff;
	font-size: 12px;
	font-weight: 800;
	color: var(--color-primary-ink, #02737a);
}
.tk-filebar__sort {
	border: 1px solid var(--color-border, #e2e8ec);
	background: #fff;
	color: var(--color-navy-900, #0c2347);
}
.tk-filebar__sort:hover,
.tk-filebar__sort:focus-visible { border-color: var(--color-primary, #028b93); background: var(--color-primary-soft, #e6f4f5); }

.tk-order--cards {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	gap: 14px;
	margin-top: 14px;
	padding: 16px;
	border-radius: 14px;
	background: #f1f5f9;
	counter-reset: none;
}
.tk-card:not([data-tk-card]) {
	position: relative;
	display: grid;
	justify-items: center;
	gap: 6px;
	padding: 10px 10px 8px;
	border: 1px solid #e0e7ee;
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 2px 8px rgba(12, 35, 71, .06);
	cursor: grab;
	transition: box-shadow .15s, transform .15s, border-color .15s;
}
.tk-card::before { content: none; }
.tk-card:hover { box-shadow: 0 8px 20px rgba(12, 35, 71, .12); }
.tk-card.is-dragging { opacity: .45; cursor: grabbing; }
.tk-card.is-over { border-color: var(--color-primary, #028b93); box-shadow: 0 0 0 3px rgba(2, 139, 147, .25); }

.tk-card__n {
	position: absolute;
	top: 8px;
	left: 8px;
	z-index: 1;
	display: grid;
	place-items: center;
	min-width: 24px;
	height: 24px;
	padding: 0 6px;
	border-radius: 999px;
	background: var(--color-navy-900, #0c2347);
	font-size: 12px;
	font-weight: 800;
	color: #fff;
}
.tk-card__x {
	position: absolute;
	top: 6px;
	right: 6px;
	z-index: 1;
	display: grid;
	place-items: center;
	width: 26px;
	height: 26px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .92);
	box-shadow: 0 1px 4px rgba(12, 35, 71, .25);
	font-size: 18px;
	line-height: 1;
	color: #b3261e;
	cursor: pointer;
}
.tk-card__x:hover,
.tk-card__x:focus-visible { background: #fdf0f1; }

.tk-card__page {
	display: grid;
	place-items: center;
	width: 100%;
	height: 170px;
	border-radius: 6px;
	background: #f6f8fa;
	overflow: hidden;
}
.tk-card__img {
	display: block;
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	box-shadow: 0 2px 8px rgba(12, 35, 71, .22);
	/* The picture must not start a native image drag - the card drags. */
	-webkit-user-drag: none;
	user-select: none;
	pointer-events: none;
}
.tk-card__img--pdf {
	display: grid;
	place-items: center;
	width: 96px;
	height: 128px;
	border-radius: 4px;
	background: #fff;
	font-size: 18px;
	font-weight: 800;
	color: #d93a2b;
	letter-spacing: .04em;
}
.tk-card__name {
	display: block;
	width: 100%;
	overflow: hidden;
	text-align: center;
	text-overflow: ellipsis;
	white-space: nowrap;
	font-size: 13px;
	font-weight: 600;
	color: var(--color-navy-900, #0c2347);
}
.tk-card__meta {
	font-size: 12px;
	color: var(--color-text-muted, #5c6b7a);
}
.tk-card__btns {
	display: flex;
	gap: 6px;
}

@media (max-width: 640px) {
	.tk-order--cards {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 10px;
		padding: 10px;
	}
	.tk-card__page { height: 140px; }
}
