/* Pastille numérotée */
.bmn-ref {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 1.5em;
	height: 1.5em;
	margin: 0 0 0 .2em;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #b23a1b;
	color: #fff;
	font: 600 .7em/1 -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	vertical-align: super;
	cursor: pointer;
	transition: background .15s;
}
.bmn-ref:hover,
.bmn-ref.is-active { background: #7f2710; }
.bmn-ref:focus-visible { outline: 2px solid #f15a2e; outline-offset: 2px; }

.bmn-text { display: none; }

/* Fond gris sur la page quand une note est ouverte */
.bmn-overlay {
	position: fixed;
	inset: 0;
	z-index: 99998;
	background: rgba(0, 0, 0, .3);
	opacity: 0;
	visibility: hidden;
	pointer-events: none; /* la page reste cliquable (pastilles, liens) */
	transition: opacity .2s ease, visibility .2s ease;
}
.bmn-overlay.is-open { opacity: 1; visibility: visible; }

/* Panneau fixe (desktop) */
.bmn-panel {
	display: none;
	position: fixed;
	top: 120px;
	right: 16px;
	z-index: 99999;
	box-sizing: border-box;
	width: 340px;
	max-width: calc(100vw - 32px);
	max-height: 70vh;
	overflow-y: auto;
	padding: 14px 64px 14px 14px;
	background: #f15a2e;
	color: #fff;
	font: 400 15px/1.45 -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	box-shadow: 0 4px 16px rgba(0, 0, 0, .2);
}
.bmn-panel.is-open { display: block; }
.bmn-panel a { color: #fff; text-decoration: underline; }
.bmn-panel-text em,
.bmn-panel-text i { font-style: italic; }

.bmn-close {
	position: absolute;
	top: 12px;
	right: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #000;
	cursor: pointer;
}
.bmn-close:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* Mobile / tablette : bandeau en bas */
@media (max-width: 900px) {
	.bmn-panel {
		top: auto;
		right: 0;
		bottom: 0;
		left: 0;
		width: auto;
		max-width: none;
		max-height: 45vh;
		padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
	}
}
