/*
 * @author: Mathieu MARI <contact@mathieumari.com>
 * @date:   26-10-2024 12:24:20
 * @lastModifiedBy:   Mathieu MARI <contact@mathieumari.com>
 * @lastModifiedTime: 2025-08-05 22:58:50
 */

/* Base du container de l'autocomplétion */
.pac-container {
	border: 1px solid #ddd; /* Bordure fine et discrète */
	box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Ombre légère pour un effet de flottaison */
	border-radius: 8px; /* Bords arrondis pour un look moderne */
	background-color: white; /* Fond blanc pour la clarté */
	font-family: Arial, sans-serif; /* Police moderne et lisible */
	color: #333; /* Couleur de texte foncée pour un contraste optimal */
	font-size: 16px; /* Taille de police appropriée pour la lisibilité */
	z-index: 1000; /* S'assurer qu'il apparaisse au-dessus des autres éléments */
}

/* Styles des éléments de suggestion individuels */
.pac-item {
	padding: 10px 20px; /* Espacement interne pour un toucher aéré */
	cursor: pointer; /* Indique que chaque élément est cliquable */
	border-bottom: 0.2px solid rgba(204, 204, 204, 0.02); /* Ligne séparatrice subtile et très peu visible entre les éléments */
}

.pac-item:last-child {
	border-bottom: none; /* Pas de bordure au bas du dernier élément */
}

/* Surbrillance lors du survol */
.pac-item:hover {
	background-color: #f0f0f0; /* Couleur de fond légèrement différente au survol */
}

/* Style du terme de requête mis en évidence dans les suggestions */
.pac-item-query {
	font-weight: bold; /* Mise en gras du texte de la requête pour une distinction claire */
}

/* Adapter le style des icônes si utilisées dans les suggestions */
.pac-icon {
	display: none; /* Retirer les icônes pour une apparence plus épurée */
}

/* Masquer le logo Google dans le .pac-container */
.pac-container::after {
	display: none;
}

/* ---------------------------------------------------------------------------------------------------- Modal spécifique à la recherche sur smartphone */
#maestra-modal-google-wrapper {
	max-width: 370px;
	width: 100%;
	margin: 0 auto;
	box-sizing: border-box;
	padding: 28px 10px 16px 10px; /* place pour bouton fermer */
	background: #fff;
	border-radius: 16px;
	display: flex;
	flex-direction: column;
	align-items: stretch;
	position: relative;
	z-index: 200002;
	overflow: visible !important;
	box-shadow: 0 6px 24px rgba(60, 60, 90, 0.09);
}

#maestra-modal-google-wrapper .maestra-modal-title {
	font-size: 18px;
	font-weight: 600;
	margin-bottom: 14px;
	text-align: center;
	margin-top: 0;
	padding-top: 0;
	color: #222;
}

#maestra-modal-google-wrapper .autocomplete-field-wrap {
	position: relative;
	width: 100%;
}

#maestra-modal-google-wrapper #swal-google-autocomplete {
	width: 100%;
	font-size: 18px;
	padding: 13px 38px 13px 13px; /* espace pour bouton effacer */
	border-radius: 12px;
	border: 1px solid #e5e5e5;
	background: #fafaff;
	margin-bottom: 0;
	box-sizing: border-box;
	color: #222;
	font-weight: 500;
}

#maestra-modal-google-wrapper #clear-swal-input {
	position: absolute;
	top: 8px;
	right: 10px;
	width: 28px;
	height: 28px;
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	display: none;
	z-index: 2;
}
#maestra-modal-google-wrapper #clear-swal-input svg {
	pointer-events: none;
}

#maestra-modal-google-wrapper .pac-container {
	position: absolute !important;
	left: 0 !important;
	top: calc(100% + 4px) !important;
	width: 100% !important;
	max-width: 100% !important;
	min-width: 0 !important;
	box-shadow: 0 8px 24px rgba(40, 40, 70, 0.11) !important;
	z-index: 999999 !important;
	background: #fff !important;
	border-radius: 0 0 12px 12px !important;
	overflow-y: auto !important;
	overflow-x: hidden !important;
	max-height: 230px !important;
	margin: 0 !important;
	box-sizing: border-box !important;
	border: 1px solid #e5e5e5 !important;
	font-size: 16px !important;
}

#maestra-modal-google-wrapper .pac-item {
	white-space: normal !important;
	word-break: break-word !important;
	padding-right: 12px !important;
	font-size: 16px !important;
	color: #1a1a1a !important;
	background: #fff !important;
}

#maestra-modal-google-wrapper .pac-item-selected {
	background: #f2f6fc !important;
}

#maestra-modal-google-wrapper .pac-icon {
	margin-right: 8px;
}

/* Responsive pour écrans minuscules */
@media (max-width: 400px) {
	#maestra-modal-google-wrapper {
		max-width: 98vw !important;
		padding-left: 2vw;
		padding-right: 2vw;
	}
	#maestra-modal-google-wrapper .pac-container {
		max-width: 98vw !important;
	}
}
