/* =============================================================
   Pro Fields — shared styles
   ============================================================= */

/* --- Image Selector ------------------------------------------ */
.efacf-image-selector-wrap {
	display: grid;
	gap: 10px;
}
.efacf-image-selector-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	border: 2px solid #ddd;
	border-radius: 6px;
	padding: 8px;
	cursor: pointer;
	transition: border-color 0.15s, box-shadow 0.15s;
	position: relative;
}
.efacf-image-selector-item:hover {
	border-color: #aaa;
}
.efacf-image-selector-item.is-selected {
	border-color: #2271b1;
	box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.15);
}
.efacf-image-selector-input {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
	pointer-events: none;
}
.efacf-image-selector-img-wrap {
	width: 100%;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	border-radius: 4px;
	background: #f0f0f1;
	display: flex;
	align-items: center;
	justify-content: center;
}
.efacf-image-selector-img-wrap img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.efacf-image-selector-placeholder {
	font-size: 24px;
	color: #999;
	font-weight: 600;
}
.efacf-image-selector-label {
	margin-top: 6px;
	font-size: 12px;
	color: #50575e;
	text-align: center;
}
.efacf-image-selector-item.is-selected .efacf-image-selector-label {
	color: #2271b1;
	font-weight: 600;
}

/* --- oEmbed --------------------------------------------------- */
.efacf-oembed-wrap {}
.efacf-oembed-url-row {
	display: flex;
	gap: 8px;
	align-items: center;
	margin-bottom: 10px;
}
.efacf-oembed-url-row input[type="url"] {
	flex: 1;
}
.efacf-oembed-preview {
	border: 1px solid #ddd;
	border-radius: 4px;
	padding: 12px;
	min-height: 80px;
	background: #fafafa;
}
.efacf-oembed-preview iframe {
	max-width: 100%;
}
.efacf-oembed-loading,
.efacf-oembed-empty,
.efacf-oembed-error {
	color: #999;
	font-style: italic;
	margin: 0;
}
.efacf-oembed-error { color: #d63638; }

/* --- Photo Gallery ------------------------------------------- */
.efacf-gallery-grid {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	min-height: 40px;
	padding: 4px 0;
}
.efacf-gallery-item {
	width: 120px;
}
.efacf-gallery-thumb {
	position: relative;
	width: 120px;
	height: 90px;
	border: 1px solid #ddd;
	border-radius: 4px;
	overflow: hidden;
	background: #f0f0f1;
	cursor: grab;
}
.efacf-gallery-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.efacf-gallery-remove {
	position: absolute;
	top: 3px;
	right: 3px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: rgba(0,0,0,.65);
	color: #fff;
	border: none;
	cursor: pointer;
	font-size: 14px;
	line-height: 18px;
	text-align: center;
	padding: 0;
	display: none;
}
.efacf-gallery-thumb:hover .efacf-gallery-remove { display: block; }
.efacf-gallery-drag-handle {
	position: absolute;
	bottom: 3px;
	left: 3px;
	color: rgba(255,255,255,.8);
	font-size: 16px;
	cursor: grab;
	text-shadow: 0 1px 2px rgba(0,0,0,.5);
}
.efacf-gallery-meta {
	display: flex;
	flex-direction: column;
	gap: 3px;
	padding: 4px 0;
}
.efacf-gallery-meta input {
	width: 100%;
	font-size: 11px;
}
.efacf-gallery-actions {
	margin-top: 10px;
}

/* --- OpenStreetMap ------------------------------------------- */
.efacf-osm-wrap {}
.efacf-osm-search-row {
	display: flex;
	gap: 8px;
	margin-bottom: 10px;
	align-items: center;
}
.efacf-osm-search-row input[type="text"] {
	flex: 1;
}
.efacf-osm-map {
	border: 1px solid #ddd;
	border-radius: 4px;
	z-index: 0;
}

/* --- Image Hotspot ------------------------------------------- */
.efacf-hotspot-wrap {}
.efacf-hotspot-image-row {
	margin-bottom: 10px;
	display: flex;
	gap: 8px;
}
.efacf-hotspot-canvas-wrap {
	margin-bottom: 12px;
}
.efacf-hotspot-hint {
	margin-bottom: 6px;
}
.efacf-hotspot-canvas {
	position: relative;
	display: inline-block;
	cursor: crosshair;
	border: 1px solid #ddd;
	border-radius: 4px;
	overflow: hidden;
	max-width: 100%;
}
.efacf-hotspot-img {
	display: block;
	max-width: 100%;
	height: auto;
	user-select: none;
}
.efacf-hotspot-pin {
	position: absolute;
	transform: translate(-50%, -50%);
	z-index: 10;
	cursor: pointer;
}
.efacf-pin-dot {
	width: 14px;
	height: 14px;
	background: #2271b1;
	border: 2px solid #fff;
	border-radius: 50%;
	box-shadow: 0 1px 4px rgba(0,0,0,.4);
}
.efacf-pin-pin {
	width: 0;
	height: 0;
	border-left: 8px solid transparent;
	border-right: 8px solid transparent;
	border-top: 20px solid #d63638;
	filter: drop-shadow(0 1px 2px rgba(0,0,0,.3));
}
.efacf-pin-numbered {
	width: 22px;
	height: 22px;
	background: #2271b1;
	color: #fff;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 11px;
	font-weight: 700;
	border: 2px solid #fff;
	box-shadow: 0 1px 4px rgba(0,0,0,.4);
}
.efacf-hotspot-item {
	border: 1px solid #ddd;
	border-radius: 4px;
	margin-bottom: 8px;
	overflow: hidden;
}
.efacf-hotspot-item-header {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 12px;
	background: #f6f7f7;
	border-bottom: 1px solid #ddd;
}
.efacf-hotspot-coords { color: #999; font-size: 11px; }
.efacf-hotspot-remove-pin { margin-left: auto; color: #d63638; }
.efacf-hotspot-item-fields {
	padding: 10px 12px;
	display: flex;
	flex-direction: column;
	gap: 6px;
}
.efacf-hotspot-item-fields input,
.efacf-hotspot-item-fields textarea {
	width: 100%;
}

/* --- Stripe Payment ------------------------------------------ */
.efacf-stripe-wrap {}
.efacf-stripe-element {
	padding: 12px;
	border: 1px solid #ddd;
	border-radius: 4px;
	background: #fff;
	min-height: 60px;
	margin-bottom: 10px;
}
.efacf-stripe-errors {
	color: #d63638;
	font-size: 13px;
	margin-bottom: 8px;
	min-height: 16px;
}
.efacf-stripe-amount-hint {
	margin: 8px 0;
}
.efacf-stripe-success {
	padding: 10px 14px;
	background: #f0fdf4;
	border: 1px solid #86efac;
	border-radius: 4px;
	display: flex;
	align-items: center;
	gap: 10px;
}
.efacf-stripe-success code {
	background: #dcfce7;
	padding: 2px 6px;
	border-radius: 3px;
	font-size: 12px;
}
.efacf-stripe-config-warning {
	padding: 8px 12px;
}
.efacf-stripe-status { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }
.efacf-stripe-status-succeeded { color: #166534; }
.efacf-stripe-status-pending   { color: #713f12; }
.efacf-stripe-status-failed    { color: #991b1b; }

/* --- Hidden Field hint --------------------------------------- */
.efacf-hidden-hint {
	color: #999;
	font-size: 12px;
}
.efacf-hidden-hint code {
	font-size: 11px;
	background: #f6f7f7;
	padding: 1px 5px;
	border-radius: 3px;
}

/* --- Slug Field ---------------------------------------------- */
.efacf-slug-wrap {
	position: relative;
}
.efacf-slug-hint {
	display: block;
	margin-top: 4px;
	color: #999;
	font-family: monospace;
	font-size: 12px;
}
