/* BTS - right-to-left (Arabic) overrides. Loaded after app.css / doc.css when the interface language is Arabic. */
:root { --font: "Segoe UI", Tahoma, "Noto Naskh Arabic", "Geeza Pro", "Arabic Typesetting", system-ui, -apple-system, sans-serif; }
body { font-size: 15px; line-height: 1.65; }

/* Arabic letters must stay connected */
h6, th, .stat .l, .perm-mod h4, .checks .grp, .brand b, .nav h6 { letter-spacing: 0 !important; text-transform: none !important; }

/* technical values stay left-to-right and are isolated from the surrounding Arabic text */
code, .mono, .secret, .codes, pre, input[type=email], input[type=url], input[type=password], input[name=username], input[name=email], input[name=code], input[name=smtp_host] { direction: ltr; unicode-bidi: isolate; }
input[type=email], input[type=url], input[type=password], input[name=username], input[name=email] { text-align: right; }
/* block-level technical values (e.g. bill number in detail lists) align with the other RTL fields */
dd.mono, td.mono, dd.ltr, td.ltr { text-align: right; }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }

/* layout chrome */
.nav a.active { box-shadow: inset -3px 0 0 var(--gold); }
.topbar .qs input { padding: 8px 34px 8px 12px; }
.topbar .qs:before { left: auto; right: 12px; }
.iconbtn .dot { right: auto; left: -4px; }
.chip { margin: 1px 0 1px 2px; }
.tabs .cnt { margin-left: 0; margin-right: 4px; }
table.t th { text-align: right; }
.hbars .r .v { text-align: left; }
ul.errs { margin: 6px 18px 0 0; }
.callout { border-left: 0; border-right: 4px solid var(--gold); }
.callout.bad { border-right-color: var(--bad); } .callout.ok { border-right-color: var(--ok); }
.timeline { padding: 0 18px 0 0; border-left: 0; border-right: 2px solid var(--line); }
.timeline li { padding: 0 16px 16px 0; }
.timeline li:before { left: auto; right: -25px; }
ul.reqs li { padding: 3px 24px 3px 0; }
ul.reqs li:before { left: auto; right: 2px; }
#idlebar button { margin-left: 0; margin-right: 12px; }
.pager .pg a { direction: rtl; }
.ev .tm { direction: ltr; text-align: right; }
.step .lbl { text-align: start; }
@media print { body { font-size: 12pt; } }

/* editor */
.ed-toast { inset-inline-start: auto; left: 50%; }
.ed-toolbar { direction: rtl; }
.ed-find input { direction: ltr; }
.ed-paper { text-align: start; }
.cmp-view .blk.mod.h1 { text-align: center; }
.thr .rp { direction: rtl; }
.doc-body, .doc-preview { font-family: "Traditional Arabic", "Sakkal Majalla", "Noto Naskh Arabic", "Segoe UI", Tahoma, serif; }
.doc-body[dir=ltr], .doc-preview[dir=ltr] { font-family: "Times New Roman", "Segoe UI", serif; }
