/* nayad RTL patch sheet (DESIGN §4.3 item 6). Authored for RTL; never flipped. Loaded only in RTL mode. */

/* vueuc / naive-ui floating layer (selects, tooltips, date pickers): JS computes physical-left
   coordinates, so pin the content to the physical left. Verified live 2026-10-01. */
.v-binder-follower-content { left: 0 !important; right: auto !important; }

/* Opportunities kanban: the runtime mirrors the columns' inline translateX; don't animate that. */
.crm-opportunities-stages-container > * { transition: width 1s !important; }

/* Phone numbers, emails and URLs keep their own (LTR) direction inside RTL text. */
a[href^="tel:"], a[href^="mailto:"],
input[type="tel"], input[type="email"], input[type="url"] { unicode-bidi: plaintext; }

/* Text that is only a phone number or email (marked by the runtime): keep its own LTR order inside RTL
   text, aligned like its RTL surroundings. */
[data-rtl-ltr] { direction: ltr; unicode-bidi: isolate; text-align: right; }

/* One-time-code (OTP) boxes: digits are typed and pasted left to right, so the boxes keep LTR order
   (GHL's HighRise/UI OTP components and generic one-time-code inputs). */
[class*="input-otp__container"], [class*="input-otp__fields"], .otp-input, .login-otp-input,
.profile-email-otp-input, input[autocomplete="one-time-code"] { direction: ltr !important; }
/* The row that orders the boxes (login page: a flex row of per-digit wrappers around input.otp-input);
   LTR inputs inside an RTL row would still run right to left. */
:is(div, span):has(> input:is(.otp-input, .login-otp-input, .profile-email-otp-input, [autocomplete="one-time-code"])),
:is(div, span):has(> :is(div, span) > input:is(.otp-input, .login-otp-input, .profile-email-otp-input, [autocomplete="one-time-code"])) { direction: ltr !important; }

/* Bootstrap 4 dropdowns positioned by Popper.js (header profile menu "IL", …): Popper writes physical
   `left`/`transform` inline, but the flipped stylesheet also gives .dropdown-menu `right: 0`. With both
   set, an RTL box ignores `left`, so the menu stuck to its parent's right edge and opened off-screen.
   Let Popper's coordinates win. Verified live 2026-10-01. */
.dropdown-menu[x-placement], .dropdown-menu[style*="translate3d"] { right: auto !important; }
