/* Engineering tools — spec-sheet plain. Read on a desktop in an office and on
   a phone in a plant, so type stays large and tables scroll rather than crush. */

.ce-tool {
	--ce-rule: #d3d7d2;
	--ce-ink-soft: #4e565b;
	--ce-accent: #17456b;
	margin: 2rem 0;
}

.ce-tool__title {
	margin: 0 0 .5rem;
}

.ce-tool__intro {
	color: var(--ce-ink-soft);
	max-width: 60ch;
}

.ce-tool__form {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
	gap: 1rem;
	margin: 1.5rem 0 1rem;
}

.ce-tool__field label {
	display: block;
	font-size: .8rem;
	font-weight: 600;
	margin-bottom: .25rem;
}

.ce-tool__field input {
	width: 100%;
	padding: .5rem .6rem;
	border: 1px solid var(--ce-rule);
	border-radius: 2px;
	font-size: 1rem;
	font-variant-numeric: tabular-nums;
}

.ce-tool__field input:focus-visible {
	outline: 2px solid var(--ce-accent);
	outline-offset: 1px;
}

.ce-tool__result {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: .4rem 1rem;
	padding: 1rem;
	border-left: 3px solid var(--ce-accent);
	background: rgba(23, 69, 107, .06);
	margin-bottom: 2rem;
}

.ce-tool__result-figure {
	font-size: 2rem;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	line-height: 1;
}

.ce-tool__result-unit {
	color: var(--ce-ink-soft);
}

.ce-tool__result-total {
	margin-left: auto;
	font-variant-numeric: tabular-nums;
}

.ce-tool__table-wrap {
	overflow-x: auto;
	border: 1px solid var(--ce-rule);
}

.ce-tool__table {
	width: 100%;
	min-width: 32rem;
	border-collapse: collapse;
	font-variant-numeric: tabular-nums;
}

.ce-tool__table th,
.ce-tool__table td {
	padding: .5rem .75rem;
	text-align: left;
	border-bottom: 1px solid var(--ce-rule);
}

.ce-tool__table thead th {
	font-size: .75rem;
	text-transform: uppercase;
	letter-spacing: .08em;
	white-space: nowrap;
}

.ce-tool__table tbody tr:hover {
	background: rgba(23, 69, 107, .05);
	cursor: pointer;
}

.ce-tool__note {
	font-size: .85rem;
	color: var(--ce-ink-soft);
	max-width: 60ch;
	margin-top: .75rem;
}
