/*
 * Language switcher (GTranslate, "float" look, [gtranslate] shortcode in the
 * header 652, widget class `f-lang`).
 *
 * The plugin injects its own stylesheet at runtime, after this one: every
 * rule here is scoped under `.f-lang` to outrank it. No flags: the current
 * language reads as its code (FR) next to a chevron, like a quiet nav link;
 * the list opens over the page in a `--f-surface` panel, like the nav
 * dropdown.
 */

.f-lang {
	position: relative;
	flex-shrink: 0;
}

.f-lang .gtranslate_wrapper,
.f-lang #gt_float_wrapper {
	display: block;
}

.f-lang .gt_float_switcher {
	display: block;
	overflow: visible;
	font-family: var(--f-font, "Archivo"), sans-serif;
	font-size: 1rem;
	line-height: 1;
	color: var(--f-ink);
	background: none;
	border-radius: 0;
	box-shadow: none;
	transition: none;
}

.f-lang .gt_float_switcher img {
	display: none;
}

/* Trigger: FR + chevron, 48 px tall for touch. */
.f-lang .gt_float_switcher .gt-selected {
	background: none;
	overflow: visible;
	text-align: start;
}

.f-lang .gt_float_switcher .gt-selected .gt-current-lang {
	display: flex;
	align-items: center;
	gap: 6px;
	min-height: 48px;
	padding: 0 8px;
	font-weight: 600;
	color: var(--f-ink);
	transition: color var(--dur-fast, 250ms) ease;
}

.f-lang .gt_float_switcher .gt-selected .gt-current-lang span.gt-lang-code {
	display: inline;
	top: 0;
	letter-spacing: 0;
}

.f-lang .gt_float_switcher .gt-selected .gt-current-lang span.gt_float_switcher-arrow {
	width: 10px;
	height: 10px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'><path d='M1 3.2 5 7l4-3.8' fill='none' stroke='black' stroke-width='1.6'/></svg>") center / contain no-repeat;
	mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'><path d='M1 3.2 5 7l4-3.8' fill='none' stroke='black' stroke-width='1.6'/></svg>") center / contain no-repeat;
	transform: none;
	transition: transform var(--dur-fast, 250ms) var(--f-ease-out, ease);
}

.f-lang .gt_float_switcher .gt-selected .gt-current-lang span.gt_float_switcher-arrow.gt_arrow_rotate {
	transform: rotate(180deg);
}

@media (hover: hover) {
	.f-lang .gt_float_switcher .gt-selected:hover .gt-current-lang {
		color: var(--f-accent);
	}
}

.f-lang .gt_float_switcher .gt-selected:focus-visible {
	outline: 2px solid var(--f-accent);
	outline-offset: 3px;
}

/* Panel: over the page, under the trigger, aligned on its right edge. */
.f-lang .gt_float_switcher .gt_options {
	position: absolute;
	top: calc(100% + 8px);
	right: 0;
	z-index: 60;
	min-width: 168px;
	max-height: none;
	overflow: visible;
	padding: 8px 0;
	background-color: var(--f-surface);
	opacity: 0;
	transform: translateY(-6px);
	transition:
		opacity var(--dur-fast, 250ms) var(--f-ease-out, ease),
		transform var(--dur-fast, 250ms) var(--f-ease-out, ease);
}

.f-lang .gt_float_switcher .gt_options.gt-open {
	opacity: 1;
	transform: none;
}

.f-lang .gt_float_switcher .gt_options a,
.f-lang .gt_float_switcher .gt_options a.gt-current {
	display: block;
	padding: 14px 20px;
	font-size: 1rem;
	line-height: 1.2;
	color: var(--f-ink);
	text-decoration: none;
	white-space: nowrap;
	transition: color var(--dur-fast, 250ms) ease, background-color var(--dur-fast, 250ms) ease;
}

.f-lang .gt_float_switcher .gt_options a:hover,
.f-lang .gt_float_switcher .gt_options a:focus-visible,
.f-lang .gt_float_switcher .gt_options a.gt-current {
	color: var(--f-accent);
	background-color: var(--f-surface-2);
}

.f-lang .gt_float_switcher .gt_options a:focus-visible {
	outline: 2px solid var(--f-accent);
	outline-offset: -2px;
}

/* Footer: in the legal line, at its size; the list opens upwards, one step
   below the footer surface. */
.elementor-location-footer .f-lang {
	align-self: center;
}

.elementor-location-footer .f-lang .gt_float_switcher .gt-selected .gt-current-lang {
	min-height: 0;
	padding: 4px 0;
	margin-block: -4px;
	font-size: var(--fs-small);
}

.elementor-location-footer .f-lang .gt_float_switcher .gt_options {
	top: auto;
	bottom: calc(100% + 8px);
	background-color: var(--f-bg);
	transform: translateY(6px);
}

.elementor-location-footer .f-lang .gt_float_switcher .gt_options.gt-open {
	transform: none;
}

.elementor-location-footer .f-lang .gt_float_switcher .gt-selected .gt-current-lang span.gt_float_switcher-arrow {
	transform: rotate(180deg);
}

.elementor-location-footer .f-lang .gt_float_switcher .gt-selected .gt-current-lang span.gt_float_switcher-arrow.gt_arrow_rotate {
	transform: none;
}

/* Mobile: the legal line stacks; the switcher keeps to the left edge. */
@media (max-width: 767px) {
	.elementor-location-footer .f-lang {
		align-self: flex-start;
	}

	.elementor-location-footer .f-lang .gt_float_switcher .gt_options {
		right: auto;
		left: 0;
	}
}

/* Mobile and tablet: the actions (switcher first) sit just before the burger. */
@media (max-width: 1024px) {
	.elementor-location-header .elementor-element.e-con:has(> .f-lang) {
		order: 2;
		margin-inline-start: auto;
	}

	.elementor-location-header .elementor-element.elementor-widget-nav-menu {
		order: 3;
		flex-grow: 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	.f-lang .gt_float_switcher .gt_options,
	.f-lang .gt_float_switcher .gt-selected .gt-current-lang span.gt_float_switcher-arrow {
		transition: none;
	}
}
