/*
 * Front-end styles for pbs/comparison-table. `__PREFIX__` is the neutral class prefix; logical
 * properties only (wp/bin/pbs-logical-css.php). Loaded only where this block renders.
 * The table scrolls sideways inside its own box on narrow screens; the page never does.
 */
.__PREFIX__-comparison-table {
	/* The containing block of the visually hidden texts inside, so they scroll with the table
	   instead of widening the page. */
	position: relative;
	max-inline-size: 100%;
	margin-block: 1.5em;
	overflow: auto;
}

.__PREFIX__-comparison-table:focus-visible {
	outline: 2px solid currentcolor;
	outline-offset: 2px;
}

.__PREFIX__-comparison-table__table {
	inline-size: 100%;
	min-inline-size: 28em;
	border-collapse: collapse;
}

.__PREFIX__-comparison-table__caption {
	padding-block-end: 0.5em;
	font-weight: 700;
	text-align: start;
}

.__PREFIX__-comparison-table__table th,
.__PREFIX__-comparison-table__table td {
	padding-block: 0.65em;
	padding-inline: 0.75em;
	border-block-end: 1px solid rgb(0 0 0 / 15%);
	vertical-align: middle;
}

.__PREFIX__-comparison-table__feature {
	font-weight: 600;
	text-align: start;
}

.__PREFIX__-comparison-table__plan,
.__PREFIX__-comparison-table__cell {
	text-align: center;
}

.__PREFIX__-comparison-table__plan {
	font-weight: 700;
}

.__PREFIX__-comparison-table__plan--highlight,
.__PREFIX__-comparison-table__cell--highlight {
	background-color: rgb(0 0 0 / 5%);
}

.__PREFIX__-comparison-table__plan--highlight {
	border-block-start: 4px solid var(--wp--preset--color--contrast, #111);
}

.__PREFIX__-comparison-table__cell--yes,
.__PREFIX__-comparison-table__cell--no {
	line-height: 0;
}

.__PREFIX__-comparison-table__cell svg {
	inline-size: 1.25em;
	block-size: 1.25em;
}

.__PREFIX__-comparison-table__cell--yes {
	color: #1f7a45;
}

.__PREFIX__-comparison-table__cell--no {
	color: #8a1f1f;
}

/* Shared by the G-B blocks. Each block file carries its own copy, because a page loads only the
   stylesheets of the blocks it uses. */
.__PREFIX__-accent--primary {
	--__PREFIX__-accent: var(--wp--preset--color--primary, var(--wp--preset--color--accent-3, #5b21b6));
}

.__PREFIX__-accent--secondary {
	--__PREFIX__-accent: var(--wp--preset--color--secondary, var(--wp--preset--color--accent-4, #3f3f46));
}

.__PREFIX__-accent--contrast {
	--__PREFIX__-accent: var(--wp--preset--color--contrast, currentcolor);
}

.__PREFIX__-accent--text {
	--__PREFIX__-accent: currentcolor;
}

.__PREFIX__-kit-icon,
.__PREFIX__-kit-icon svg {
	display: inline-block;
	line-height: 0;
}

.__PREFIX__-sr {
	position: absolute;
	inline-size: 1px;
	block-size: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

/* On a phone a table of one to three plans fits the screen instead of scrolling: the minimum width
   pushed the plan columns out of view and visitors saw only the feature names (pagebuildersandwich.com,
   390 px, 2026-10-04). Wider tables still scroll inside their own box. */
@media (max-width: 37.5em) {
	.__PREFIX__-comparison-table__table:not(:has(thead th:nth-of-type(4))) {
		min-inline-size: 0;
	}

	.__PREFIX__-comparison-table__table th,
	.__PREFIX__-comparison-table__table td {
		padding-inline: 0.4em;
		overflow-wrap: break-word;
	}

	.__PREFIX__-comparison-table__feature {
		inline-size: 50%;
	}
}
