/* PAGE-3: split page title. The title on the left, its summary on the right, standing on one line. */

.wprk-page-3.wprk-section {
	padding-block: var(--wp--preset--spacing--60);
}

.wprk-page-3 .wprk-page-3__inner {
	align-items: end;
	column-gap: var(--wp--preset--spacing--60);
	display: grid;
	grid-template-columns: minmax(0, 1fr);
}

.wprk-page-3 .wprk-page-3__inner > * {
	grid-column: 1;
	margin-block: 0;
	min-width: 0;
}

.wprk-page-3 .wprk-page-3__inner > * + * {
	margin-block-start: var(--wp--preset--spacing--20);
}

.wprk-page-3 .wp-block-breadcrumbs {
	color: var(--wprk-muted);
	font-size: var(--wp--preset--font-size--small);
	line-height: 1.6;
}

/*
 * Every crumb is a tap target 2.75rem high. The negative margin gives the
 * extra height back, so the crumbs take the room of one line of small text.
 */
.wprk-page-3 .wprk-page-3__inner > .wp-block-breadcrumbs {
	margin-block: calc((1.6em - 2.75rem) / 2);
}

.wprk-page-3 .wp-block-breadcrumbs :where(li) {
	min-height: 2.75rem;
}

.wprk-page-3 .wp-block-breadcrumbs :where(a) {
	align-items: center;
	align-self: stretch;
	display: flex;
}

.wprk-page-3 :where(h1) {
	font-size: var(--wp--preset--font-size--huge);
	line-height: 1.12;
	max-width: 16em;
}

.wprk-page-3 .wprk-page-3__inner > .wprk-lead {
	margin-block-start: var(--wp--preset--spacing--30);
	max-width: 34rem;
}

.wprk-page-3 .wprk-page-3__inner > .wprk-lead :where(p) {
	margin: 0;
}

/* A search field in the bar of a template is no wider than a line of text. */
.wprk-page-3 .wprk-page-3__inner > :where(.wp-block-search) {
	max-width: 40rem;
}

/*
 * Wide screens: two columns, when there is a summary to put in the second.
 * The crumbs run above both. The summary stands on the base line of whatever
 * the first column ends with, behind a line in the accent colour.
 */
@media (min-width: 782px) {
	.wprk-page-3 .wprk-page-3__inner:has(> .wprk-lead:not(:empty)) {
		grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
	}

	.wprk-page-3 .wprk-page-3__inner > .wp-block-breadcrumbs {
		grid-column: 1 / -1;
	}

	.wprk-page-3 .wprk-page-3__inner > .wprk-lead:not(:empty) {
		align-self: end;
		border-inline-start: 2px solid var(--wprk-accent);
		grid-column: 2;
		grid-row: 2 / span 4;
		margin-block-start: 0;
		padding-inline-start: var(--wp--preset--spacing--40);
	}

	.wprk-page-3 .wprk-page-3__inner:not(:has(> .wp-block-breadcrumbs)) > .wprk-lead:not(:empty) {
		grid-row: 1 / span 4;
	}
}
