/* Скрываем скролл страницы при открытом попапе */
html:has(.overlay:target) {
	overflow: hidden;
	width: 100%;
	height: 100%;
}
html:has(.overlay:target) body {
    overflow: hidden;
}
/* Основной контейнер попапа */
.overlay {
	position: fixed;
	inset: 0;
	z-index: 9999;
	visibility: hidden;
	opacity: 0;
	transition: opacity 0.3s, visibility 0.3s;
	overflow-y: auto;
	overscroll-behavior: contain;
	-webkit-overflow-scrolling: touch;
	pointer-events: none;
	display: grid;
}
.overlay > * {
	grid-area: 1 / 1;
}
.overlay:target {
	visibility: visible;
	opacity: 1;
	pointer-events: auto;
}
/* Фон попапа */
.overlay-bg {
	position: sticky;
	top: 0;
	min-height: 100vh;
	min-height: 100dvh;
	background: rgba(0, 0, 0, 0.6);
	cursor: pointer;
	z-index: 1;
	pointer-events: auto;
}
/* Обертка контента попапа */
.popup-wrapper {
	display: grid;
	place-items: center;
	z-index: 2;
	pointer-events: none;
	margin: 50px 0 50px 0;
}
/* Контент попапа */
.popup {
	position: relative;
	width: 90%;
	max-width: 400px;
	min-width: 200px;
	background: #fff;
	border-radius: 30px;
	padding: 0 40px 40px 40px;
	box-shadow: 0 15px 20px rgba(0, 0, 0, 0.22), 0 19px 60px rgba(0, 0, 0, 0.3);
	transform: scale(0.8);
	opacity: 0;
	transition: transform 0.3s ease-out, opacity 0.3s ease-out;
	pointer-events: auto;
	box-sizing: border-box;
}
.w60{
max-width: 60%;
min-width: 200px;
}
@media only screen and (max-width:1700px) {
.w60{
max-width: 70%;
}
}
@media only screen and (max-width:1390px) {
.w60{
max-width: 80%;
}
}
@media only screen and (max-width:1250px) {
.w60{
max-width: 90%;
}
}
@media only screen and (max-width:1100px) {
.w60{
max-width: 100%;
}
}
.popcnt{
	text-align: center;
}
.popup h2 {
	text-align: center;
	font-size: 20px;
	margin: 30px 0 20px 0;
	padding-bottom: 20px;
	font-weight: 700;
	color: #223767;
	border-bottom: 1px solid #f4f7f8;
	hyphens: manual !important;
}
.popup p {
hyphens: manual !important;
}
.popup h4,
.popup b {
display: block;
font-weight: 600;
font-size: 18px;
}
.popup h4 {
	font-weight: 700;
  color: #223767;
  line-height: 20px;
}
.popup b {
  font-size: 12px;
  line-height: 20px;
  text-transform: uppercase;
  color: #838d91;
  font-weight: 400;
	margin-bottom:10px;
}
.popup form div> label {
color: #223767;
font-weight: 600;
	margin-bottom:5px;
}
.popup form div> label b{
	font-size: 16px;
color: #FF2525;
font-weight: 600;
display: inline-block;
	margin-bottom:0;
}
.popup form div> input {
	color: #223767;
	border: 1px solid #C4D5D8;
	background: #F4F7F8;
	box-sizing: border-box;
	padding: 0 20px 0 20px;
	height: 50px;
	line-height: 50px;
	width: 100%;
	border-radius: 8px;
	margin-bottom:20px;
}
.popup form div > input[name="tel"] {
  margin-bottom: 0; /* Или margin: 0;, если нужно обнулить вообще все внешние отступы */
}
.popup form div> textarea {
	color: #223767;
	border: 1px solid #C4D5D8;
	background: #F4F7F8;
	box-sizing: border-box;
	padding: 20px;
	height: 140px;
	width: 100%;
	border-radius: 8px;
}
.popup form div> input:hover,
.popup form div> input:focus,
.popup form div> textarea:hover,
.popup form div> textarea:focus {
	border: 1px solid #356DDC;
}
.recap{
	background: #D3D3D3;
	padding: 8px;
	border-radius: 8px;
	margin:20px 0 20px 0;
}
.g-recaptcha {
  width: fit-content; /* Контейнер обжимает капчу точно по ширине */
  margin: 5px auto; /* Центрируем по горизонтали */

  /* Магия закругления */
  border-radius: 8px; 
  overflow: hidden; /* Обрезаем квадратные углы iframe, которые торчат наружу */
}
/* На всякий случай закругляем и сам iframe, чтобы браузеры рендерили ровнее */
.g-recaptcha iframe {
  border-radius: 8px;
}
.popuptext a{
	color: #356DDC;
}
.popuptext a:hover {
	color: #223767;
}
.popuptext ul li {
	  list-style-type: none;
  position: relative; 
  margin: 7px 0 7px 0;
	padding-left: 18px;
}
.popuptext ul li::before {
  content: '✓';
  color: #356DDC;
  font-size: 18px;
  position: absolute;
  left: 0;
  top: 0px; 
  line-height: 1.2; 
}
/* Стили для самого списка */
.popuptext ol {
  list-style: none; /* Отключаем стандартные скучные цифры */
  counter-reset: custom-counter; /* Запускаем свой счетчик */
  padding-left: 0; /* Убираем стандартный отступ слева */
	margin-top: 10px;
}
/* Стили для элементов списка */
.popuptext ol li {
  counter-increment: custom-counter; /* Шаг счетчика */
  position: relative;
  padding-left:35px; /* Освобождаем место под красивые цифры */
  margin-bottom: 10px;
}
/* Оформляем сами цифры */
.popuptext ol li::before {
  content: counter(custom-counter);
  position: absolute;
  left: 0;
  top: 0;
  width: 20px;
  height: 20px;
  background-color: #356DDC; /* Тот самый синий цвет */
  color: #ffffff;
  border-radius: 50%; /* Делаем цифры в круглых плашках */
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 10px;
}
/* Убираем лишние отступы у абзацев внутри li */
.popuptext ol li p {
  margin: 0;
  line-height: 1.6;
  color: #333333;
}
/* Делаем жирный текст чуть контрастнее */
.popuptext ol li strong {
  color: #111827; 
}
.popuptext blockquote{
	background-color: #f8fafc; 
	border-left: 4px solid #356DDC; 
	padding: 16px; 
	border-radius: 4px;
}
.popuptext ul li:last-child {
margin-bottom: 0;
}
.popuptext b,
.popuptext strong {
	font-weight: 700;
}
.popup button,
.btnn{
	display: block;
	box-sizing: border-box;
  width: 100%;
  height: 52px;
  line-height: 52px;
  border-radius: 90px;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  background: #356DDC;
  color: #fff;
  margin-top: 20px;
  box-shadow: 0 0 30px rgba(112, 144, 165, 0.4);
	border:0;
}
.popup button:hover,
.btnn:hover{
	background: #223767;
}


.overlay:target .popup {
	transform: scale(1);
	opacity: 1;
}
.popup .close {
	position: absolute;
	top: -8px;
	right: -8px;
	width: 30px;
	height: 30px;
	line-height: 30px;
	text-align: center;
	background: #ff0000;
	color: #fff;
	border-radius: 50%;
	text-decoration: none;
	font-size: 21px;
	transition: 0.3s;
	z-index: 10001;
	box-shadow: 0 0 12px rgba(19, 37, 49, 0.7);
}
.popup .close:hover {
	background: #212121;
}

/* Стилизация скроллбара внутри попапа */
.popup::-webkit-scrollbar {
	width: 8px;
}
.popup::-webkit-scrollbar-track {
	background: #f1f1f1;
	border-radius: 4px;
}
.popup::-webkit-scrollbar-thumb {
	background: #888;
	border-radius: 4px;
}
.popup::-webkit-scrollbar-thumb:hover {
	background: #555;
}
@media (max-width: 768px) {
	.popup {
		width: 95%;
		padding: 20px 15px 25px;
	}
	.popup h2 {
		margin: -20px -15px 20px -15px;
		padding: 20px 15px;
	}
}
@media (max-width: 480px) {
.popup h2 {
	font-size: 18px;
}
.popup .close {
	top: -0px;
	right: -0px;
}
}

@media (max-width: 400px) {
.popup h2 {
	font-size: 16px;
}
}
