/*
 * Окна конверсии по макету Figma: запись, обратный звонок и остальные.
 * Разметка одна на все окна — классы uc-modal__*.
 */

.uc-modal {
	position: fixed;
	inset: 0;
	/* Выше всплывающего меню: у него z-index 100, иначе окно окажется под ним. */
	z-index: 200;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
}

.uc-modal[hidden] {
	display: none;
}

.uc-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(3, 8, 21, .55);
}

.uc-modal__window {
	position: relative;
	width: 100%;
	max-width: 560px;
	max-height: calc(100vh - 48px);
	padding: 32px;
	border-radius: 20px;
	background: #F4F4F5;
	overflow-y: auto;
}

.uc-modal__close {
	position: absolute;
	top: 20px;
	right: 20px;
	width: 36px;
	height: 36px;
	border: none;
	border-radius: 50%;
	background: #fff;
	font-size: 13px;
	color: #5C616B;
	cursor: pointer;
	transition: background .2s ease;
}

.uc-modal__close:hover {
	background: #E1F0FB;
}

.uc-modal__title {
	max-width: calc(100% - 48px);
	font-size: 22px;
	font-weight: 600;
	line-height: 30px;
	color: #16181D;
}

.uc-modal__text {
	margin-top: 8px;
	font-size: 15px;
	line-height: 21px;
	color: #5C616B;
}

.uc-modal__form {
	margin-top: 20px;
}

.uc-modal__label {
	display: block;
}

.uc-modal__label + .uc-modal__label {
	margin-top: 8px;
}

.uc-modal__input {
	width: 100%;
	height: 48px;
	padding: 0 16px;
	border: none;
	border-radius: 12px;
	background: #fff;
	font-family: inherit;
	font-size: 15px;
	line-height: 21px;
	color: #16181D;
}

.uc-modal__input::placeholder {
	color: #9DA2AA;
}

.uc-modal__input:focus {
	outline: 2px solid #E1F0FB;
	outline-offset: 0;
}

/* Когда позвонить: плашки-переключатели, как в макете. */
.uc-modal__times {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 12px;
}

.uc-modal__time {
	cursor: pointer;
}

.uc-modal__time-input {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
}

.uc-modal__time-text {
	display: flex;
	align-items: center;
	height: 37px;
	padding: 0 13px;
	border-radius: 999px;
	background: #fff;
	font-size: 14px;
	line-height: 19px;
	color: #000;
	transition: background .2s ease;
}

.uc-modal__time-input:checked + .uc-modal__time-text {
	background: #E1F0FB;
}

.uc-modal__time-input:focus-visible + .uc-modal__time-text {
	outline: 2px solid #3A465A;
}

.uc-modal__submit {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 50px;
	margin-top: 20px;
	border: none;
	border-radius: 14px;
	background: #2B303C;
	font-family: inherit;
	font-size: 15px;
	line-height: 21px;
	color: #fff;
	cursor: pointer;
	transition: background .2s ease;
}

.uc-modal__submit:hover {
	background: #16181D;
}

.uc-modal__submit:disabled {
	opacity: .6;
	cursor: default;
}

/* Мессенджеры: тёмное окно с кнопками, как в макете. */
.uc-modal__window--dark {
	background: #2B303C;
}

.uc-modal__window--dark .uc-modal__title {
	color: #fff;
}

.uc-modal__window--dark .uc-modal__text {
	color: #A7ACB5;
}

.uc-modal__window--dark .uc-modal__close {
	background: #3A4152;
	color: #fff;
}

.uc-modal__window--dark .uc-modal__close:hover {
	background: #4A5265;
}

.uc-modal__links {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 20px;
}

.uc-modal__link {
	display: flex;
	align-items: center;
	min-height: 46px;
	padding: 12px 16px;
	border-radius: 12px;
	background: #242832;
	font-size: 15px;
	line-height: 21px;
	color: #fff;
	transition: background .2s ease;
}

.uc-modal__link:hover {
	background: #1A1E27;
	color: #fff;
}

/* Отказ в подсказке при уходе — второстепенная кнопка. */
.uc-modal__dismiss {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 44px;
	margin-top: 8px;
	border: none;
	border-radius: 12px;
	background: #fff;
	font-family: inherit;
	font-size: 15px;
	line-height: 21px;
	color: #5C616B;
	cursor: pointer;
	transition: background .2s ease;
}

.uc-modal__dismiss:hover {
	background: #E9EAEC;
}

/* ------------------------------------------------- лид-форма в блоке (2) -- */

.uc-lead {
	margin: 40px 0;
}

.uc-lead__card {
	padding: 32px 40px 36px;
	border-radius: 20px;
	background: #F4F4F5;
}

.uc-lead__title {
	font-size: 22px;
	font-weight: 600;
	line-height: 30px;
	color: #16181D;
}

.uc-lead__text {
	margin-top: 8px;
	font-size: 15px;
	line-height: 21px;
	color: #5C616B;
}

.uc-lead__form {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 16px;
}

.uc-lead__label {
	flex: 1 1 300px;
}

.uc-lead__input {
	width: 100%;
	height: 48px;
	padding: 0 16px;
	border: none;
	border-radius: 12px;
	background: #fff;
	font-family: inherit;
	font-size: 15px;
	line-height: 21px;
	color: #16181D;
}

.uc-lead__input::placeholder {
	color: #9DA2AA;
}

.uc-lead__submit {
	flex: 0 0 auto;
	height: 48px;
	padding: 0 20px;
	border: none;
	border-radius: 12px;
	background: #16181D;
	font-family: inherit;
	font-size: 15px;
	line-height: 21px;
	color: #fff;
	cursor: pointer;
	transition: background .2s ease;
}

.uc-lead__submit:hover {
	background: #2B303C;
}

.uc-lead__accept {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin-top: 16px;
	font-size: 14px;
	line-height: 19px;
	color: #5C616B;
	cursor: pointer;
}

.uc-lead__checkbox {
	flex-shrink: 0;
	width: 18px;
	height: 18px;
	margin-top: 1px;
	accent-color: #16181D;
	cursor: pointer;
}

.uc-lead--dark .uc-lead__checkbox {
	accent-color: #fff;
}

.uc-lead__accept-link {
	color: #16181D;
	text-decoration: underline;
}

/* Тёмный вариант — для светлых страниц. */
.uc-lead--dark .uc-lead__card {
	background: #2B303C;
}

.uc-lead--dark .uc-lead__title {
	color: #fff;
}

.uc-lead--dark .uc-lead__text,
.uc-lead--dark .uc-lead__accept {
	color: #A7ACB5;
}

.uc-lead--dark .uc-lead__accept-link {
	color: #fff;
}

.uc-lead--dark .uc-lead__submit {
	background: #fff;
	color: #16181D;
}

.uc-lead--dark .uc-lead__submit:hover {
	background: #E1F0FB;
}

@media (max-width: 768px) {
	.uc-lead__card {
		padding: 24px 16px;
	}

	.uc-lead__label,
	.uc-lead__submit {
		flex: 1 1 100%;
	}
}

/* ------------------------------------------------------------------ квиз -- */

.uc-quiz__answers {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 20px;
}

.uc-quiz__answer {
	display: flex;
	align-items: center;
	width: 100%;
	min-height: 47px;
	padding: 13px 16px;
	border: none;
	border-radius: 12px;
	background: #fff;
	font-family: inherit;
	font-size: 15px;
	line-height: 21px;
	color: #000;
	text-align: left;
	cursor: pointer;
	transition: background .2s ease;
}

.uc-quiz__answer:hover {
	background: #E1F0FB;
}

.uc-quiz__foot {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-top: 24px;
}

.uc-quiz__back {
	padding: 0;
	border: none;
	background: none;
	font-family: inherit;
	font-size: 14px;
	line-height: 19px;
	color: #5C616B;
	text-decoration: underline;
	cursor: pointer;
}

.uc-quiz__back:hover {
	color: #16181D;
}

.uc-quiz__bar {
	flex: 1 1 auto;
	height: 6px;
	border-radius: 999px;
	background: #fff;
	overflow: hidden;
}

.uc-quiz__bar-fill {
	display: block;
	height: 100%;
	border-radius: 999px;
	background: #16181D;
	transition: width .25s ease;
}

.uc-quiz__counter {
	flex-shrink: 0;
	font-size: 14px;
	line-height: 19px;
	color: #3D424B;
}

/* Согласие на обработку данных — обязательная галочка: без неё форма
   не отправляется, это требование заказчика ко всем формам сайта. */
.uc-modal__accept {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin-top: 14px;
	font-size: 14px;
	line-height: 19px;
	color: #5C616B;
	cursor: pointer;
}

.uc-modal__checkbox {
	flex-shrink: 0;
	width: 18px;
	height: 18px;
	margin-top: 1px;
	accent-color: #16181D;
	cursor: pointer;
}

.uc-modal__accept-link {
	color: #16181D;
	text-decoration: underline;
}

@media (max-width: 768px) {
	.uc-modal {
		align-items: flex-end;
		padding: 0;
	}

	/* На телефоне окно выезжает снизу и занимает ширину экрана. */
	.uc-modal__window {
		max-width: none;
		max-height: 90vh;
		padding: 24px 16px 28px;
		border-radius: 20px 20px 0 0;
	}

	.uc-modal__title {
		font-size: 19px;
		line-height: 26px;
	}
}
