/* ============================================================
   SwiftTranslate — Front-end Switcher Styles
   ============================================================ */

/* ── Inline switcher (shortcode) ────────────────────────── */
.swifttranslate-switcher.swifttranslate-inline-switcher {
	display: inline-flex;
	gap: 6px;
	flex-wrap: wrap;
	align-items: center;
}

.swifttranslate-lang-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 7px 14px;
	border: 2px solid #ddd;
	border-radius: 4px;
	text-decoration: none;
	color: inherit;
	font-size: 14px;
	transition: border-color .2s, background .2s;
	background: #fff;
}

.swifttranslate-lang-btn:hover {
	border-color: #2271b1;
	color: #2271b1;
}

.swifttranslate-lang-btn.active {
	border-color: #2271b1;
	background: #2271b1;
	color: #fff;
}

.swifttranslate-lang-btn .st-flag {
	font-size: 18px;
	line-height: 1;
}

/* ── Floating switcher ───────────────────────────────────── */
.swifttranslate-floating {
	position: fixed;
	z-index: 9999;
}

/* Position variants */
.swifttranslate-pos-bottom-right { bottom: 24px; right: 24px; }
.swifttranslate-pos-bottom-left  { bottom: 24px; left: 24px;  }
.swifttranslate-pos-top-right    { top: 80px;    right: 24px; }
.swifttranslate-pos-top-left     { top: 80px;    left: 24px;  }

.st-float-trigger {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 10px 16px;
	background: #2271b1;
	color: #fff;
	border: none;
	border-radius: 30px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	box-shadow: 0 4px 14px rgba(0,0,0,.22);
	transition: background .2s, transform .15s;
	white-space: nowrap;
}

.st-float-trigger:hover {
	background: #135e96;
	transform: translateY(-1px);
}

.st-float-trigger .st-flag { font-size: 18px; }

.st-caret {
	font-size: 10px;
	transition: transform .2s;
}

.swifttranslate-floating.open .st-caret {
	transform: rotate(180deg);
}

/* Dropdown */
.st-float-menu {
	position: absolute;
	bottom: calc(100% + 8px);
	right: 0;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	box-shadow: 0 8px 24px rgba(0,0,0,.14);
	list-style: none;
	margin: 0;
	padding: 6px 0;
	min-width: 160px;
	display: none;
}

.swifttranslate-pos-bottom-left .st-float-menu,
.swifttranslate-pos-top-left    .st-float-menu {
	right: auto;
	left: 0;
}

.swifttranslate-pos-top-right .st-float-menu,
.swifttranslate-pos-top-left  .st-float-menu {
	bottom: auto;
	top: calc(100% + 8px);
}

.swifttranslate-floating.open .st-float-menu {
	display: block;
}

.st-float-item {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 9px 16px;
	text-decoration: none;
	color: #333;
	font-size: 14px;
	transition: background .15s;
}

.st-float-item:hover {
	background: #f0f6fc;
	color: #2271b1;
}

.st-float-item.active {
	font-weight: 600;
	color: #2271b1;
}

.st-float-item .st-flag { font-size: 18px; }

/* Caret flip on open */
.swifttranslate-floating.open .st-float-trigger .st-caret {
	transform: rotate(180deg);
}

/* ── Admin bar spacing ────────────────────────────────────── */
.admin-bar .swifttranslate-pos-top-right,
.admin-bar .swifttranslate-pos-top-left {
	top: 112px;
}
