/* ==========================================================================
   Bouton Doctolib Flottant - Styles Publics (Front-Office)
   ========================================================================== */

#mb-doctolib-floating-btn {
	position: fixed;
	right: 0;
	transform: translateY(-50%);
	display: flex;
	align-items: center;
	justify-content: flex-end;
	text-decoration: none;
	border-radius: 28px 0 0 28px;
	box-shadow: -4px 6px 20px rgba(0, 0, 0, 0.15);
	cursor: pointer;
	overflow: hidden;
	height: 56px;
	transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
	z-index: 99999; /* S'assure d'être au-dessus de la majorité des thèmes */
}

#mb-doctolib-floating-btn:hover {
	box-shadow: -4px 8px 25px rgba(0, 0, 0, 0.25);
	transform: translateY(-50%) scale(1.02);
}

#mb-doctolib-floating-btn .mb-bubble-text {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	font-size: 14px;
	font-weight: 700;
	padding: 0 10px 0 24px;
	white-space: nowrap;
	display: block;
	max-width: 0;
	opacity: 0;
	overflow: hidden;
	line-height: 56px;
	transition: max-width 0.4s cubic-bezier(0.25, 0.8, 0.25, 1), opacity 0.3s ease;
}

/* Glissement du texte au survol ou forcé par JS au chargement */
#mb-doctolib-floating-btn:hover .mb-bubble-text,
#mb-doctolib-floating-btn.mb-force-open .mb-bubble-text {
	max-width: 200px;
	opacity: 1;
}

#mb-doctolib-floating-btn .mb-bubble-icon {
	width: 56px;
	height: 56px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	flex-shrink: 0;
}

#mb-doctolib-floating-btn .mb-bubble-icon img {
	width: 36px;
	height: 36px;
	object-fit: contain;
	border-radius: 50%;
	transition: transform 0.3s ease;
}

#mb-doctolib-floating-btn:hover .mb-bubble-icon img {
	transform: rotate(10deg) scale(1.05);
}

/* Animations d'attention */
@keyframes mb-front-pulse {
	0% { box-shadow: -2px 4px 10px rgba(0, 83, 135, 0.3); }
	50% { box-shadow: -4px 8px 25px rgba(0, 83, 135, 0.6); }
	100% { box-shadow: -2px 4px 10px rgba(0, 83, 135, 0.3); }
}

@keyframes mb-front-shake {
	0%, 100% { transform: translateY(-50%); }
	10%, 30%, 50%, 70%, 90% { transform: translateY(-53%); }
	20%, 40%, 60%, 80% { transform: translateY(-47%); }
}

#mb-doctolib-floating-btn.mb-anim-pulse .mb-bubble-icon {
	animation: mb-front-pulse 2s infinite ease-in-out;
}

#mb-doctolib-floating-btn.mb-anim-shake {
	animation: mb-front-shake 2.5s infinite ease-in-out;
}

/* ==========================================================================
   Design Responsif (Mobile et Tablettes)
   ========================================================================== */

@media (max-width: 768px) {
	/* Masque le bouton si l'option correspondante est activée */
	#mb-doctolib-floating-btn.mb-hide-mobile {
		display: none !important;
	}
	
	/* Réduction de taille sur mobile pour une navigation moins intrusive */
	#mb-doctolib-floating-btn {
		height: 48px;
		border-radius: 24px 0 0 24px;
	}
	
	#mb-doctolib-floating-btn .mb-bubble-icon {
		width: 48px;
		height: 48px;
	}
	
	#mb-doctolib-floating-btn .mb-bubble-icon img {
		width: 30px;
		height: 30px;
	}
	
	#mb-doctolib-floating-btn .mb-bubble-text {
		font-size: 12px;
		line-height: 48px;
		padding: 0 8px 0 16px;
	}
	
	#mb-doctolib-floating-btn:hover .mb-bubble-text {
		max-width: 150px;
	}
}
