/*
 * PROOF-2: accreditation cards with number and validity.
 * One card for each certificate: the mark, the name, who issued it, then the
 * two facts a buyer checks, the certificate number and the date it runs to,
 * and a link to the certificate itself.
 */

.wprk-section.wprk-proof-2 .wprk-proof-2__list {
	gap: var(--wp--preset--spacing--40);
}

.wprk-proof-2 .wprk-proof-2__item {
	background-color: var(--wprk-card-bg);
	border: 1px solid var(--wprk-border);
	border-radius: var(--wp--custom--radius--lg);
	display: flex;
	flex-direction: column;
	padding: var(--wp--preset--spacing--40);
}

.wprk-proof-2 .wprk-proof-2__item > *,
.wprk-proof-2 .wprk-proof-2__facts > * {
	margin: 0;
	min-width: 0;
}

.wprk-proof-2 .wprk-proof-2__item > .wprk-proof-2__mark {
	margin-block-end: var(--wp--preset--spacing--30);
}

/* One height for every mark. The editor sets its own size on the image, hence the two !important. */
.wprk-proof-2 .wprk-proof-2__mark img {
	border-radius: 0;
	height: 3.5rem !important;
	object-fit: contain;
	width: auto !important;
}

/* Dark style: an image cannot read the colour variables, so the marks are shown in white. */
.wprk-proof-2[class*="is-style-wprk-dark"] .wprk-proof-2__mark img {
	filter: brightness(0) invert(1);
	opacity: 0.85;
}

.wprk-proof-2 .wprk-proof-2__item :where(h3) {
	font-size: var(--wp--preset--font-size--large);
	line-height: 1.3;
}

.wprk-proof-2 .wprk-proof-2__item > .wprk-muted {
	font-size: var(--wp--preset--font-size--small);
	line-height: 1.5;
	margin-block-start: 0.25rem;
}

/* The two facts stand on a hairline at the foot of the card, whatever the length of the name. */
.wprk-proof-2 .wprk-proof-2__item > .wprk-proof-2__facts {
	border-block-start: 1px solid var(--wprk-border);
	margin-block-start: auto;
	padding-block-start: var(--wp--preset--spacing--30);
}

.wprk-proof-2 .wprk-proof-2__item > :not(.wprk-proof-2__facts):has(+ .wprk-proof-2__facts) {
	margin-block-end: var(--wp--preset--spacing--30);
}

.wprk-proof-2 .wprk-proof-2__fact {
	color: var(--wprk-heading);
	font-size: var(--wp--preset--font-size--small);
	font-variant-numeric: lining-nums tabular-nums;
	font-weight: 600;
	line-height: 1.5;
}

.wprk-proof-2 .wprk-proof-2__item > .wp-block-buttons {
	margin-block-start: var(--wp--preset--spacing--10);
}

/* Editor: a new mark waits for its picture at the size of a mark, not of a photo. */
.wprk-proof-2 .wprk-proof-2__mark .components-placeholder {
	height: 3.5rem;
	min-height: 3.5rem;
	min-width: 3.5rem;
}
