/*
 * M8 topic card (group class meckup-topic-card), used by section-learn-topics
 * and section-learn-training. Fill, radius and padding are block attributes.
 * Figma LE 2960:4664 / 2960:4667: image → 36 → heading → 36 → body. The
 * editor's block gap can't hold a calc(), so the 36 px is set here.
 */

.meckup-topic-card.is-layout-flow > * + * {
	margin-block-start: calc(3 * var(--wp--preset--spacing--30));
}

/*
 * One card per row below 1024 (interim, no mobile design yet). Two up, the
 * cards are 303-419 px wide at 900-1023 and the 4x-large titles run 3 lines.
 * The core grid already goes to one column below about 790.
 */
@media (max-width: 1023px) {
	.meckup-learn-topics.is-layout-grid {
		grid-template-columns: minmax(0, 1fr);
	}
}

/*
 * Below 600 the card padding drops from L (32 there) to S (20), so the titles
 * get a 275 px column instead of 251. The padding is the preset in the block
 * (editors still see "L"); redefining the token on the card changes what it
 * resolves to, without !important. Padding an editor changes isn't affected.
 */
@media (max-width: 599px) {
	.meckup-topic-card {
		--wp--preset--spacing--60: var(--wp--preset--spacing--40);
	}
}
