/**
 * CH3 phone (intl-tel-input) — scoped to .ch3-hs-form (HubSpot WPForms only).
 */

.ch3-hs-form .wpforms-field.ch3-phone,
.ch3-hs-form .wpforms-field.wpforms-field-6 {
	overflow: visible !important;
	width: 100% !important;
}

/* Hide Phone label (keep placeholder / dial UI only). */
.ch3-hs-form .wpforms-field.ch3-phone .wpforms-field-label,
.ch3-hs-form .wpforms-field.wpforms-field-6 .wpforms-field-label {
	display: none !important;
}

.ch3-hs-form .wpforms-field.ch3-phone .iti,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti {
	width: 100% !important;
	max-width: 100% !important;
	display: block !important;
	position: relative !important;
	font-family: inherit;
	color: inherit;
}

/* Keep flag + dial code on the left of a full-width input. */
.ch3-hs-form .wpforms-field.ch3-phone .iti__country-container,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__country-container,
.ch3-hs-form .wpforms-field.ch3-phone .iti__flag-container,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__flag-container {
	position: absolute !important;
	top: 0 !important;
	bottom: 0 !important;
	left: 0 !important;
	z-index: 3 !important;
}

.ch3-hs-form .wpforms-field.ch3-phone .iti__selected-country,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__selected-country,
.ch3-hs-form .wpforms-field.ch3-phone .iti__selected-flag,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__selected-flag {
	display: flex !important;
	align-items: center !important;
	height: 100% !important;
	padding: 0 6px 0 10px !important;
	background: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
	color: inherit !important;
	text-decoration: none !important;
	cursor: pointer !important;
	line-height: 1 !important;
	width: auto !important;
	min-width: 0 !important;
}

.ch3-hs-form .wpforms-field.ch3-phone .iti__selected-country:hover,
.ch3-hs-form .wpforms-field.ch3-phone .iti__selected-country:focus,
.ch3-hs-form .wpforms-field.ch3-phone .iti__selected-flag:hover,
.ch3-hs-form .wpforms-field.ch3-phone .iti__selected-flag:focus,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__selected-country:hover,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__selected-flag:hover {
	background: rgba(0, 0, 0, 0.04) !important;
	color: inherit !important;
	text-decoration: none !important;
}

/*
 * Critical: library puts "United States +1" in .iti__a11y-text for screen readers.
 * Theme CSS was making that visible → looked like duplicate "+1".
 */
.iti__a11y-text,
.ch3-hs-form .wpforms-field.ch3-phone .iti__a11y-text,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__a11y-text {
	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;
	font-size: 0 !important;
	line-height: 0 !important;
	color: transparent !important;
}

.ch3-hs-form .wpforms-field.ch3-phone .iti__selected-dial-code,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__selected-dial-code {
	margin-left: 6px !important;
	font-size: 14px !important;
	color: #000 !important;
	opacity: 0.9;
	white-space: nowrap !important;
}

.ch3-hs-form .wpforms-field.ch3-phone .iti__arrow,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti__arrow {
	/* margin-left: 6px !important; */
	border-top-color: currentColor !important;
	opacity: 0.7;
	flex-shrink: 0;
}

.ch3-hs-form .wpforms-field.ch3-phone .iti input[type='tel'],
.ch3-hs-form .wpforms-field.ch3-phone .iti input.wpforms-field-medium,
.ch3-hs-form .wpforms-field.ch3-phone .iti input.wpforms-field-large,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti input[type='tel'],
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti input.wpforms-field-medium,
.ch3-hs-form .wpforms-field.wpforms-field-6 .iti input.wpforms-field-large {
	width: 100% !important;
	max-width: 100% !important;
	box-sizing: border-box !important;
}

/* Dropdown shell: no scrollbar here (avoids double scroll). */
.iti__dropdown-content {
	z-index: 100000 !important;
	background: #fff !important;
	color: #222 !important;
	border: 1px solid #ccc !important;
	border-radius: 4px !important;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18) !important;
	overflow: hidden !important;
	max-height: none !important;
	margin: 0 !important;
	padding: 0 !important;
	width: auto !important;
	min-width: 280px !important;
}

/* Only the country list scrolls. */
.iti__country-list {
	z-index: 1 !important;
	background: #fff !important;
	color: #222 !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	max-height: 200px !important;
	overflow-x: hidden !important;
	overflow-y: auto !important;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none !important;
	width: 100% !important;
	min-width: 0 !important;
}

.iti__country-list .iti__country {
	display: flex !important;
	align-items: center !important;
	padding: 8px 10px !important;
	color: #222 !important;
	background: #fff !important;
	line-height: 1.3 !important;
	white-space: nowrap !important;
}

.iti__country-list .iti__country:hover,
.iti__country-list .iti__country.iti__highlight {
	background: #f3f3f3 !important;
	color: #222 !important;
}

.iti__country-list .iti__country-name,
.iti__country-list .iti__dial-code {
	color: inherit !important;
	font-size: 14px !important;
}

.iti__country-list .iti__dial-code {
	opacity: 0.7;
	margin-left: 6px !important;
}

.iti__search-input {
	width: 100% !important;
	box-sizing: border-box !important;
	padding: 8px 10px !important;
	border: 0 !important;
	border-bottom: 1px solid #ddd !important;
	border-radius: 0 !important;
	margin: 0 !important;
	background: #fff !important;
	color: #222 !important;
}

/* HD flags are applied via JS from local vendor/flags/w80/. */
.iti__flag {
	display: inline-block !important;
	width: 24px !important;
	height: 18px !important;
	margin: 0 !important;
	flex-shrink: 0 !important;
	visibility: visible !important;
	opacity: 1 !important;
	border-radius: 2px !important;
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15) !important;
	background-color: #f0f0f0 !important;
	background-repeat: no-repeat !important;
	background-position: center center !important;
	background-size: cover !important;
	/* Override sprite sheet sizing from the library. */
	--iti-flag-width: 24px;
	--iti-flag-height: 18px;
	--iti-flag-offset: 0px;
}

.iti__flag.iti__globe,
.iti__globe {
	background-image: var(--iti-path-globe-1x) !important;
	background-size: contain !important;
	background-position: center !important;
	box-shadow: none !important;
	height: 18px !important;
	width: 18px !important;
	border-radius: 0 !important;
}

@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
	.iti__flag.iti__globe,
	.iti__globe {
		background-image: var(--iti-path-globe-2x) !important;
	}
}

.iti__country-list .iti__flag {
	width: 22px !important;
	height: 16px !important;
	margin-right: 8px !important;
}

.ch3-hs-form .wpforms-field.ch3-phone .ch3-phone-error,
.ch3-hs-form .wpforms-field.wpforms-field-6 .ch3-phone-error {
	display: block;
	margin-top: 6px;
	color: #d63638;
	font-style: normal;
	font-size: 13px;
}
