/* Euro Realtime Translate — popup + persistent switcher styles */

#ert-popup, #ert-launcher {
	--ert-accent: #22d3ee;
	font-family: 'JetBrains Mono', 'SF Mono', 'Fira Code', ui-monospace, monospace;
}

/* ---------------- Popup card ---------------- */
#ert-popup {
	position: fixed;
	z-index: 999999;
	width: 320px;
	max-width: calc(100vw - 32px);
	background: #0d1117;
	border: 1px solid rgba(148, 163, 184, 0.18);
	border-radius: 10px;
	box-shadow: 0 12px 40px rgba(0,0,0,0.55), 0 0 0 1px rgba(34,211,238,0.06);
	padding: 16px 16px 14px;
	color: #e6edf3;
	opacity: 0;
	transform: translateY(12px) scale(0.98);
	transition: opacity 0.35s ease, transform 0.35s ease;
	pointer-events: none;
}
#ert-popup.ert-visible {
	opacity: 1;
	transform: translateY(0) scale(1);
	pointer-events: auto;
}

#ert-popup.ert-pos-bottom-right { right: 20px; bottom: 20px; }
#ert-popup.ert-pos-bottom-left  { left: 20px; bottom: 20px; }
#ert-popup.ert-pos-top-right    { right: 20px; top: 20px; }
#ert-popup.ert-pos-top-left     { left: 20px; top: 20px; }
#ert-popup.ert-pos-center {
	left: 50%; top: 50%;
	transform: translate(-50%, -46%) scale(0.98);
}
#ert-popup.ert-pos-center.ert-visible {
	transform: translate(-50%, -50%) scale(1);
}

#ert-popup .ert-topline {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 11px;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--ert-accent);
	margin-bottom: 10px;
}
#ert-popup .ert-topline .ert-dot {
	width: 6px; height: 6px; border-radius: 50%;
	background: var(--ert-accent);
	box-shadow: 0 0 8px var(--ert-accent);
	flex-shrink: 0;
}

#ert-popup .ert-close {
	position: absolute;
	top: 10px; right: 12px;
	background: none; border: none;
	color: #8b949e;
	font-size: 16px;
	cursor: pointer;
	line-height: 1;
	padding: 4px;
}
#ert-popup .ert-close:hover { color: #e6edf3; }

#ert-popup .ert-title {
	font-size: 14px;
	font-weight: 600;
	margin: 0 0 4px;
	color: #f0f6fc;
}
#ert-popup .ert-sub {
	font-size: 12px;
	color: #8b949e;
	margin: 0 0 12px;
	line-height: 1.5;
}

#ert-popup .ert-see-original {
	width: 100%;
	display: flex;
	align-items: center;
	gap: 8px;
	background: rgba(255,255,255,0.04);
	border: 1px dashed rgba(148,163,184,0.3);
	border-radius: 7px;
	color: #c9d1d9;
	font-size: 12px;
	font-weight: 600;
	font-family: inherit;
	padding: 9px 12px;
	cursor: pointer;
	margin-bottom: 10px;
	transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}
#ert-popup .ert-see-original:hover {
	border-color: var(--ert-accent);
	border-style: solid;
	color: #fff;
	background: rgba(34,211,238,0.08);
}
#ert-popup .ert-see-original-icon {
	font-size: 14px;
	color: var(--ert-accent);
}

#ert-popup .ert-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 6px;
	margin-top: 4px;
	max-height: 240px;
	overflow-y: auto;
	padding-right: 2px;
}
#ert-popup .ert-grid button {
	background: rgba(255,255,255,0.03);
	border: 1px solid rgba(148,163,184,0.14);
	border-radius: 6px;
	color: #c9d1d9;
	font-size: 11px;
	font-family: inherit;
	padding: 7px 4px;
	cursor: pointer;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 3px;
	transition: border-color 0.15s ease, color 0.15s ease;
}
#ert-popup .ert-grid button:hover {
	border-color: var(--ert-accent);
	color: #fff;
}
#ert-popup .ert-grid button.ert-active {
	border-color: var(--ert-accent);
	background: rgba(34,211,238,0.1);
	color: #fff;
}
#ert-popup .ert-grid .ert-flag { font-size: 15px; }

#ert-popup .ert-footer-row {
	margin-top: 10px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}
#ert-popup .ert-no-thanks {
	background: none;
	border: none;
	color: #6e7681;
	font-size: 11px;
	font-family: inherit;
	cursor: pointer;
}
#ert-popup .ert-no-thanks:hover { color: #8b949e; }

/* ---------------- Persistent launcher (translate pill) ---------------- */
#ert-launcher {
	position: fixed;
	z-index: 999998;
	bottom: 20px;
	right: 20px;
	display: none;
	align-items: center;
	gap: 7px;
	height: 40px;
	padding: 0 16px 0 13px;
	border-radius: 999px;
	background: var(--ert-accent);
	border: none;
	color: #04181d;
	font-weight: 700;
	font-size: 12.5px;
	letter-spacing: 0.02em;
	cursor: pointer;
	box-shadow: 0 6px 18px rgba(34,211,238,0.35), 0 2px 6px rgba(0,0,0,0.35);
	transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}
#ert-launcher.ert-show { display: flex; }
#ert-launcher:hover {
	transform: translateY(-1px);
	filter: brightness(1.08);
	box-shadow: 0 8px 22px rgba(34,211,238,0.45), 0 3px 8px rgba(0,0,0,0.4);
}
#ert-launcher .ert-launcher-icon {
	font-size: 15px;
	line-height: 1;
}

/* Neutralize Google's default translate banner + avoid layout jump */
body { top: 0 !important; }
.goog-te-banner-frame.skiptranslate { display: none !important; }
.goog-te-gadget { height: 0; overflow: hidden; }
#google_translate_element {
	position: absolute;
	top: -9999px;
	left: -9999px;
	height: 1px;
	width: 1px;
	overflow: hidden;
}
