.aiim-badge {
	position: absolute;
	right: 8px;
	bottom: 8px;
	z-index: 2;
	background: rgba(20, 20, 20, .62);
	color: #fff;
	font-size: 11px;
	line-height: 1;
	letter-spacing: .02em;
	padding: 4px 7px;
	border-radius: 4px;
	pointer-events: none;
	white-space: nowrap;
}

/* The wrapper encloses exactly the image area (not the figcaption), so the
   badge anchors to the image and never sits on top of the caption */
.aiim-imgwrap {
	position: relative;
	display: inline-block;
	max-width: 100%;
	line-height: 0;
	vertical-align: top;
}

.aiim-thumbwrap {
	position: relative;
	display: block;
}

/* Mini variant for small images (e.g. 72px sidebar teasers): shows only the
   short label ("AI"/"KI") taken from the data attribute. The full text stays
   in the DOM (screen readers) and appears as a tooltip. Applied via JS based
   on the rendered image width. */
.aiim-badge--mini {
	font-size: 0;
	right: 3px;
	bottom: 3px;
	padding: 2px 4px;
	border-radius: 3px;
	pointer-events: auto;
}

.aiim-badge--mini::after {
	content: attr(data-aiim-short);
	font-size: 9px;
	line-height: 1;
	font-weight: 600;
	letter-spacing: .03em;
}
