/* BP page ("Моделирование бизнес-процессов") — extras on top of main.css. */

/* Hero chart: bars + trend line + dots, composed from the original Zero Block pieces
   (box 663 x 508 px on the 1200 px Tilda grid). */
.bp-chart {
	position: relative;
	width: 100%;
	max-width: 663px;
	margin-left: auto;
	aspect-ratio: 663 / 508;
}

.bp-chart > .wp-block-image {
	position: absolute;
	margin: 0;
}

.m-hero__media.bp-chart img {
	width: 100%;
	height: 100%;
}

.bp-chart__bars {
	top: 0;
	left: 4.83%;
	width: 91.86%;
	height: 100%;
}

.bp-chart__line {
	top: 3.74%;
	left: 2.26%;
	width: 97.74%;
	height: 73.03%;
}

.bp-chart__dot {
	width: 5.43%;
	aspect-ratio: 1;
}

.bp-chart__dot--1 { top: 73.03%; left: 0; }
.bp-chart__dot--2 { top: 51.97%; left: 16.14%; }
.bp-chart__dot--3 { top: 65.94%; left: 33.63%; }
.bp-chart__dot--4 { top: 26.38%; left: 59.13%; }
.bp-chart__dot--5 { top: 39.37%; left: 78.88%; }

/* Hero: the 4-line title needs a wider text column than the CRM hero. */
.m-hero:has(.bp-chart) {
	grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
}

.m-hero:has(.bp-chart) .m-hero__title {
	max-width: none;
	font-size: clamp(30px, 3vw, 43px);
}

/* Expert card: the medium-weight sentence. */
.bp-expert__accent {
	font-weight: 500;
}

/* Stage cards: column proportions of the original (work / result / documents);
   the last column needs no right padding. */
.m-stage--cols {
	grid-template-columns: 1.35fr 1fr 1.25fr;
}

.m-stage--cols .m-stage__result {
	font-size: clamp(20px, 1.6vw, 22px);
}

.m-stage--cols > .wp-block-group:last-child {
	padding-right: 0;
}

.m-stage--cols .m-stage__label {
	margin-top: 2px;
	font-size: 15px;
}

/* Stage cards: the "Документы по результату…" label sits above the big blue title. */
.m-stage--cols .m-stage__label + .m-stage__result {
	margin-top: 12px;
}

.m-stage > .m-stage__label + .m-stage__result {
	margin-top: 10px;
}

/* Contact: "Хотите:" above the check list. */
.bp-contact__label {
	margin-bottom: 20px;
	font-size: clamp(16px, 1.4vw, 18px);
	font-weight: 500;
}

.bp-contact__intro .is-style-m-checks {
	font-size: clamp(16px, 1.3vw, 17px);
}

@media (max-width: 960px) {
	.m-hero:has(.bp-chart) {
		grid-template-columns: minmax(0, 1fr);
	}

	.bp-chart {
		margin: 10px auto 0;
	}

	.m-stage--cols {
		grid-template-columns: minmax(0, 1fr);
	}

	.m-stage--cols > .wp-block-group:last-child {
		padding-right: 0;
	}
}

@media (max-width: 640px) {
	.bp-chart {
		max-width: 420px;
	}
}
