/* Формы обратной связи (макет заказчика 02.11.2026): «Обсудим ваш запрос» на /contact и «Узнать подробнее об объекте»
   в окне заявки (карточка объекта, каталог, акции, поиск). Цвета, поля и кнопки — в стиле сайта. */

.cr-form {
	--crf-ink: #262929;
	--crf-teal: #239eba;
	--crf-teal-d: #1b879f;
	--crf-muted: #7f8f8f;
	--crf-line: #dbe3e3;
	--crf-soft: #f3f6f6;
	--crf-err: #d9534f;
	color: var(--crf-ink);
	font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

.cr-form__eyebrow {
	display: block;
	margin: 0 0 10px;
	font-size: 12px;
	font-weight: 500;
	line-height: 1.2;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--crf-teal-d);
}

.cr-form__title {
	margin: 0 0 12px;
	font-size: 30px;
	font-weight: 500;
	line-height: 1.2;
	color: var(--crf-ink);
}

.cr-form__lead {
	margin: 0 0 24px;
	font-size: 15px;
	font-weight: 400;
	line-height: 1.5;
	color: var(--crf-muted);
}

.cr-form__field {
	margin: 0 0 16px;
}

.cr-form__field label {
	display: block;
	margin: 0 0 8px;
	font-size: 15px;
	font-weight: 400;
	line-height: 1.4;
	color: var(--crf-ink);
}

.cr-form__req {
	color: var(--crf-teal);
}

.cr-form__opt {
	color: var(--crf-muted);
}

.cr-form__field input,
.cr-form__field textarea {
	display: block;
	box-sizing: border-box;
	width: 100%;
	height: auto;
	margin: 0;
	padding: 14px 24px;
	border: 1px solid var(--crf-line);
	border-radius: 100px;
	background: #fff;
	box-shadow: none;
	font: 400 15px/1.4 Inter, system-ui, sans-serif;
	color: var(--crf-ink);
	outline: 0;
	transition: border-color .2s;
	-webkit-appearance: none;
	appearance: none;
}

.cr-form__field textarea {
	min-height: 104px;
	border-radius: 16px;
	resize: vertical;
}

.cr-form__field input::placeholder,
.cr-form__field textarea::placeholder {
	color: var(--crf-muted);
	opacity: 1;
}

.cr-form__field input:focus,
.cr-form__field textarea:focus {
	border-color: var(--crf-teal);
}

.cr-form__field.has-error input,
.cr-form__field.has-error textarea {
	border-color: var(--crf-err);
}

.cr-form__err {
	margin: 6px 0 0;
	font-size: 13px;
	line-height: 1.4;
	color: var(--crf-err);
}

.cr-form__err--js {
	margin: 0 0 12px;
}

.cr-form__agree {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	margin: 4px 0 0;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.45;
	color: var(--crf-ink);
	cursor: pointer;
}

.cr-form__agree input {
	flex: 0 0 20px;
	width: 20px;
	height: 20px;
	margin: 0;
	accent-color: var(--crf-teal);
	cursor: pointer;
}

.cr-form__agree a {
	color: var(--crf-teal-d) !important;
	text-decoration: underline;
}

/* Между согласием и кнопкой 20 px (просьба заказчика: «добавить 10-20 пикселей») */
.cr-form__agree + .cr-form__err,
.cr-form__agree {
	margin-bottom: 20px;
}

.cr-form__submit {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	box-sizing: border-box;
	width: 100%;
	min-height: 54px;
	margin: 0;
	padding: 16px 20px;
	border: 0;
	border-radius: 50px;
	background: #111;
	font: 500 15px/1.2 Inter, system-ui, sans-serif;
	letter-spacing: .02em;
	text-transform: uppercase;
	color: #fff;
	cursor: pointer;
	transition: background .2s;
}

.cr-form__submit:hover {
	background: var(--crf-teal-d);
}

.cr-form__submit[disabled] {
	background: #5d6363;
	cursor: wait;
}

.cr-form__alt {
	margin: 20px 0 0;
	padding: 18px 0 0;
	border-top: 1px solid var(--crf-line);
	text-align: center;
}

.cr-form__alt-label {
	display: block;
	font-size: 14px;
	line-height: 1.4;
	color: var(--crf-muted);
}

.cr-form__alt-phone {
	display: inline-block;
	margin-top: 4px;
	font-size: 20px;
	font-weight: 600;
	line-height: 1.3;
	color: var(--crf-ink) !important;
	text-decoration: none !important;
	white-space: nowrap;
}

.cr-form__alt-phone:hover {
	color: var(--crf-teal) !important;
}

/* Cloudflare Turnstile в режиме interaction-only: пока проверка не нужна, блок пустой и места не занимает.
   Виджет вручную не прячем — отступ появляется, только когда Cloudflare его показывает или проверка не загрузилась. */
.cr-ts {
	margin: 0;
}

.cr-ts.is-visible,
.cr-ts.is-failed,
.cr-ts.is-error {
	margin: 4px 0 16px;
}

.cr-ts .cf-turnstile {
	display: flex;
	justify-content: center;
	max-width: 100%;
	overflow: hidden;
}

.cr-ts__msg {
	margin: 0 0 8px;
	font-size: 13px;
	line-height: 1.4;
	color: #d9534f;
}

.cr-ts__fail {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 12px;
	font-size: 13px;
	line-height: 1.4;
	color: #d9534f;
}

.cr-ts__fail[hidden] {
	display: none;
}

.cr-ts__retry {
	padding: 6px 14px;
	border: 1px solid #dbe3e3;
	border-radius: 50px;
	background: #fff;
	font: 500 13px/1.2 Inter, system-ui, sans-serif;
	color: #262929;
	cursor: pointer;
}

/* ===== /contact: карточка формы справа от офисов ===== */
.crc .crc-form.cr-form {
	padding: 40px 44px 36px;
}

@media (max-width: 1100px) {
	.crc .crc-form.cr-form {
		padding: 32px 28px 30px;
	}
}

@media (max-width: 768px) {
	.crc .crc-form.cr-form {
		padding: 28px 20px 26px;
	}

	.cr-form__title {
		font-size: 24px;
	}

	.cr-form__field input,
	.cr-form__field textarea {
		font-size: 16px; /* iPhone не увеличивает страницу при вводе */
	}
}

/* ===== Окно заявки по объекту ===== */
/* Тема рисует у .modal-dialog свою белую подложку с отступом 50 px и центрирует окно по высоте:
   высокое окно уходило верхом за экран. Теперь окно сверху, лишнее прокручивается вместе с подложкой */
#myModal.cr-req.in {
	align-items: flex-start !important;
	padding: 24px 0;
}

#myModal.cr-req .modal-dialog {
	width: 600px;
	max-width: calc(100% - 24px);
	margin: auto;
	padding: 0;
	background: none;
	box-shadow: none;
}

/* Форма в окне сохранила id="oneclick" (его ждут старые скрипты темы), а правила темы #oneclick input / label
   сильнее классов — повторяем свои с #myModal */
#myModal .cr-form__field label {
	margin: 0 0 8px;
	font-size: 15px;
	color: #262929;
}

#myModal .cr-form__field input,
#myModal .cr-form__field textarea {
	height: auto;
	padding: 14px 24px;
	border: 1px solid #dbe3e3;
	background: #fff;
	font-size: 15px;
}

#myModal .cr-form__field input:focus,
#myModal .cr-form__field textarea:focus {
	border-color: #239eba;
}

#myModal .cr-form__field textarea {
	border-radius: 16px;
}

#myModal .cr-form__agree {
	display: flex;
	margin: 4px 0 20px;
	font-size: 13px;
	line-height: 1.45;
	color: #262929;
}

#myModal .cr-form__agree input {
	flex: 0 0 20px;
	width: 20px;
	height: 20px;
	padding: 0;
	border: 0;
	background: none;
}

#myModal .cr-form a {
	margin: 0;
}

#myModal.cr-req .cr-req__box {
	position: relative;
	padding: 40px 44px 32px;
	border-radius: 20px;
	background: #fff;
	box-shadow: 0 20px 60px rgba(15, 39, 49, .18);
}

#myModal.cr-req .cr-req__close {
	position: absolute;
	top: 16px;
	right: 16px;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 1px solid #dbe3e3;
	border-radius: 50%;
	background: #fff;
	cursor: pointer;
	opacity: 1;
}

#myModal.cr-req .cr-req__close::before,
#myModal.cr-req .cr-req__close::after {
	content: "";
	position: absolute;
	left: 50%;
	top: 50%;
	width: 16px;
	height: 1.5px;
	margin: -.75px 0 0 -8px;
	background: #262929;
	transform: rotate(45deg);
}

#myModal.cr-req .cr-req__close::after {
	transform: rotate(-45deg);
}

#myModal.cr-req .cr-form__title {
	margin-right: 44px;
}

.cr-req__obj {
	display: flex;
	align-items: center;
	gap: 14px;
	margin: 0 0 16px;
	padding: 10px;
	border: 1px solid #dbe3e3;
	border-radius: 16px;
}

.cr-req__obj-img {
	flex: 0 0 96px;
	width: 96px;
	height: 68px;
	border-radius: 10px;
	object-fit: cover;
	background: #f3f6f6;
}

.cr-req__obj-img[hidden] {
	display: none;
}

.cr-req__obj-text {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
}

.cr-req__obj-name {
	display: -webkit-box;
	overflow: hidden;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	font-size: 15px;
	font-weight: 500;
	line-height: 1.35;
	color: #262929;
}

.cr-req__obj-price {
	font-size: 14px;
	line-height: 1.3;
	color: #7f8f8f;
}

.cr-req__obj-price:empty {
	display: none;
}

.cr-req .cr-form__lead {
	margin-bottom: 20px;
}

.cr-req .cr-form__alt {
	margin-top: 18px;
}

.cr-req .contact-buttons {
	display: flex;
	justify-content: center;
	gap: 12px;
	margin-top: 10px;
}

.cr-req .contact-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: #f3f6f6;
}

@media (max-width: 768px) {
	#myModal .cr-form__field input,
	#myModal .cr-form__field textarea {
		font-size: 16px; /* iPhone не увеличивает страницу при вводе */
	}
}

@media (max-width: 600px) {
	#myModal.cr-req.in {
		padding: 12px 0;
	}

	#myModal.cr-req .cr-req__box {
		padding: 28px 18px 22px;
		border-radius: 18px;
	}

	#myModal.cr-req .cr-req__close {
		top: 12px;
		right: 12px;
	}

	.cr-req__obj-img {
		flex-basis: 76px;
		width: 76px;
		height: 56px;
	}
}
