/**
 * FitsAura — right-to-left overrides (Arabic).
 *
 * Most of the theme uses logical properties, so this file only mirrors the
 * deliberately physical rules: drawers, flyout submenus, directional icons
 * and Arabic typography adjustments.
 */

html[dir="rtl"] body {
	direction: rtl;
	text-align: right;
}

/* Arabic script must not be letter-spaced: it breaks the joins. */
html[dir="rtl"] .fa-eyebrow,
html[dir="rtl"] .fa-btn,
html[dir="rtl"] .fa-link-arrow,
html[dir="rtl"] .fa-topbar,
html[dir="rtl"] .fa-nav__link,
html[dir="rtl"] .fa-nav__sublink,
html[dir="rtl"] .fa-lang__toggle,
html[dir="rtl"] .fa-breadcrumb,
html[dir="rtl"] .fa-badge,
html[dir="rtl"] .fa-product-card__brand,
html[dir="rtl"] .fa-section-head__title,
html[dir="rtl"] .fa-section-head__text,
html[dir="rtl"] .fa-footer,
html[dir="rtl"] .fa-footer__title,
html[dir="rtl"] .fa-form-field label,
html[dir="rtl"] .fa-form-field__label,
html[dir="rtl"] .fa-newsletter-form,
html[dir="rtl"] .fa-search__label,
html[dir="rtl"] .fa-search__all,
html[dir="rtl"] .fa-product-card__action,
html[dir="rtl"] .fa-shop__results,
html[dir="rtl"] .fa-pdp__trust,
html[dir="rtl"] .fa-pdp__concierge,
html[dir="rtl"] .fa-post-meta,
html[dir="rtl"] .fa-page-hero__text,
html[dir="rtl"] .fa-page-hero .fa-eyebrow,
html[dir="rtl"] .fa-blog__layout .fa-eyebrow,
html[dir="rtl"] .fa-pagination,
html[dir="rtl"] .fa-chip,
html[dir="rtl"] .fa-cat-card__cta,
html[dir="rtl"] .comment-form label,
html[dir="rtl"] .woocommerce a.button,
html[dir="rtl"] .woocommerce button.button,
html[dir="rtl"] .woocommerce input.button,
html[dir="rtl"] .woocommerce #place_order,
html[dir="rtl"] .woocommerce table.shop_table th,
html[dir="rtl"] .woocommerce-order ul.woocommerce-thankyou-order-details li,
html[dir="rtl"] .woocommerce-order ul.woocommerce-order-overview li,
html[dir="rtl"] .woocommerce form .form-row label,
html[dir="rtl"] .woocommerce-account .woocommerce-MyAccount-navigation li a,
html[dir="rtl"] .woocommerce div.product .woocommerce-tabs ul.tabs li a,
html[dir="rtl"] .woocommerce .widget_price_filter .price_slider_amount,
html[dir="rtl"] .fa-drawer__title,
html[dir="rtl"] .fa-drawer__count,
html[dir="rtl"] .fa-quickview__more {
	letter-spacing: 0;
}

html[dir="rtl"] h1,
html[dir="rtl"] h2,
html[dir="rtl"] h3,
html[dir="rtl"] h4,
html[dir="rtl"] h5,
html[dir="rtl"] h6 {
	letter-spacing: 0;
}

/* Latin brand names and codes keep their tracking. */
html[dir="rtl"] .fa-logo__name,
html[dir="rtl"] [dir="ltr"] {
	letter-spacing: inherit;
	direction: ltr;
}

/* Directional icons ------------------------------------------------------ */

html[dir="rtl"] .fa-icon--arrow-right,
html[dir="rtl"] .fa-icon--arrow-left,
html[dir="rtl"] .fa-icon--chevron-right,
html[dir="rtl"] .fa-icon--chevron-left {
	transform: scaleX(-1);
}

html[dir="rtl"] .fa-btn:hover svg,
html[dir="rtl"] .fa-link-arrow:hover svg,
html[dir="rtl"] .fa-cat-card:hover .fa-cat-card__cta svg {
	transform: translateX(-4px);
}

html[dir="rtl"] .fa-btn:hover svg.fa-icon--arrow-right,
html[dir="rtl"] .fa-btn:hover svg.fa-icon--arrow-left,
html[dir="rtl"] .fa-link-arrow:hover svg.fa-icon--arrow-right,
html[dir="rtl"] .fa-link-arrow:hover svg.fa-icon--arrow-left,
html[dir="rtl"] .fa-cat-card:hover .fa-cat-card__cta svg.fa-icon--arrow-right {
	transform: scaleX(-1) translateX(4px);
}

html[dir="rtl"] .fa-pdp__concierge:hover svg:last-child {
	transform: scaleX(-1) translateX(3px);
}

/* Navigation ------------------------------------------------------------- */

html[dir="rtl"] .fa-submenu {
	text-align: right;
}

html[dir="rtl"] .fa-nav__item:hover > .fa-submenu,
html[dir="rtl"] .fa-nav__item:focus-within > .fa-submenu {
	transform: translate(50%, 0);
}

html[dir="rtl"] .fa-submenu .fa-submenu {
	transform: translate(-8px, 0);
}

html[dir="rtl"] .fa-nav__subitem:hover > .fa-submenu,
html[dir="rtl"] .fa-nav__subitem:focus-within > .fa-submenu {
	transform: translate(0, 0);
}

/* Drawers keep their physical edge, so they slide fully off-canvas when closed. */
html[dir="rtl"] .fa-drawer__panel {
	text-align: right;
}

html[dir="rtl"] .fa-mobile-nav .fa-nav__link,
html[dir="rtl"] .fa-mobile-nav .fa-nav__sublink {
	text-align: right;
}

html[dir="rtl"] .fa-mobile-nav .fa-submenu {
	padding: 0 0.9rem 0.6rem 0;
}

/* Hero ------------------------------------------------------------------- */

html[dir="rtl"] .fa-hero__content {
	text-align: right;
}

html[dir="rtl"] .fa-hero__content--center {
	text-align: center;
}

html[dir="rtl"] .fa-hero__content--right {
	text-align: left;
}

html[dir="rtl"] .fa-hero__actions,
html[dir="rtl"] .fa-hero__eyebrow {
	justify-content: flex-start;
}

html[dir="rtl"] .fa-hero__content--center .fa-hero__actions,
html[dir="rtl"] .fa-hero__content--center .fa-eyebrow {
	justify-content: center;
}

/* Cards and sections ----------------------------------------------------- */

html[dir="rtl"] .fa-product-card__body {
	text-align: right;
}

html[dir="rtl"] .fa-cat-card__body {
	text-align: right;
}

html[dir="rtl"] .fa-edit-card {
	text-align: right;
}

html[dir="rtl"] .fa-reviews__card,
html[dir="rtl"] .fa-journal__card,
html[dir="rtl"] .fa-post-card,
html[dir="rtl"] .fa-widget {
	text-align: right;
}

html[dir="rtl"] .fa-usp__item {
	text-align: right;
}

html[dir="rtl"] .fa-promise__body,
html[dir="rtl"] .fa-newsletter__inner,
html[dir="rtl"] .fa-news__inner {
	text-align: right;
}

html[dir="rtl"] .fa-footer__col,
html[dir="rtl"] .fa-footer__brand,
html[dir="rtl"] .fa-footer__bottom {
	text-align: right;
}

/* Search overlay --------------------------------------------------------- */

html[dir="rtl"] .fa-search__form input {
	text-align: right;
}

html[dir="rtl"] .fa-search-result__body {
	text-align: right;
}

/* Blog / prose ----------------------------------------------------------- */

html[dir="rtl"] .fa-single__header,
html[dir="rtl"] .fa-single__meta,
html[dir="rtl"] .fa-author-box,
html[dir="rtl"] .fa-comment,
html[dir="rtl"] .fa-page__body {
	text-align: right;
}

html[dir="rtl"] .fa-prose ul,
html[dir="rtl"] .fa-prose ol {
	padding-inline-start: 1.5rem;
	padding-inline-end: 0;
}

html[dir="rtl"] .fa-prose blockquote {
	border-inline-start: 2px solid var(--fa-accent);
	border-inline-end: 0;
}

/* Forms ------------------------------------------------------------------ */

html[dir="rtl"] input[type="text"],
html[dir="rtl"] input[type="email"],
html[dir="rtl"] input[type="tel"],
html[dir="rtl"] input[type="search"],
html[dir="rtl"] input[type="password"],
html[dir="rtl"] input[type="url"],
html[dir="rtl"] input[type="number"],
html[dir="rtl"] textarea,
html[dir="rtl"] select {
	text-align: right;
}

html[dir="rtl"] .fa-searchform button {
	right: auto;
	left: 0;
}

/* WooCommerce ------------------------------------------------------------ */

@media (max-width: 1024px) {
	html[dir="rtl"] .fa-shop__sidebar {
		transform: translateX(102%);
	}

	html[dir="rtl"] .fa-shop__sidebar.is-open {
		transform: translateX(0);
	}
}

html[dir="rtl"] .woocommerce div.product div.images .woocommerce-product-gallery__trigger {
	right: auto;
	left: 1rem;
}

/* Flexslider's RTL layout pushes the 400% track off the left edge. */
html[dir="rtl"] .woocommerce-product-gallery .flex-viewport {
	direction: ltr;
}

html[dir="rtl"] .woocommerce div.product .onsale {
	left: auto;
	right: 1rem;
}

html[dir="rtl"] .woocommerce div.product .woocommerce-tabs .panel,
html[dir="rtl"] .woocommerce #reviews,
html[dir="rtl"] .woocommerce .woocommerce-product-details__short-description,
html[dir="rtl"] .fa-pdp__editor-note,
html[dir="rtl"] .fa-pdp__note {
	text-align: right;
}

html[dir="rtl"] .woocommerce div.product .woocommerce-tabs ul.tabs li a::after {
	transform-origin: 100% 50%;
}

html[dir="rtl"] .woocommerce table.shop_attributes th,
html[dir="rtl"] .woocommerce table.shop_attributes td {
	text-align: right;
	padding: 0.85rem 0 0.85rem 1rem;
}

html[dir="rtl"] .woocommerce .star-rating::before,
html[dir="rtl"] .woocommerce .star-rating span,
html[dir="rtl"] .woocommerce .star-rating span::before {
	right: 0;
	left: auto;
}

html[dir="rtl"] .woocommerce #review_form p.stars a {
	direction: ltr;
}

html[dir="rtl"] .woocommerce form .form-row .select2-selection__rendered {
	text-align: right;
}

html[dir="rtl"] .woocommerce table.cart td.actions .coupon {
	float: right;
}

html[dir="rtl"] .woocommerce table.cart td.actions > .button {
	float: left;
}

html[dir="rtl"] .woocommerce .cart-collaterals {
	justify-content: flex-start;
}

html[dir="rtl"] .woocommerce table.shop_table th,
html[dir="rtl"] .woocommerce table.shop_table td {
	text-align: right;
}

html[dir="rtl"] .woocommerce .cart-collaterals .cart_totals table td {
	text-align: left;
}

html[dir="rtl"] .woocommerce-checkout #order_review .shop_table td {
	text-align: left;
}

html[dir="rtl"] .woocommerce-checkout #order_review .shop_table .product-name {
	text-align: right;
}

html[dir="rtl"] .woocommerce-account .woocommerce-MyAccount-navigation li.is-active a {
	border-left: 0;
	border-right: 2px solid var(--fa-accent);
	padding-right: 0.75rem;
	padding-left: 0;
}

html[dir="rtl"] .woocommerce table.shop_table_responsive tr td {
	text-align: left;
}

html[dir="rtl"] .woocommerce table.shop_table_responsive tr td::before {
	float: right;
}

html[dir="rtl"] .woocommerce table.shop_table_responsive tr td.product-thumbnail {
	text-align: right;
}

html[dir="rtl"] .woocommerce table.shop_table_responsive tr td.product-remove {
	right: auto;
	left: 0;
}

/* Keep numeric cells and prices LTR for clarity. */
html[dir="rtl"] .woocommerce .amount,
html[dir="rtl"] .woocommerce .woocommerce-Price-amount,
html[dir="rtl"] .fa-price,
html[dir="rtl"] .fa-pdp__price,
html[dir="rtl"] .fa-product-card__price {
	direction: ltr;
	unicode-bidi: isolate;
}

/* Pagination arrows */
html[dir="rtl"] .fa-pagination .page-numbers svg,
html[dir="rtl"] .woocommerce nav.woocommerce-pagination .page-numbers svg {
	transform: scaleX(-1);
}
