.mlmgr-switcher {
	--mlmgr-bg: #fff;
	--mlmgr-text: #1f2937;
	--mlmgr-border: #d1d5db;
	--mlmgr-hover-bg: #f3f4f6;
	--mlmgr-hover-text: #111827;
	--mlmgr-accent: #2563eb;
	--mlmgr-radius: 8px;
	--mlmgr-font-size: 14px;
	position: relative;
	display: inline-block;
	font-size: var(--mlmgr-font-size);
	line-height: 1.4;
	color: var(--mlmgr-text);
	font-family: inherit;
	box-sizing: border-box;
}

.mlmgr-switcher *,
.mlmgr-switcher *::before,
.mlmgr-switcher *::after {
	box-sizing: border-box;
}

.mlmgr-switcher__toggle,
.mlmgr-switcher__link {
	display: inline-flex;
	align-items: center;
	gap: 0.4em;
	color: var(--mlmgr-text);
	background: var(--mlmgr-bg);
	border: 1px solid var(--mlmgr-border);
	border-radius: var(--mlmgr-radius);
	text-decoration: none;
	font: inherit;
	cursor: pointer;
}

.mlmgr-switcher__toggle {
	padding: 0.45em 0.7em;
	min-width: 2.5em;
}

.mlmgr-switcher__toggle:hover,
.mlmgr-switcher__toggle:focus-visible,
.mlmgr-switcher--dropdown .mlmgr-switcher__link:hover,
.mlmgr-switcher--dropdown .mlmgr-switcher__link:focus-visible,
.mlmgr-switcher--list .mlmgr-switcher__link:hover,
.mlmgr-switcher--list .mlmgr-switcher__link:focus-visible {
	background: var(--mlmgr-hover-bg);
	color: var(--mlmgr-hover-text);
	border-color: var(--mlmgr-accent);
}

.mlmgr-switcher__toggle:focus-visible,
.mlmgr-switcher__link:focus-visible {
	outline: 2px solid var(--mlmgr-accent);
	outline-offset: 2px;
}

.mlmgr-switcher__chevron {
	width: 0.45em;
	height: 0.45em;
	margin-left: 0.35em;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translateY(-0.1em);
}

.mlmgr-switcher.is-open .mlmgr-switcher__chevron {
	transform: rotate(225deg) translateY(-0.1em);
}

.mlmgr-switcher__flag,
.mlmgr-switcher__flag-emoji,
.mlmgr-switcher__flag-img {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
}

.mlmgr-switcher img.mlmgr-switcher__flag-img {
	display: block;
	width: 20px;
	height: 15px;
	max-width: 20px;
	max-height: 15px;
	object-fit: cover;
	border-radius: 2px;
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15);
	flex-shrink: 0;
}

.mlmgr-switcher__flag-code {
	display: inline-block;
	min-width: 20px;
	padding: 0 3px;
	font-size: 9px;
	font-weight: 700;
	line-height: 15px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	background: var(--mlmgr-hover-bg);
	border: 1px solid var(--mlmgr-border);
	border-radius: 2px;
}

.mlmgr-switcher__flag-emoji {
	font-size: 1.15em;
}

.mlmgr-switcher__menu {
	position: absolute;
	top: calc(100% + 4px);
	left: 0;
	z-index: 1000;
	margin: 0;
	padding: 0.35em;
	list-style: none;
	min-width: 100%;
	background: var(--mlmgr-bg);
	border: 1px solid var(--mlmgr-border);
	border-radius: var(--mlmgr-radius);
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.mlmgr-switcher__item {
	margin: 0;
	padding: 0;
	list-style: none;
}

.mlmgr-switcher--dropdown .mlmgr-switcher__link {
	display: flex;
	width: 100%;
	padding: 0.4em 0.6em;
	border: 0;
	border-radius: calc(var(--mlmgr-radius) - 2px);
	background: transparent;
}

.mlmgr-switcher--dropdown .mlmgr-switcher__link.is-current {
	color: var(--mlmgr-accent);
	font-weight: 600;
}

.mlmgr-switcher--list {
	display: block;
}

.mlmgr-switcher__list {
	display: flex;
	flex-wrap: wrap;
	gap: 0.4em;
	margin: 0;
	padding: 0;
	list-style: none;
}

.mlmgr-switcher--list .mlmgr-switcher__link {
	padding: 0.4em 0.7em;
}

.mlmgr-switcher--list .mlmgr-switcher__link.is-current,
.mlmgr-switcher--inline .mlmgr-switcher__link.is-current {
	border-color: var(--mlmgr-accent);
	color: var(--mlmgr-accent);
	font-weight: 600;
}

.mlmgr-switcher--inline {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.35em;
	background: var(--mlmgr-bg);
	border: 1px solid var(--mlmgr-border);
	border-radius: var(--mlmgr-radius);
	padding: 0.25em 0.5em;
}

.mlmgr-switcher--inline .mlmgr-switcher__link {
	border: 0;
	background: transparent;
	padding: 0.2em 0.15em;
	border-radius: 0;
}

.mlmgr-switcher--inline .mlmgr-switcher__link:hover,
.mlmgr-switcher--inline .mlmgr-switcher__link:focus-visible {
	color: var(--mlmgr-accent);
	background: transparent;
}

.mlmgr-switcher__sep {
	color: var(--mlmgr-border);
	user-select: none;
}

.mlmgr-switcher-empty {
	margin: 0;
	color: #646970;
}

@media (max-width: 480px) {
	.mlmgr-switcher--list .mlmgr-switcher__list {
		flex-direction: column;
	}
}
