/**
 * GoHighLevel Forms - Frontend Styles
 * 
 * Styles for displaying GHL forms via shortcode on the frontend
 */

/* Form Wrapper */
.ghl-form-wrapper {
	margin: 20px 0;
	clear: both;
	position: relative;
	min-height: 100px;
	width: 100%;
}

.ghl-form-wrapper iframe {
	display: block;
	width: 100%;
	border: none;
	overflow: auto;
	-webkit-overflow-scrolling: touch;
}

/* Loading State */
.ghl-form-wrapper[data-loading="true"] .ghl-form-loading {
	display: flex;
}

.ghl-form-wrapper[data-loading="false"] .ghl-form-loading {
	display: none;
}

.ghl-form-loading {
	display: none;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 60px 20px;
	text-align: center;
}

.ghl-form-loading p {
	margin: 15px 0 0 0;
	color: #666;
	font-size: 14px;
}

/* Spinner Animation */
.ghl-form-spinner {
	width: 40px;
	height: 40px;
	border: 4px solid #f3f3f3;
	border-top: 4px solid #3498db;
	border-radius: 50%;
	animation: ghl-spin 1s linear infinite;
}

@keyframes ghl-spin {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}

/* Error Message (admin only) */
.ghl-form-error {
	padding: 20px;
	margin: 20px 0;
	background: #fee;
	border: 1px solid #c33;
	border-radius: 4px;
	color: #c33;
}

.ghl-form-error strong {
	display: block;
	margin-bottom: 5px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
	.ghl-form-wrapper {
		margin: 15px 0;
	}
	
	.ghl-form-loading {
		padding: 40px 20px;
	}
	
	.ghl-form-spinner {
		width: 35px;
		height: 35px;
	}
}

@media (max-width: 480px) {
	.ghl-form-wrapper {
		margin: 10px 0;
	}
	
	.ghl-form-loading {
		padding: 30px 15px;
	}
	
	.ghl-form-spinner {
		width: 30px;
		height: 30px;
		border-width: 3px;
	}
	
	.ghl-form-loading p {
		font-size: 13px;
	}
}
