/**
 * Real Estate Theme - Elementor Widgets Styles
 */

/* Property Grid Widget */
.elementor-widget-property_grid .property-grid {
	display: grid;
	gap: 30px;
}

.elementor-widget-property_grid .property-grid[data-columns="2"] {
	grid-template-columns: repeat(2, 1fr);
}

.elementor-widget-property_grid .property-grid[data-columns="3"] {
	grid-template-columns: repeat(3, 1fr);
}

.elementor-widget-property_grid .property-grid[data-columns="4"] {
	grid-template-columns: repeat(4, 1fr);
}

/* Property List Widget */
.elementor-widget-property_list .property-list {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.elementor-widget-property_list .property-list-item {
	display: flex;
	gap: 20px;
	padding: 15px;
	background-color: #f9fafb;
	border-radius: 8px;
	border: 1px solid #e5e7eb;
	transition: all 0.3s ease;
}

.elementor-widget-property_list .property-list-item:hover {
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
	transform: translateX(5px);
}

.elementor-widget-property_list .property-list-image {
	flex: 0 0 150px;
	border-radius: 4px;
	overflow: hidden;
}

.elementor-widget-property_list .property-list-image img {
	width: 100%;
	height: 150px;
	object-fit: cover;
}

.elementor-widget-property_list .property-list-content {
	flex: 1;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
}

.elementor-widget-property_list .property-list-content h3 {
	margin: 0 0 10px 0;
	font-size: 1.2rem;
}

.elementor-widget-property_list .property-list-content a {
	color: var(--primary-color, #1e40af);
	text-decoration: none;
}

.elementor-widget-property_list .property-list-content a:hover {
	text-decoration: underline;
}

.elementor-widget-property_list .property-list-content p {
	margin: 0 0 10px 0;
	color: #6b7280;
	font-size: 0.95rem;
}

.elementor-widget-property_list .property-list-meta {
	display: flex;
	gap: 20px;
	font-size: 0.9rem;
	color: #6b7280;
}

/* Featured Properties Widget */
.elementor-widget-featured_properties .featured-properties-section {
	margin-bottom: 40px;
}

.elementor-widget-featured_properties .featured-properties-title {
	font-size: 2rem;
	margin-bottom: 30px;
	color: #1f2937;
	text-align: center;
}

/* Property Search & Filter Widget */
.elementor-widget-property_search .property-search-form {
	background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
	padding: 30px;
	border-radius: 8px;
	border: 1px solid #e5e7eb;
}

.elementor-widget-property_search .search-field {
	margin-bottom: 20px;
}

.elementor-widget-property_search .filter-field {
	width: 100%;
}

.elementor-widget-property_search .search-input,
.elementor-widget-property_search .filter-input,
.elementor-widget-property_search .filter-select {
	width: 100%;
	padding: 12px;
	border: 1px solid #d1d5db;
	border-radius: 4px;
	font-size: 1rem;
	background-color: white;
	transition: all 0.3s ease;
	font-family: inherit;
}

.elementor-widget-property_search .search-input:focus,
.elementor-widget-property_search .filter-input:focus,
.elementor-widget-property_search .filter-select:focus {
	outline: none;
	border-color: var(--primary-color, #1e40af);
	box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.elementor-widget-property_search .search-field-group {
	margin-bottom: 20px;
}

.elementor-widget-property_search .filter-fields-row {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 15px;
	margin-bottom: 20px;
}

.elementor-widget-property_search .property-search-btn {
	width: 100%;
	background-color: var(--primary-color, #1e40af);
	color: white;
	padding: 12px 30px;
	border: none;
	border-radius: 4px;
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s ease;
}

.elementor-widget-property_search .property-search-btn:hover {
	background-color: var(--secondary-color, #0f766e);
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(15, 118, 110, 0.3);
}

/* Property Map Widget */
.elementor-widget-property_map .property-map {
	width: 100%;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.elementor-widget-property_map .leaflet-container {
	background-color: #e5e3df;
	font-family: inherit;
}

.elementor-widget-property_map .leaflet-control-zoom {
	border-radius: 4px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.elementor-widget-property_map .leaflet-control-attribution {
	background-color: rgba(255, 255, 255, 0.9);
	font-size: 11px;
}

/* Leaflet popup customization */
.leaflet-popup-content-wrapper {
	border-radius: 4px;
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

.leaflet-popup-tip {
	background-color: white;
}

/* Responsive adjustments */
@media (max-width: 768px) {
	.elementor-widget-property_grid .property-grid {
		grid-template-columns: 1fr !important;
	}

	.elementor-widget-property_list .property-list-item {
		flex-direction: column;
	}

	.elementor-widget-property_list .property-list-image {
		flex: 0 0 auto;
		width: 100%;
	}

	.elementor-widget-property_search .filter-fields-row {
		grid-template-columns: 1fr;
	}

	.elementor-widget-property_search .property-search-form {
		padding: 20px;
	}
}

/* Animations */
@keyframes fadeIn {
	from {
		opacity: 0;
		transform: translateY(10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.elementor-widget-property_grid .property-card,
.elementor-widget-property_list .property-list-item,
.elementor-widget-featured_properties .property-card {
	animation: fadeIn 0.5s ease-out;
}

/* Loading state */
.elementor-widget-property_grid.loading,
.elementor-widget-property_list.loading,
.elementor-widget-featured_properties.loading {
	opacity: 0.6;
	pointer-events: none;
}

.elementor-widget-property_grid .spinner,
.elementor-widget-property_list .spinner,
.elementor-widget-featured_properties .spinner {
	display: inline-block;
	width: 20px;
	height: 20px;
	border: 3px solid #e5e7eb;
	border-top-color: var(--primary-color, #1e40af);
	border-radius: 50%;
	animation: spin 0.8s linear infinite;
}

@keyframes spin {
	to {
		transform: rotate(360deg);
	}
}

/* Print styles */
@media print {
	.elementor-widget-property_search {
		display: none;
	}

	.property-card,
	.property-list-item {
		page-break-inside: avoid;
	}
}
