/* PMT language switcher — header dropdown */
.pmt-lang-switcher {
	position: relative;
	margin-left: 4px;
}

.pmt-lang-dd {
	position: relative;
}

.pmt-lang-toggle {
	display: inline-flex;
	align-items: center;
	box-sizing: border-box;
	gap: 5px;
	padding: 6px 8px;
	border-radius: 6px;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.2;
	color: inherit;
	cursor: pointer;
	list-style: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}

/* Desktop: compact globe + language code; full language name on mobile. */
.pmt-lang-code {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.02em;
}

.pmt-lang-current {
	display: none;
}

.pmt-lang-toggle::-webkit-details-marker {
	display: none;
}

.pmt-lang-toggle::marker {
	content: "";
}

.pmt-lang-toggle:hover,
.pmt-lang-toggle:focus-visible {
	background: #f2f9fa;
	color: #1a7c8f;
	outline: none;
}

.pmt-lang-globe {
	width: 17px;
	height: 17px;
	flex: 0 0 auto;
}

.pmt-lang-chev {
	width: 12px;
	height: 12px;
	flex: 0 0 auto;
	transition: transform 0.15s ease;
}

.pmt-lang-dd[open] .pmt-lang-chev {
	transform: rotate(180deg);
}

.pmt-lang-dd .pmt-lang-list {
	position: absolute;
	right: 0;
	top: calc(100% + 8px);
	z-index: 1000;
	min-width: 168px;
	margin: 0;
	padding: 6px;
	list-style: none;
	background: #fff;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	box-shadow: 0 12px 32px rgba(15, 23, 42, 0.14);
}

.pmt-lang-dd .pmt-lang-list li {
	margin: 0;
	padding: 0;
	list-style: none;
}

.pmt-lang-dd .pmt-lang-list a {
	display: block;
	padding: 9px 12px;
	border-radius: 6px;
	color: #1e293b;
	font-size: 14px;
	font-weight: 400;
	line-height: 1.3;
	text-decoration: none;
	white-space: nowrap;
	transition: background-color 0.12s ease, color 0.12s ease;
}

.pmt-lang-dd .pmt-lang-list a:hover,
.pmt-lang-dd .pmt-lang-list a:focus-visible {
	background: #f2fafb;
	color: #1a7c8f;
	outline: none;
}

.pmt-lang-dd .pmt-lang-list .is-current a {
	background: #e9f8f9;
	color: #1a7c8f;
	font-weight: 600;
}

/* Transparent header (home hero): keep the trigger white. */
.ast-theme-transparent-header .pmt-lang-toggle {
	color: #fff;
}

.ast-theme-transparent-header .pmt-lang-toggle:hover,
.ast-theme-transparent-header .pmt-lang-toggle:focus-visible {
	background: rgba(255, 255, 255, 0.16);
	color: #fff;
}

.ast-theme-transparent-header .pmt-lang-dd .pmt-lang-list a {
	color: #1e293b;
}

.ast-theme-transparent-header .pmt-lang-dd .pmt-lang-list a:hover {
	color: #1a7c8f;
}

/* German menu links are wider than English: trim padding so the switcher
   stays on the same row on desktop. */
@media (min-width: 922px) {
	html:lang(de) .main-header-menu > li > a.menu-link {
		padding-left: 0.6em;
		padding-right: 0.6em;
	}
}

/* Japanese headings: prefer breaking between phrases, not inside words.
   Supported in Chromium; other engines keep normal CJK wrapping. */
html:lang(ja) h1,
html:lang(ja) h2,
html:lang(ja) h3 {
	word-break: auto-phrase;
}

@media (max-width: 921px) {
	.pmt-lang-switcher {
		width: 100%;
		margin: 4px 0 0;
	}

	.pmt-lang-dd {
		width: 100%;
	}

	.pmt-lang-toggle {
		width: 100%;
		justify-content: flex-start;
		padding: 12px 16px;
		font-size: 15px;
	}

	.pmt-lang-code {
		display: none;
	}

	.pmt-lang-current {
		display: inline;
	}

	.pmt-lang-chev {
		margin-left: auto;
	}

	.pmt-lang-dd .pmt-lang-list {
		position: static;
		top: auto;
		right: auto;
		min-width: 0;
		margin: 4px 0 6px 12px;
		padding: 0;
		border: 0;
		border-radius: 0;
		box-shadow: none;
		background: transparent;
	}

	.pmt-lang-dd .pmt-lang-list a {
		padding: 10px 16px;
		font-size: 15px;
	}

	.ast-theme-transparent-header .pmt-lang-toggle {
		color: inherit;
	}
}
