/* Table: comparison table; rows stack into labelled blocks on small screens. */

.wu-table {
	overflow: hidden;
	border: 1px solid var(--wu-color-table-line);
	border-radius: var(--wu-radius-lg);
	background-color: var(--wu-color-surface);
	box-shadow: var(--wu-shadow-soft);
}

.wu-table__table {
	width: 100%;
	margin: 0;
	border-collapse: collapse;
	font-size: 0.9375rem;
	line-height: 1.45;
}

.wu-table__table th,
.wu-table__table td {
	padding: 14px 16px;
	border: 0;
	border-bottom: 1px solid var(--wu-color-table-line);
	color: var(--wu-color-text);
	text-align: left;
	vertical-align: top;
	/* Wrap between words (hyphenate where possible), never in the middle of a short word. */
	overflow-wrap: break-word;
	hyphens: auto;
}

@media (min-width: 768px) {
	.wu-table__table th:first-child {
		width: 18%;
	}

	.wu-table__table th:nth-child(2),
	.wu-table__table td:nth-child(2) {
		width: 22%;
	}
}

.wu-table__table thead th {
	background-color: var(--wu-color-table-head);
	font-weight: 700;
}

.wu-table__table tbody th {
	font-weight: 700;
}

.wu-table__table tbody tr:last-child > * {
	border-bottom: 0;
}

.wu-table__table tbody tr:hover {
	background-color: var(--wu-color-surface-alt);
}

.wu-table__table .wu-table__highlight {
	background-color: var(--wu-color-table-highlight);
	font-weight: 600;
}

.wu-table__table thead .wu-table__highlight {
	background-color: var(--wu-color-table-head-highlight);
}

@media (max-width: 767px) {
	.wu-table__table thead {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip-path: inset(50%);
	}

	.wu-table__table,
	.wu-table__table tbody,
	.wu-table__table tr,
	.wu-table__table th,
	.wu-table__table td {
		display: block;
	}

	.wu-table__table tr {
		padding: 8px 0;
		border-bottom: 1px solid var(--wu-color-table-line);
	}

	.wu-table__table tbody tr:last-child {
		border-bottom: 0;
	}

	.wu-table__table th,
	.wu-table__table td {
		padding: 6px 16px;
		border-bottom: 0;
	}

	.wu-table__table tbody th {
		font-size: 1.0625rem;
	}

	.wu-table__table td::before {
		content: attr(data-label);
		display: block;
		color: var(--wu-color-muted);
		font-size: 0.8125rem;
		font-weight: 600;
	}
}
