/**
 * Pricing table.
 *
 * Minimal and colour-free apart from the reached row, which tints with
 * currentColor so it reads on a light or a dark theme. Typography, colour and
 * spacing come from the theme, or from the block's own supports.
 */

.wcdp-table {
	margin: 0 0 1.5em;
}

.wcdp-table__table {
	border-collapse: collapse;
	width: 100%;
	max-width: 32em;
	margin: 0;
}

.wcdp-table__caption {
	text-align: left;
	font-weight: 600;
	padding-bottom: 0.35em;
}

/* Three classes deep: Storefront's striping is (0,2,4) and must not win. */
.wcdp-table .wcdp-table__table th,
.wcdp-table .wcdp-table__table td,
.wcdp-table .wcdp-table__table .wcdp-table__row th,
.wcdp-table .wcdp-table__table .wcdp-table__row td {
	text-align: left;
	padding: 0.45em 1em 0.45em 0.5em;
	font-weight: 400;
	border: 0;
	border-top: 1px solid color-mix( in srgb, currentColor 15%, transparent );
	background: transparent;
}

.wcdp-table .wcdp-table__table thead th {
	border-top: 0;
	font-size: 0.85em;
	opacity: 0.75;
}

.wcdp-table .wcdp-table__table .wcdp-table__row.is-active th,
.wcdp-table .wcdp-table__table .wcdp-table__row.is-active td {
	background: color-mix( in srgb, currentColor 8%, transparent );
	font-weight: 600;
}

.wcdp-table__savings {
	white-space: nowrap;
}

.wcdp-table__nudge,
.wcdp-table__choose,
.wcdp-table__note {
	font-size: 0.9em;
	margin: 0.5em 0 0;
}

.wcdp-table__note {
	opacity: 0.75;
}

.wcdp-table [hidden] {
	display: none !important;
}

.wcdp-table .wcdp-table__table .wcdp-table__name {
	display: block;
	font-weight: 600;
}
