/**
 * Store Locator - Frontend Styles
 * RTL-compatible, responsive design
 */

/* Main Container */
.store-locator-container {
	display: grid;
    grid-template-columns: 30% 70%;
    gap: 0;
    min-height: 600px;
    background: #fff;
    overflow: hidden;
    direction: rtl;
}

/* Map Section */
.store-locator-map-section {
	position: relative;
	height: 600px;
}

#store-locator-map {
	width: 100%;
	height: 100%;
}

/* Stores List Section */
.store-locator-list-section {
    background: #ffffff;
    overflow-y: auto;
    max-height: 600px;
    display: flex;
    flex-direction: column;
    border: 1px solid #e5e7eb;
	border-bottom-right-radius: var(--pls-border-radius);
}

/* Search Filter */
.store-search-wrapper {
    padding: 20px 20px 0 20px;
    display: flex;
    gap: 10px;
    align-items: center;
    background: #ffffff;
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 15px;
}

.store-search-input {
	flex: 1;
	padding: 10px 15px;
	border: 1px solid #d1d5db;
	font-size: 14px;
	direction: rtl;
	background: white;
}

.store-search-input:focus {
	outline: none;
	border-color: #2b2a29;
}

.store-search-btn {
	padding: 10px 20px;
	background: #2b2a29;
	color: white;
	border: none;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 6px;
	white-space: nowrap;
}

.store-reset-btn {
	padding: 10px 16px;
	background: #6b7280;
	color: white;
	border: none;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 6px;
	white-space: nowrap;
}

.store-cards-wrapper {
	display: flex;
    flex-direction: column;
    gap: 15px;
    flex: 1;
    border-bottom: 1px solid #e5e7eb;
}

.store-no-results {
	padding: 40px 20px;
	text-align: center;
	color: #6b7280;
	font-size: 15px;
}

/* Store Card */
.store-card {
    padding: 20px;
    position: relative;
    cursor: pointer;
    border-bottom: 1px solid #e5e7eb;
}

/* Store Badge */
.store-card-badge {
	position: absolute;
	top: 15px;
	left: 15px;
	padding: 6px 14px;
	color: white;
	font-size: 12px;
	font-weight: 600;
	white-space: nowrap;
	border-radius: var(--pls-border-radius);
}

/* Store Title */
.store-card-title {
	margin: 0 0 15px 0;
	font-size: 20px;
	font-weight: 700;
	color: #1a1a1a;
	line-height: 1.3;
	padding-left: 100px; /* Space for badge */
}

/* Store Info */
.store-card-info {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin-bottom: 15px;
}

.store-info-item {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-size: 14px;
	color: #4b5563;
	line-height: 1.5;
}

.store-icon {
	flex-shrink: 0;
	color: #6b7280;
	margin-top: 2px;
}

.store-info-item a {
	color: #3b82f6;
	text-decoration: none;
}

.store-info-item a:hover {
	text-decoration: underline;
}

/* Navigate Button */
.store-navigate-btn {
	display: block;
	width: 100%;
	padding: 8px 15px;
	background: #2b2a29;
	color: white;
	text-align: center;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
	transition: background 0.2s ease;
	border-radius: var(--pls-border-radius);
}


/* Modal Popup */
.store-modal {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.store-modal-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.6);
	backdrop-filter: blur(2px);
}

.store-modal-content {
	position: relative;
	background: white;
	max-width: 500px;
	width: 100%;
	max-height: 90vh;
	overflow-y: auto;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
	animation: modalFadeIn 0.2s ease;
	direction: rtl;
}

@keyframes modalFadeIn {
	from {
		opacity: 0;
		transform: scale(0.95);
	}
	to {
		opacity: 1;
		transform: scale(1);
	}
}

.store-modal-close {
	position: absolute;
	top: 15px;
	left: 15px;
	background: #f3f4f6;
	border: none;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #6b7280;
	transition: all 0.2s ease;
	z-index: 10;
	padding: 15px;
}

.store-modal-close:hover {
	background: #e5e7eb;
	color: #2b2a29;
}

.store-modal-body {
	padding: 30px;
}

/* Popup Content */
.store-popup-content {
	text-align: center;
}

.store-popup-badge {
	display: inline-block;
	padding: 6px 16px;
	color: white;
	font-size: 13px;
	font-weight: 600;
	margin-bottom: 15px;
	border-radius: var(--pls-border-radius);
}

.store-popup-title {
	margin: 0 0 8px 0;
	font-size: 24px;
	font-weight: 700;
	color: #1a1a1a;
	line-height: 1.3;
}

.store-popup-city {
	font-size: 16px;
	color: #6b7280;
	margin-bottom: 25px;
	font-weight: 500;
}

.store-popup-details {
	display: flex;
	flex-direction: column;
	gap: 15px;
	margin-bottom: 25px;
	text-align: right;
}

.store-popup-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px;
	background: #f9fafb;
	font-size: 14px;
	color: #374151;
	border-radius: var(--pls-border-radius);
}

.store-popup-icon {
	flex-shrink: 0;
	color: #6b7280;
}

.store-popup-item a {
	color: #3b82f6;
	text-decoration: none;
	font-weight: 500;
}

.store-popup-item a:hover {
	text-decoration: underline;
}

.store-popup-navigate {
	display: block;
	width: 100%;
	padding: 10px 30px;
	background: #2b2a29;
	color: white;
	text-align: center;
	text-decoration: none;
	font-weight: 600;
	font-size: 15px;
	transition: background 0.2s ease;
	border-radius: var(--pls-border-radius);
}

.store-popup-navigate:hover {
	background: #111827;
}

.store-popup-navigate a:hover , store-navigate-btn a:hover{
	color: white !important
}



/* Google Maps Container */
#store-locator-map {
	width: 100%;
	height: 100%;
	border-top-left-radius: var(--pls-border-radius);
    border-bottom-left-radius: var(--pls-border-radius);
}

#store-locator-map img {
	max-width: none !important;
}

/* Empty State */
.store-locator-empty {
	padding: 60px 20px;
	text-align: center;
	color: #6b7280;
	font-size: 16px;
	background: #f9fafb;
	border: 2px dashed #d1d5db;
}

/* Responsive Design */

/* Tablet */
@media (max-width: 1024px) {
	.store-locator-container {
		grid-template-columns: 50% 50%;
	}
	
	.store-card-title {
		font-size: 18px;
	}
}

/* Mobile */
@media (max-width: 768px) {
	.store-locator-container {
		grid-template-columns: 1fr;
		min-height: auto;
	}
	
	.store-locator-map-section {
		height: 400px;
		order: 1;
	}

	#store-locator-map{
		border-radius: var(--pls-border-radius);
	}
	
	.store-locator-list-section {
		order: 2;
		max-height: none;
	}
	
	.store-search-wrapper {
		flex-wrap: wrap;
		padding: 15px 30px;
	}
	
	.store-popup-content{
		text-align: right;
	}
	
	.store-cards-wrapper {
		padding: 15px;
	}
	
	.store-card {
		padding: 15px;
	}
	
	.store-card-title {
		font-size: 18px;
		padding-left: 90px;
	}
	
	.store-card-badge {
		font-size: 11px;
		padding: 5px 12px;
	}
	
	.store-info-item {
		font-size: 13px;
	}
	
	.store-modal-content {
		max-width: 95%;
		margin: 0 10px;
	}
	
	.store-modal-body {
		padding: 25px 20px;
	}
	
	.store-popup-title {
		font-size: 22px;
	}
	
	.store-popup-city {
		font-size: 15px;
		margin-bottom: 20px;
	}
}

/* Small Mobile */
@media (max-width: 480px) {
	.store-locator-map-section {
		height: 400px;
		height: 400px;
		padding: 0px 30px 15px 30px;
	}
	
	.store-card-title {
		font-size: 16px;
		padding-left: 0;
		margin-bottom: 30px;
	}
	
	.store-card-badge {
		position: static;
		display: inline-block;
		margin-bottom: 10px;
	}
	
	.store-info-item {
		font-size: 12px;
	}
	
	.store-navigate-btn {
        padding: 10px 30px;
        font-size: 13px;
        border-radius: var(--pls-border-radius);
	}
	
	.store-popup-title {
		font-size: 20px;
	}
	
	.store-popup-details {
		gap: 12px;
	}
	
	.store-popup-item {
		padding: 10px;
		font-size: 13px;
	}
}

/* Print Styles */
@media print {
	.store-locator-map-section {
		display: none;
	}
	
	.store-locator-container {
		grid-template-columns: 1fr;
		box-shadow: none;
	}
	
	.store-card {
		page-break-inside: avoid;
		box-shadow: none;
		border: 1px solid #ddd;
	}
	
	.store-navigate-btn {
		display: none;
	}
	
	.store-modal {
		display: none !important;
	}
}

