/* Callback popup — Figma 4268:2331 */

.callback-modal[hidden] {
	display: none !important;
}

.callback-modal {
	position: fixed;
	inset: 0;
	z-index: 10000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

.callback-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.32);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
}

.callback-modal__dialog {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: 500px;
	padding: 24px;
	background: #fffffe;
	border-radius: 20px;
	box-sizing: border-box;
}

.callback-modal__close {
	position: absolute;
	top: 20px;
	right: 20px;
	width: 20px;
	height: 20px;
	padding: 0;
	border: none;
	background: transparent;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 2;
}

.callback-modal__close:hover {
	opacity: 0.7;
}

.callback-modal__view--form {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.callback-modal__view[hidden] {
	display: none !important;
}

.callback-modal__view--success,
.callback-modal__view--error {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 24px;
	min-height: 212px;
	text-align: center;
}

.callback-modal__header {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.callback-modal__title {
	margin: 0;
	font-family: var(--font-family-primary);
	font-size: 24px;
	font-weight: 600;
	line-height: 28px;
	color: #212121;
}

.callback-modal__desc {
	margin: 0;
	font-family: var(--font-family-primary);
	font-size: 16px;
	font-weight: 400;
	line-height: 20px;
	color: #212121;
	white-space: pre-wrap;
}

.callback-form {
	display: flex;
	flex-direction: column;
	gap: 12px;
	width: 100%;
}

.callback-form__fields {
	display: flex;
	flex-direction: column;
	gap: 12px;
	width: 100%;
}

.callback-form__field {
	display: flex;
	flex-direction: column;
	gap: 7px;
	width: 100%;
}

.callback-form__input,
.callback-form__textarea {
	width: 100%;
	height: 50px;
	padding: 12px 20px;
	border: 1px solid #dbdbdb;
	border-radius: 12px;
	background: #fffffe;
	box-sizing: border-box;
	font-family: var(--font-family-primary);
	font-size: 16px;
	font-weight: 400;
	line-height: 20px;
	color: #212121;
	outline: none;
	transition: border-color 0.2s ease;
}

.callback-form__textarea {
	height: auto;
	min-height: 90px;
	resize: vertical;
}

.callback-form__input::placeholder,
.callback-form__textarea::placeholder {
	color: #7f8081;
}

.callback-form__input:focus,
.callback-form__textarea:focus {
	border-color: #212121;
}

.callback-form__field--error .callback-form__input,
.callback-form__field--error .callback-form__textarea {
	border-color: #cf1f19;
}

.callback-form__error {
	display: none;
	font-family: var(--font-family-primary);
	font-size: 14px;
	font-weight: 400;
	line-height: 20px;
	color: #cf1f19;
}

.callback-form__field--error .callback-form__error {
	display: block;
}

.callback-form__consent {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	font-family: var(--font-family-primary);
	font-size: 14px;
	line-height: 18px;
	color: #7f8081;
	cursor: pointer;
	user-select: none;
	position: relative;
}

.callback-form__checkbox {
	position: absolute;
	opacity: 0;
	width: 0;
	height: 0;
	pointer-events: none;
}

.callback-form__check {
	position: relative;
	width: 18px;
	height: 18px;
	flex-shrink: 0;
	margin-top: 1px;
	border: 1px solid #212121;
	border-radius: 3px;
	background: transparent;
	transition: background-color 0.2s ease;
}

.callback-form__check::after {
	content: "";
	position: absolute;
	opacity: 0;
	width: 10px;
	height: 7px;
	top: 5px;
	left: 3px;
	background: url('/local/templates/latonit/components/bitrix/form.result.new/request/check.svg') no-repeat center / contain;
	transition: opacity 0.2s ease;
}

.callback-form__checkbox:checked + .callback-form__check {
	background: #212121;
}

.callback-form__checkbox:checked + .callback-form__check::after {
	opacity: 1;
}

.callback-form__checkbox:focus-visible + .callback-form__check {
	outline: 2px solid #212121;
	outline-offset: 2px;
}

.callback-form__consent-text {
	flex: 1;
	min-width: 0;
	font-size: 14px;
	line-height: 18px;
	color: #7f8081;
}

.callback-form__consent-text a {
	color: #212121;
	text-decoration: underline;
}

.callback-form__consent-text a:hover {
	opacity: 0.75;
}

.callback-form__field--consent.callback-form__field--error .callback-form__check {
	border-color: #cf1f19;
}

.callback-form__field--consent.callback-form__field--error .callback-form__consent-text {
	color: #cf1f19;
}

.callback-form__select {
	width: 100%;
	min-height: 50px;
	padding: 12px 20px;
	border: 1px solid #dbdbdb;
	border-radius: 12px;
	background: #fffffe;
	box-sizing: border-box;
	font-family: var(--font-family-primary);
	font-size: 16px;
	font-weight: 400;
	line-height: 20px;
	color: #212121;
	outline: none;
}

.callback-form__field--error .callback-form__select {
	border-color: #cf1f19;
}

.callback-form__options {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.callback-form__option {
	display: flex;
	align-items: center;
	gap: 8px;
	font-family: var(--font-family-primary);
	font-size: 16px;
	line-height: 20px;
	color: #212121;
	cursor: pointer;
}

.callback-form__file {
	width: 100%;
	font-family: var(--font-family-primary);
	font-size: 14px;
}

.callback-form__submit {
	width: 100%;
	height: 50px;
	padding: 12px 16px;
	border: none;
	border-radius: 20px;
	background: #212121;
	font-family: var(--font-family-primary);
	font-size: 18px;
	font-weight: 500;
	line-height: 24px;
	color: #fffffe;
	cursor: pointer;
	transition: opacity 0.2s ease;
}

.callback-form__submit:hover {
	opacity: 0.85;
}

.callback-form__submit:disabled {
	opacity: 0.6;
	cursor: wait;
}

.callback-modal__status-icon {
	width: 58px;
	height: 58px;
	flex-shrink: 0;
}

.callback-modal__status-icon svg {
	display: block;
	width: 100%;
	height: 100%;
}

.callback-modal__status-text {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	width: 100%;
}

.callback-modal__status-title {
	margin: 0;
	font-family: var(--font-family-primary);
	font-size: 24px;
	font-weight: 600;
	line-height: 28px;
	color: #212121;
}

.callback-modal__status-desc {
	margin: 0;
	max-width: 380px;
	font-family: var(--font-family-primary);
	font-size: 16px;
	font-weight: 400;
	line-height: 20px;
	color: #212121;
}

body.callback-modal-open {
	overflow: hidden;
}

@media (max-width: 575px) {
	.callback-modal {
		align-items: flex-end;
		padding: 16px;
	}

	.callback-modal__dialog {
		max-width: none;
		padding: 16px;
		border-radius: 20px;
	}

	.callback-modal__status-icon {
		width: 48px;
		height: 48px;
	}

	.callback-modal__view--success,
	.callback-modal__view--error {
		min-height: 228px;
	}
}
