/**
 * Truento – globales Hilfe-Tooltip.
 *
 * Verhalten nach dem Shopify-Tooltip-Prinzip:
 * - ergänzende, nicht-interaktive Information
 * - Hover und Tastatur-Fokus
 * - automatische Platzierung durch JavaScript
 *
 * Datei:
 * /assets/css/components/help-tooltip.css
 */

.truento-help {
	position: relative;
	top: -1px;
	display: inline-flex;
	align-items: center;
	margin-left: 5px;
	vertical-align: middle;
}

.truento-help__icon {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 20px;
	height: 20px;
	margin: -3px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: transparent;
	font: inherit;
	font-size: 0;
	line-height: 1;
	cursor: help;
	appearance: none;
}

.truento-help__icon::before {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 13px;
	height: 13px;
	border: 1px solid rgba(36, 40, 45, .28);
	border-radius: 50%;
	background: transparent;
	color: var(--truento-text-muted, #73777c);
	content: "?";
	font-size: 9px;
	font-weight: 600;
	line-height: 1;
}

.truento-help__icon:hover::before,
.truento-help__icon:focus-visible::before,
.truento-help__icon[aria-expanded="true"]::before {
	border-color: rgba(36, 40, 45, .38);
	color: var(--truento-text-muted, #73777c);
}


.truento-help__icon:hover,
.truento-help__icon:focus-visible,
.truento-help__icon[aria-expanded="true"] {
	outline: none;
}

.truento-help__tooltip {
	position: fixed;
	z-index: 100000;
	display: block;
	box-sizing: border-box;
	width: max-content;
	max-width: min(340px, calc(100vw - 24px));
	padding: 10px 12px;
	border-radius: 5px;
	background: #24282d;
	color: #fff;
	font-size: 12px;
	font-weight: 400;
	line-height: 1.5;
	text-align: left;
	white-space: normal;
	box-shadow: 0 6px 18px rgba(0, 0, 0, .16);
	pointer-events: none;
}

.truento-help__tooltip[hidden] {
	display: none !important;
}

.truento-help__tooltip strong {
	display: block;
	margin-bottom: 3px;
	color: #fff;
	font-weight: 600;
}

.truento-help__tooltip::after {
	position: absolute;
	width: 8px;
	height: 8px;
	background: #24282d;
	content: "";
	transform: rotate(45deg);
}

.truento-help__tooltip[data-placement="top"]::after {
	left: var(--truento-help-arrow, 50%);
	bottom: -4px;
	transform: translateX(-50%) rotate(45deg);
}

.truento-help__tooltip[data-placement="bottom"]::after {
	left: var(--truento-help-arrow, 50%);
	top: -4px;
	transform: translateX(-50%) rotate(45deg);
}

.truento-help__tooltip[data-placement="left"]::after {
	top: var(--truento-help-arrow, 50%);
	right: -4px;
	transform: translateY(-50%) rotate(45deg);
}

.truento-help__tooltip[data-placement="right"]::after {
	top: var(--truento-help-arrow, 50%);
	left: -4px;
	transform: translateY(-50%) rotate(45deg);
}

@media (hover: none), (pointer: coarse) {
	.truento-help__icon {
		cursor: default;
	}
}