/**
 * Right-to-left corrections for the plugin's own controls.
 *
 * Scoped to .ozytr- classes throughout. Flipping a theme's own layout is not
 * this plugin's business, and a stylesheet that tried would break more
 * sites than it fixed.
 */

.ozytr-rtl .ozytr-switcher,
.ozytr-rtl .ozytr-switcher * {
	direction: rtl;
	text-align: right;
}

.ozytr-rtl .ozytr-switcher__list {
	padding-right: 0;
}

.ozytr-rtl .ozytr-switcher__toggle {
	flex-direction: row-reverse;
}

.ozytr-rtl .ozytr-switcher__caret {
	margin-right: 8px;
	margin-left: 0;
}

.ozytr-rtl .ozytr-flag {
	margin-left: 8px;
	margin-right: 0;
}

.ozytr-rtl .ozytr-switcher__dropdown,
.ozytr-rtl .ozytr-switcher__panel {
	right: 0;
	left: auto;
}

.ozytr-rtl .ozytr-switcher--align-left {
	justify-content: flex-end;
}

.ozytr-rtl .ozytr-switcher--align-right {
	justify-content: flex-start;
}

.ozytr-rtl .ozytr-switcher__search {
	padding-right: 32px;
	padding-left: 8px;
	background-position: right 8px center;
}

.ozytr-rtl .ozytr-fab {
	right: auto;
	left: 24px;
}

.ozytr-rtl .ozytr-sidebar {
	right: auto;
	left: 0;
	transform: translateX(-100%);
}

.ozytr-rtl .ozytr-sidebar.is-open {
	transform: translateX(0);
}

.ozytr-rtl .ozytr-modal__close {
	right: auto;
	left: 16px;
}

.ozytr-rtl .ozytr-suggestion {
	direction: rtl;
	text-align: right;
}

.ozytr-rtl .ozytr-suggestion__actions {
	flex-direction: row-reverse;
}

/* Numbers, codes and URLs stay left-to-right inside right-to-left text,
   otherwise a language code such as pt-BR renders reversed. */
.ozytr-rtl .ozytr-lang-code,
.ozytr-rtl code,
.ozytr-rtl .ozytr-switcher__code {
	direction: ltr;
	unicode-bidi: embed;
	display: inline-block;
}
