/*
 * 査定承認方法は既存のカードUIを操作部として使う。
 * CF7が自動生成するラジオ一覧は、値を保持したまま画面外へ隠す。
 */
.wpcf7 .form_radio_card > .wpcf7-form-control-wrap {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	clip-path: inset(50%) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

/* このプラグインで開いたDatepicker。外部テーマCSSは不要。 */
#ui-datepicker-div.emk-datepicker {
	display: none;
	width: 300px;
	max-width: calc(100vw - 24px);
	padding: 12px;
	background: #fff;
	color: #333;
	border: 1px solid #ccc;
	border-radius: 8px;
	box-shadow: 0 4px 20px #0002;
	z-index: 10000 !important;
	font-size: 15px;
}
.emk-datepicker .ui-datepicker-header { position: relative; padding: 8px 36px; background: #f3f3f3; }
.emk-datepicker .ui-datepicker-title { text-align: center; }
.emk-datepicker .ui-datepicker-title select { width: auto; padding: 3px; font-size: 14px; }
.emk-datepicker .ui-datepicker-prev,
.emk-datepicker .ui-datepicker-next { position: absolute; top: 10px; cursor: pointer; font-size: 12px; }
.emk-datepicker .ui-datepicker-prev { left: 3px; }
.emk-datepicker .ui-datepicker-next { right: 3px; }
.emk-datepicker table { width: 100%; border-collapse: collapse; margin: 8px 0; table-layout: fixed; }
.emk-datepicker th { padding: 4px; text-align: center; }
.emk-datepicker td { padding: 1px; text-align: center; }
.emk-datepicker td a,
.emk-datepicker td span { display: block; padding: 7px 2px; text-decoration: none; color: inherit; }
.emk-datepicker .ui-state-disabled { opacity: .3; }
.emk-datepicker td a:hover,
.emk-datepicker td a:focus { background: #e4f3e9; }
.emk-datepicker td .ui-state-active { background: #049946; color: #fff; }
.emk-datepicker td .ui-state-highlight { outline: 1px solid #049946; }
.emk-datepicker .ui-datepicker-buttonpane { display: flex; justify-content: space-between; }
.emk-datepicker button { padding: 5px 10px; border: 1px solid #ccc; background: #fff; color: #333; cursor: pointer; }

.wpcf7 .approval_card {
	cursor: pointer;
}

.wpcf7 .approval_card:focus-visible {
	outline: 2px solid #9b4faa;
	outline-offset: 2px;
}

/* 単位付き入力では、エラー文の長さで「箱・点・cm」等を押し出さない。 */
.wpcf7 .input_wrap > .wpcf7-form-control-wrap {
	width: 100%;
	max-width: 200px;
}

.wpcf7 .need_boxes .input_wrap > .wpcf7-form-control-wrap {
	max-width: 100px;
}

.wpcf7 .input_wrap .wpcf7-not-valid-tip {
	display: block;
	width: max-content;
	max-width: none;
	font-size: inherit;
	line-height: 1.5;
	white-space: nowrap;
}

.wpcf7 .emk-confirmation[hidden],
.wpcf7 .form_wrap[hidden] {
	display: none !important;
}

.wpcf7 .emk-confirmation__lead { margin-bottom: 24px; }

.wpcf7 .emk-confirmation__list {
	display: grid;
	grid-template-columns: minmax(180px, 30%) 1fr;
	margin: 0 0 32px;
	border-top: 1px solid #ddd;
}

.wpcf7 .emk-confirmation__list dt,
.wpcf7 .emk-confirmation__list dd {
	box-sizing: border-box;
	margin: 0;
	padding: 14px 16px;
	border-bottom: 1px solid #ddd;
}

.wpcf7 .emk-confirmation__list dt {
	background: #f7f1fa;
	font-weight: 700;
}

.wpcf7 .emk-confirmation__list dd {
	white-space: pre-wrap;
	overflow-wrap: anywhere;
}

.wpcf7 .emk-confirmation__buttons {
	display: flex;
	justify-content: center;
	gap: 16px;
	flex-wrap: wrap;
}

.wpcf7 .emk-confirmation__status {
	margin: 0px 0 20px;
	text-align: center;
	font-weight: 700;
}

.wpcf7 .emk-confirmation__status:empty { display: none; }
.wpcf7 .emk-confirmation__status.is-sending { color: #555; }
.wpcf7 .emk-confirmation__status.is-success { color: #047a39; }
.wpcf7 .emk-confirmation__status.is-error { color: #c00; }

.wpcf7 .emk-confirmation__send:disabled,
.wpcf7 .emk-confirmation__back:disabled {
	cursor: wait;
	opacity: .65;
}

.wpcf7 .emk-confirmation__back,
.wpcf7 .emk-confirmation__send {
	min-width: 220px;
	padding: 14px 24px;
	border: 1px solid transparent;
	cursor: pointer;
	transition: opacity .3s, background-color .3s;
}

.wpcf7 .emk-confirmation__send {
	border-color: #049946;
	background-color: #049946;
	color: #fff;
}

.wpcf7 .emk-confirmation__back {
	border-color: #777;
	background-color: #fff;
	color: #333;
}

.wpcf7 .emk-confirmation__back:hover,
.wpcf7 .emk-confirmation__send:hover {
	opacity: .7;
}

.wpcf7 .emk-confirmation__back:focus-visible,
.wpcf7 .emk-confirmation__send:focus-visible {
	outline: 2px solid #4d2667;
	outline-offset: 2px;
}

.turnstile_wrap {
	display: flex;
	justify-content: center;
	margin: 30px 0;
}

@media (max-width: 640px) {
	.wpcf7 .emk-confirmation__list { display: block; }
	.wpcf7 .emk-confirmation__list dt,
	.wpcf7 .emk-confirmation__list dd { display: block; }
	.wpcf7 .emk-confirmation__list dd { padding-top: 10px; }
	.wpcf7 .emk-confirmation__buttons { flex-direction: column-reverse; }
	.wpcf7 .emk-confirmation__back,
	.wpcf7 .emk-confirmation__send { width: 100%; }
}
