.fanfan-language-switcher {
	position: relative;
	display: inline-block;
	color: var(--wp--preset--color--ink, #151816);
	font-size: 0.8125rem;
}

.fanfan-language-switcher summary {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 5px;
	min-width: 44px;
	min-height: 44px;
	border: 0;
	border-radius: 6px;
	background: transparent;
	cursor: pointer;
	list-style: none;
	padding: 7px 8px;
	transition: background-color 160ms ease, color 160ms ease;
}

.fanfan-language-switcher summary::-webkit-details-marker {
	display: none;
}

.fanfan-language-switcher summary:hover,
.fanfan-language-switcher[open] summary {
	background: var(--wp--preset--color--moss-soft, #e8eeea);
}

.fanfan-language-switcher__short {
	font-weight: 600;
	letter-spacing: 0.02em;
}

.fanfan-language-switcher__icon {
	width: 14px;
	height: 14px;
	transition: transform 160ms ease;
}

.fanfan-language-switcher[open] .fanfan-language-switcher__icon {
	transform: rotate(180deg);
}

.fanfan-language-switcher__list {
	position: absolute;
	z-index: 30;
	top: calc(100% + 8px);
	right: 0;
	left: auto;
	min-width: max-content;
	margin: 0;
	border: 1px solid var(--wp--preset--color--border, #d9deda);
	border-radius: 8px;
	background: var(--wp--preset--color--surface, #fff);
	box-shadow: 0 16px 40px rgba(21, 24, 22, 0.08);
	padding: 5px;
	list-style: none;
}

.fanfan-language-switcher__list a,
.fanfan-language-switcher__list span[aria-disabled="true"] {
	display: flex;
	align-items: center;
	min-width: 132px;
	min-height: 40px;
	border-radius: 4px;
	padding: 7px 10px;
	color: var(--wp--preset--color--ink, #151816);
	text-decoration: none;
}

.fanfan-language-switcher__list a:hover,
.fanfan-language-switcher__list a:focus-visible,
.fanfan-language-switcher__list a[aria-current="page"] {
	background: var(--wp--preset--color--moss-soft, #e8eeea);
}

.fanfan-language-switcher__list a[aria-current="page"] {
	font-weight: 600;
}

.fanfan-language-switcher__list span[aria-disabled="true"] {
	opacity: 0.55;
}

.fanfan-language-switcher .screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
}

.fanfan-original-language-fallback {
	margin-block: 0 1.25rem;
	color: var(--wp--preset--color--muted, #626a65);
	font-size: 0.8125rem;
	line-height: 1.6;
}

@media (prefers-reduced-motion: reduce) {
	.fanfan-language-switcher summary,
	.fanfan-language-switcher__icon {
		transition: none;
	}
}
