/* Форма заявки в контенте (plg_system_emform). Префикс .emf */
.emf {
	--emf-w: 100%;
	--emf-bg: linear-gradient(110deg, #bde3f8 0%, #a3cbf3 38%, #8eb4f0 68%, #82a6ee 100%);
	--emf-text: #111;
	--emf-btn: #b70928;
	--emf-btn-text: #fff;
	--emf-radius: 12px;
	--emf-pad: 26px 26px 20px;
	--emf-gap: 24px;
	--emf-input-bg: #fff;
	--emf-err: #b70928;
	--emf-link: #b70928;

	box-sizing: border-box;
	width: 100%;
	max-width: var(--emf-w);
	margin: var(--emf-gap) auto;
	padding: var(--emf-pad);
	border-radius: var(--emf-radius);
	background: var(--emf-bg);
	color: var(--emf-text);
	text-align: left;
	container-type: inline-size;
	container-name: emf;
}
.emf *, .emf *::before, .emf *::after { box-sizing: border-box; }
.emf--shadow { box-shadow: 0 6px 24px rgba(29, 75, 115, .16); }

/* Положение блока */
.emf--pos-left { margin-left: 0; margin-right: auto; }
.emf--pos-right { margin-left: auto; margin-right: 0; }

/* Обтекание текстом (float="yes") */
.emf--float { width: var(--emf-w); max-width: 100%; }
.emf--float.emf--pos-left { float: left; margin: 4px 28px 16px 0; }
.emf--float.emf--pos-right { float: right; margin: 4px 0 16px 28px; }

.emf__form { margin: 0; }

/* Заголовок */
.emf__head { margin: 0 0 22px; }
.emf--align-center .emf__head { text-align: center; }
.emf--align-right .emf__head { text-align: right; }
.emf .emf__title {
	margin: 0;
	padding: 0;
	font-size: 24px;
	font-weight: 500;
	line-height: 1.25;
	color: inherit;
	text-transform: none;
	letter-spacing: 0;
	border: 0;
}
.emf .emf__title::before, .emf .emf__title::after { display: none; }
.emf .emf__subtitle { margin: 8px 0 0; font-size: 18px; line-height: 1.35; }

/* Поля */
.emf__fields { display: flex; gap: 12px; align-items: stretch; }
.emf__field { display: block; flex: 1 1 0; min-width: 0; margin: 0; }
.emf__sr {
	position: absolute;
	width: 1px; height: 1px; margin: -1px; padding: 0;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.emf .emf__input {
	display: block;
	width: 100%;
	height: 40px;
	margin: 0;
	padding: 0 12px;
	border: 1px solid transparent;
	border-radius: 4px;
	background: var(--emf-input-bg);
	color: #222;
	font: inherit;
	font-size: 15px;
	line-height: 38px;
	box-shadow: none;
	outline: none;
	transition: border-color .15s, box-shadow .15s;
}
.emf--ph-center .emf__input { text-align: center; }
.emf .emf__input::placeholder { color: #808080; opacity: 1; }
.emf .emf__input:focus { border-color: #1d4b73; box-shadow: 0 0 0 2px rgba(29, 75, 115, .18); }
.emf .emf__input--err, .emf .emf__input--err:focus { border-color: var(--emf-err); box-shadow: 0 0 0 2px rgba(183, 9, 40, .18); }
.emf .emf__select {
	-webkit-appearance: none;
	appearance: none;
	padding-right: 30px;
	cursor: pointer;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23555' stroke-width='1.6'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
}
.emf .emf__select:invalid { color: #808080; }
.emf .emf__select option { color: #222; }

.emf .emf__btn {
	flex: 0 0 auto;
	height: 40px;
	margin: 0;
	padding: 0 14px;
	border: 0;
	border-radius: 4px;
	background: var(--emf-btn);
	color: var(--emf-btn-text);
	font: inherit;
	font-size: 15px;
	line-height: 40px;
	white-space: nowrap;
	cursor: pointer;
	transition: filter .15s, opacity .15s;
}
.emf .emf__btn:hover { filter: brightness(1.12); }
.emf--btn-hover .emf__btn:hover { background: var(--emf-btn-hover); filter: none; }
.emf .emf__btn:focus-visible { outline: 2px solid #1d4b73; outline-offset: 2px; }
.emf .emf__btn:disabled { opacity: .65; cursor: wait; }

/* Галочки */
.emf__check {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 16px 0 0;
	font-size: 13px;
	line-height: 1.35;
	cursor: pointer;
}
.emf__check[hidden] { display: none; }
.emf .emf__check input {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: 0;
	accent-color: #1d4b73;
	cursor: pointer;
}
.emf .emf__check a { color: var(--emf-link); text-decoration: underline; }
.emf .emf__check a:hover { text-decoration: none; }
.emf__check--err { color: var(--emf-err); }
.emf .emf__check--err input { outline: 2px solid var(--emf-err); outline-offset: 1px; }
.emf__intl { margin-top: 10px; }
.emf__subscribe { margin-top: 8px; }

.emf__captcha:not(:empty) { margin-top: 14px; }

.emf__msg:empty { display: none; }
.emf__msg { margin-top: 12px; font-size: 14px; line-height: 1.35; }
.emf__msg--err { color: var(--emf-err); }
.emf__msg--info { color: #1d4b73; }

.emf__form--busy .emf__btn { cursor: wait; }

.emf__done { font-size: 18px; line-height: 1.4; text-align: center; padding: 6px 0 4px; }
.emf--align-left .emf__done { text-align: left; }

.emf__hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Поля столбиком */
.emf--column .emf__fields { flex-direction: column; }
.emf--column .emf__field { flex: 0 0 auto; }
.emf--column .emf__btn { width: 100%; }

/* Узкая форма: перестройка по ширине самого блока, а не экрана */
@container emf (max-width: 760px) {
	.emf--row .emf__fields { flex-wrap: wrap; }
	.emf--row .emf__field { flex: 1 1 calc(50% - 6px); }
	.emf--row .emf__btn { flex: 1 1 100%; }
}
@container emf (max-width: 480px) {
	.emf--row .emf__field { flex: 1 1 100%; }
	.emf .emf__title { font-size: 20px; }
	.emf .emf__subtitle { font-size: 16px; }
}

/* Браузеры без container queries */
@supports not (container-type: inline-size) {
	@media (max-width: 991px) {
		.emf--row .emf__fields { flex-wrap: wrap; }
		.emf--row .emf__field { flex: 1 1 calc(50% - 6px); }
		.emf--row .emf__btn { flex: 1 1 100%; }
	}
}

@media (max-width: 767px) {
	.emf { padding: 20px 16px 16px; }
	.emf--float.emf--pos-left, .emf--float.emf--pos-right { float: none; width: 100%; margin: var(--emf-gap) 0; }
	.emf--row .emf__field { flex: 1 1 100%; }
	.emf .emf__title { font-size: 20px; }
	.emf .emf__subtitle { font-size: 16px; }
}
