/* Internal customer notes flag, available across the platform. */
.rd-crm-fab-flag {
	align-items: center;
	background: var(--rd-primary-hover);
	border: 0;
	border-radius: var(--rd-borderradius-border-big) 0 0 var(--rd-borderradius-border-big);
	box-shadow: var(--rd-shadow-level-2);
	color: var(--rd-font-light);
	cursor: grab;
	display: flex;
	font-size: var(--rd-fontsize-4);
	font-weight: var(--rd-fontweights-open-sans-1);
	gap: var(--rd-spacing-x-sm);
	padding: var(--rd-spacing-sm) var(--rd-spacing-md);
	position: fixed;
	right: 0;
	top: var(--rd-spacing-xxx-lg);
	touch-action: none;
	transition: background 150ms ease;
	white-space: nowrap;
	writing-mode: horizontal-tb;
	z-index: 1005;
}

.rd-crm-fab-flag.rd-crm-fab-dragging {
	cursor: grabbing;
	user-select: none;
}

.rd-crm-fab-flag[hidden] {
	display: none;
}

.rd-crm-fab-flag:hover,
.rd-crm-fab-flag:focus-visible {
	background: var(--rd-primary-pressed);
}

.rd-crm-fab-icon {
	display: inline-grid;
	place-items: center;
	flex: none;
}

.rd-crm-fab-icon::before {
	margin: 0 !important;
	background-color: currentColor;
}

body:has(.kursadmin_warinung) .rd-crm-fab-flag {
	top: calc(var(--rd-spacing-xx-huge) + var(--rd-spacing-x-huge));
}

@media (max-width: 900px) {
	body:has(.kursadmin_warinung) .rd-crm-fab-flag,
	.rd-crm-fab-flag {
		justify-content: center;
		width: calc(var(--rd-spacing-lg) + var(--rd-spacing-xx-sm));
		height: calc(var(--rd-spacing-lg) + var(--rd-spacing-xx-sm));
		padding: 0;
		bottom: var(--rd-spacing-xx-lg);
		top: auto;
	}

	.rd-crm-fab-label {
		display: none;
	}
}
