/* =========================================================
   Юстина — короткая форма в выезжающей панели
   Файл: ustina-popup-form.css
   ========================================================= */

/* Панель */
.ustina-appointment-panel {
	width:100%;
	max-width:430px;
	background:#fff;
}

.ustina-appointment-panel .ustina-panel__wrap {
	height:100dvh;
	box-sizing:border-box;
	padding:28px 30px 24px;
	overflow-y:auto;
	scrollbar-gutter:stable;
}

.ustina-appointment-panel .ustina-panel__head {
	margin:0 0 18px;
}

.ustina-appointment-panel .panel__title {
	display:block;
	margin:0 0 10px;
	padding:0;
	color:#203E63;
	font-size:1.55rem;
	font-weight:700;
	line-height:1.15;
	letter-spacing:-.02em;
}

.ustina-appointment-panel .panel__descr {
	margin:0;
	color:#68778A;
	font-size:.9rem;
	line-height:1.5;
}

.ustina-appointment-panel .ustina-panel__form {
	margin:0;
	padding:0;
	background:transparent;
}

/* Карточка короткой формы */
.ustina-appointment-panel .ustina-short-form {
	margin:0;
	padding:18px;
	background:#fff;
	border:1px solid #D9DFE5;
	border-radius:12px;
	box-shadow:0 8px 24px rgba(32,62,99,.055);
}

.ustina-appointment-panel .ustina-short-form__field {
	margin:0 0 14px;
}

.ustina-appointment-panel .ustina-short-form__field label {
	display:block;
	margin:0;
	color:#203E63;
	font-size:12px;
	font-weight:600;
	line-height:1.35;
}

.ustina-appointment-panel .ustina-short-form__field p,
.ustina-appointment-panel .ustina-short-form__consent p,
.ustina-appointment-panel .ustina-short-form__submit p {
	margin:0;
}

/* Поля */
.ustina-appointment-panel .ustina-short-form input[type="text"],
.ustina-appointment-panel .ustina-short-form input[type="tel"] {
	display:block;
	width:100%;
	min-height:44px;
	box-sizing:border-box;
	margin:6px 0 0;
	padding:10px 12px;
	background:#fff;
	border:1px solid #BDC6D0;
	border-radius:6px;
	box-shadow:none;
	color:#31465E;
	font-family:inherit;
	font-size:14px;
	line-height:1.35;
	transition:border-color .2s ease,box-shadow .2s ease;
}

.ustina-appointment-panel .ustina-short-form input[type="text"]:focus,
.ustina-appointment-panel .ustina-short-form input[type="tel"]:focus {
	outline:0;
	border-color:#203E63;
	box-shadow:0 0 0 3px rgba(32,62,99,.08);
}

.ustina-appointment-panel .ustina-short-form input::placeholder {
	color:#8A96A5;
	opacity:1;
}

/* Согласие */
.ustina-appointment-panel .ustina-short-form__consent {
	margin:2px 0 16px;
	color:#68778A;
	font-size:11.5px;
	font-weight:400;
	line-height:1.45;
}

.ustina-appointment-panel .ustina-short-form__consent .wpcf7-form-control-wrap,
.ustina-appointment-panel .ustina-short-form__consent .wpcf7-acceptance,
.ustina-appointment-panel .ustina-short-form__consent .wpcf7-list-item {
	display:block;
	margin:0;
	padding:0;
}

.ustina-appointment-panel .ustina-short-form__consent .wpcf7-list-item > label {
	display:grid;
	grid-template-columns:16px minmax(0,1fr);
	gap:9px;
	align-items:start;
	margin:0;
	color:#68778A;
	font-size:11.5px;
	font-weight:400;
	line-height:1.45;
	cursor:pointer;
}

.ustina-appointment-panel .ustina-short-form__consent input[type="checkbox"] {
	width:16px;
	height:16px;
	min-width:16px;
	min-height:16px;
	margin:2px 0 0;
	padding:0;
	border:1px solid #9EABB9;
	border-radius:3px;
	accent-color:#8A2432;
	box-shadow:none;
}

.ustina-appointment-panel .ustina-short-form__consent .wpcf7-list-item-label {
	display:block;
	min-width:0;
}

.ustina-appointment-panel .ustina-short-form__consent a {
	color:#203E63;
	font-weight:500;
	text-decoration:underline;
	text-decoration-thickness:1px;
	text-underline-offset:2px;
}

.ustina-appointment-panel .ustina-short-form__consent a:hover {
	color:#8A2432;
}

/* Кнопка */
.ustina-appointment-panel .ustina-short-form__submit {
	margin:0;
}

.ustina-appointment-panel .ustina-short-form__submit input[type="submit"] {
	display:block;
	width:100%;
	min-height:46px;
	margin:0;
	padding:0 16px;
	background:#8A2432;
	border:1px solid #8A2432;
	border-radius:6px;
	box-shadow:none;
	color:#fff;
	font-family:inherit;
	font-size:14px;
	font-weight:600;
	line-height:1;
	cursor:pointer;
	transition:background .2s ease,border-color .2s ease,transform .2s ease;
}

.ustina-appointment-panel .ustina-short-form__submit input[type="submit"]:hover:not(:disabled) {
	background:#711B29;
	border-color:#711B29;
	transform:translateY(-1px);
}

.ustina-appointment-panel .ustina-short-form__submit input[type="submit"]:disabled {
	background:#CFA5AC;
	border-color:#CFA5AC;
	color:#fff;
	opacity:1;
	cursor:not-allowed;
}

/* Подпись под кнопкой */
.ustina-appointment-panel .ustina-short-form__note {
	position:relative;
	margin:12px 0 0;
	padding:11px 0 0 18px;
	border-top:1px solid #E2E6EB;
	color:#68778A;
	font-size:11.5px;
	line-height:1.4;
	text-align:left;
}

.ustina-appointment-panel .ustina-short-form__note::before {
	content:"";
	position:absolute;
	top:17px;
	left:0;
	width:9px;
	height:2px;
	background:#8A2432;
}

/* CF7: ошибки и успешная отправка */
.ustina-appointment-panel .wpcf7-not-valid-tip {
	display:block;
	margin-top:5px;
	color:#8A2432;
	font-size:11px;
	line-height:1.35;
}

.ustina-appointment-panel .wpcf7 form .wpcf7-response-output {
	margin:14px 0 0;
	padding:11px 12px;
	background:#fff;
	border:1px solid #D9DFE5 !important;
	border-left:3px solid #203E63 !important;
	border-radius:6px;
	color:#31465E;
	font-size:12px;
	line-height:1.45;
}

.ustina-appointment-panel .wpcf7 form.sent .wpcf7-response-output {
	border-left-color:#8A2432 !important;
}

.ustina-appointment-panel .wpcf7-spinner {
	margin:8px auto 0;
}

/* Планшет / мобильный */
@media (max-width:600px) {
	.ustina-appointment-panel {
		max-width:none;
		width:100%;
	}

	.ustina-appointment-panel .ustina-panel__wrap {
		height:100dvh;
		padding:22px 18px 20px;
	}

	.ustina-appointment-panel .ustina-panel__head {
		margin-bottom:15px;
		padding-right:42px;
	}

	.ustina-appointment-panel .panel__title {
		font-size:1.35rem;
		line-height:1.15;
	}

	.ustina-appointment-panel .panel__descr {
		font-size:.84rem;
		line-height:1.45;
	}

	.ustina-appointment-panel .ustina-short-form {
		padding:16px;
		border-radius:10px;
		box-shadow:none;
	}

	.ustina-appointment-panel .ustina-short-form__field {
		margin-bottom:12px;
	}

	.ustina-appointment-panel .ustina-short-form input[type="text"],
	.ustina-appointment-panel .ustina-short-form input[type="tel"] {
		min-height:46px;
		font-size:16px;
	}

	.ustina-appointment-panel .ustina-short-form__consent,
	.ustina-appointment-panel .ustina-short-form__consent .wpcf7-list-item > label {
		font-size:11.5px;
		line-height:1.4;
	}

	.ustina-appointment-panel .ustina-short-form__submit input[type="submit"] {
		min-height:48px;
		font-size:14px;
	}

	.ustina-appointment-panel .ustina-short-form__note {
		font-size:11.5px;
	}
}

/* Невысокий экран: дополнительно уплотняем форму */
@media (max-height:760px) and (min-width:601px) {
	.ustina-appointment-panel .ustina-panel__wrap {
		padding-top:20px;
		padding-bottom:18px;
	}

	.ustina-appointment-panel .ustina-panel__head {
		margin-bottom:13px;
	}

	.ustina-appointment-panel .panel__title {
		margin-bottom:7px;
		font-size:1.4rem;
	}

	.ustina-appointment-panel .panel__descr {
		font-size:.82rem;
	}

	.ustina-appointment-panel .ustina-short-form {
		padding:15px;
	}

	.ustina-appointment-panel .ustina-short-form__field {
		margin-bottom:11px;
	}

	.ustina-appointment-panel .ustina-short-form__consent {
		margin-bottom:12px;
	}

	.ustina-appointment-panel .ustina-short-form__note {
		margin-top:9px;
		padding-top:8px;
	}
}


/* Mobile popup form UX fix */
@media (max-width: 767px){

    .ustina-appointment-panel .ustina-panel__wrap{
        padding:16px 16px 20px;
    }

    .ustina-appointment-panel .ustina-panel__head{
        margin-bottom:14px;
    }

    .ustina-appointment-panel .panel__title{
        font-size:1.35rem;
        line-height:1.15;
        margin-bottom:8px;
    }

    .ustina-appointment-panel .panel__descr{
        font-size:.86rem;
        line-height:1.4;
    }

    .ustina-appointment-panel .ustina-panel__form .ustina-form,
    .ustina-appointment-panel .ustina-short-form{
        padding:16px;
        border-radius:10px;
    }

    .ustina-appointment-panel .ustina-form__field,
    .ustina-appointment-panel .ustina-short-form__field{
        margin-bottom:12px;
    }

    .ustina-appointment-panel .ustina-form label,
    .ustina-appointment-panel .ustina-short-form__field label{
        margin-bottom:0;
        font-size:12px;
    }

    .ustina-appointment-panel .ustina-form input,
    .ustina-appointment-panel .ustina-form select,
    .ustina-appointment-panel .ustina-form textarea,
    .ustina-appointment-panel .ustina-short-form input{
        margin-top:5px;
        padding:10px 12px;
        min-height:42px;
        font-size:16px;
    }

    .ustina-appointment-panel .ustina-form textarea{
        height:90px;
        min-height:90px;
    }

    .ustina-appointment-panel .ustina-form__consent,
    .ustina-appointment-panel .ustina-short-form__consent{
        margin:12px 0;
        font-size:11px;
        line-height:1.35;
    }

    .ustina-appointment-panel .wpcf7-submit{
        margin-top:10px;
        min-height:46px;
        padding:12px;
    }
}
