/*
 * Pojo Accessibility — custom layer
 * Hides the original toggle button; provides a floating round button + close button.
 * Dimensions and color inherit from the site's bottom-nav CSS variables.
 */

/* ── Hide the original plugin toggle button ──────────────────────────────── */
.pojo-a11y-toolbar-toggle {
	display: none !important;
}

/* ── Floating round button ───────────────────────────────────────────────── */
.pojo-a11y-float-btn {
	position: fixed;
	bottom: var(--prilinq-nav-offset-bottom, 34px);
	left: var(--prilinq-nav-side-margin, 16px);
	z-index: 99999;
	width: var(--prilinq-nav-home-height, 44px);
	height: var(--prilinq-nav-home-height, 44px);
	border-radius: 50%;
	background-color: var(--prilinq-nav-bg, #1e293b);
	color: var(--prilinq-nav-text, #ffffff);
	border: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: transform 0.15s ease;
	padding: 0;
}

.pojo-a11y-float-btn:hover,
.pojo-a11y-float-btn:focus {
	transform: scale(1.05);
}

.pojo-a11y-float-btn svg {
	width: 22px;
	height: 22px;
	fill: currentColor;
	pointer-events: none;
}

/* ── Close (×) button inside toolbar ────────────────────────────────────── */
.pojo-a11y-toolbar-close {
	background: none;
	border: none;
	cursor: pointer;
	font-size: 22px;
	line-height: 1;
	padding: 2px 6px;
	color: inherit;
	opacity: 0.75;
	border-radius: 4px;
	transition: opacity 0.15s ease;
}

.pojo-a11y-toolbar-close:hover,
.pojo-a11y-toolbar-close:focus {
	opacity: 1;
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

/* Toolbar title row — flex so close button sits at the end */
.pojo-a11y-toolbar .pojo-a11y-toolbar-title {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

/* RTL: close button on the left */
html[dir="rtl"] .pojo-a11y-toolbar .pojo-a11y-toolbar-title,
body.rtl .pojo-a11y-toolbar .pojo-a11y-toolbar-title {
	flex-direction: row-reverse;
}

/* LTR: close button on the right (default row is fine) */
html[dir="ltr"] .pojo-a11y-toolbar .pojo-a11y-toolbar-title,
body.ltr .pojo-a11y-toolbar .pojo-a11y-toolbar-title {
	flex-direction: row;
}

/* ── Mobile (≤ 950px) — match the nav toggle pill height (48px) ─────────── */
@media (max-width: 950px) {
	.pojo-a11y-float-btn {
		width: 48px;
		height: 48px;
	}

	.pojo-a11y-float-btn svg {
		width: 20px;
		height: 20px;
	}
}
