/* Pajhwok 2026 — right-to-left (Dari, Pashto). Loaded after pajhwok.css and wp.css only when the
   page language is right-to-left; pajhwok.css itself is never changed. Every rule here mirrors a
   left/right rule of the design. */

/* Type: Naskh for reading; Arabic letters must not be spaced apart or upper-cased. */
body,.nav>a,.nav .grp>span,.btn,.tb,.chip,.tag,.tag2,.form input{font-family:Vazirmatn,Tahoma,system-ui,sans-serif}
h1,h2,h3,h4,.lead p,.fstory p,.body,.ahd .dek,.pj-archdesc,.pj-profile-bio,.ut b,.mapside .stat b{font-family:Vazirmatn,Tahoma,system-ui,sans-serif}
.k,.railhd h2,.sechd h2,.fgrid h4,.fgrid h2,.toc span,.trust h3,.pj-profile-facts dt,.body .is-style-pj-factbox h3,.mono,.lgrid a::before{letter-spacing:0;text-transform:none}
.live,.pj-ticker-k,.pj-lock,.gal .more small,.pj-rates thead th,.pj-weather thead th,.body .rcp_form legend,.body .rcp_header,.body .rcp-table th,.pj-find-g,.pj-ap{letter-spacing:0;text-transform:none}
/* No slanted (made-up italic) Arabic letters: the font has no italic. */
.op h3,.body blockquote,.body .wp-block-quote{font-style:normal}
h1,h2,h3,h4{letter-spacing:0;line-height:1.35}
.body{line-height:1.9}
.lead h2{line-height:1.3}

/* Header and menu */
.nav{mask:linear-gradient(270deg,#000 94%,transparent)}
.nav a[aria-current]::after,.nav .grp:hover>span::after{left:12px;right:12px}
.theme{padding:3px 10px 3px 4px}
.theme i::after{left:12px}
[data-theme="dark"] .theme i::after{left:2px}
.btn svg{transform:scaleX(-1)}
.ut{border-right:0;border-left:1px solid var(--line)}
.ut:first-child{padding-left:16px;padding-right:0}
.ut:last-child{border-left:0}
.ut.sp::before{right:auto;left:8px}
.pj-drawer details ul{padding:0 14px 8px 0}
.pj-drawer a,.pj-drawer summary{padding:14px 4px 14px 10px}

/* Ads */
.ad::before{right:auto;left:10px}
.pj-sticky-x{right:auto;left:4px}

/* Home */
.rail{border-left:0;padding-left:0;border-right:1px solid var(--line);padding-right:28px}
.tl::before{left:auto;right:6px}
.tl li{padding:0 22px 18px 0}
.tl li::before{left:auto;right:0}
.st span{line-height:1.4}
.poll .opt i{left:auto;right:0}
.dur{right:auto;left:14px}
.short .dur{left:auto;right:10px}
.wave{background:linear-gradient(270deg,#fff 0 38%,rgba(255,255,255,.3) 38%)}
.player2 .wave{background:linear-gradient(270deg,#fff 0 var(--p),rgba(255,255,255,.3) var(--p))}
.player3 .wave{background:linear-gradient(270deg,var(--navy) 0 30%,rgba(28,63,143,.3) 30%)}
.op{padding:28px 0 28px 24px;margin-right:0;margin-left:24px;border-right:0;border-left:1px solid var(--line)}
.thread .tl{padding:0 18px 0 0}
.thread .tl::before{left:auto;right:5px}
.thread .tl li::before{left:auto;right:-18px}
.photo .pic::after{background:linear-gradient(270deg,rgba(8,14,32,.85) 0,rgba(8,14,32,.4) 45%,transparent 70%)}
.photo .t{left:auto;right:0}
.photo .lic{right:auto;left:20px}
.mapbox .pres{right:auto;left:16px}
.pvlist a .mono{text-align:left}
.lgrid a::before{padding-top:5px}
/* Numbered lists in Persian digits, like the dates: More news (۰۱, ۰۲ …), the Morning brief and Most read (۱, ۲ …). */
@counter-style pj-fa-lz{system:extends persian;pad:2 "۰"}
.lgrid a::before{content:counter(n,pj-fa-lz)}
.bcard li::before{content:counter(b,persian)}
.mostr a::before{content:counter(m,persian)}

/* Story page */
.rp{left:auto;right:0}
.toc{border-left:0;padding-left:0;border-right:2px solid var(--line);padding-right:14px}
.toc a.on::before{left:auto;right:-16px}
.body .dc::first-letter{float:right;padding:6px 0 0 10px}
.body blockquote,.body .wp-block-quote{padding:0 24px 0 0;border-left:0;border-right:3px solid var(--navy)}
.body ul,.body ol{padding-left:0;padding-right:1.2em}
.body .is-style-pj-factbox ul{padding-left:0;padding-right:1.1em}
.body .pj-correction{border-left:0;border-right:3px solid var(--red);border-radius:8px 0 0 8px}
.body .is-style-pj-timeline{padding:0 22px 0 0}
.body .is-style-pj-timeline::before{left:auto;right:4px}
.body .is-style-pj-timeline li::before{left:auto;right:-22px}
.trust dl{grid-template-columns:110px 1fr}

@media (max-width:1100px){.rail{border-right:0;padding-right:0}}
@media (max-width:760px){.op{margin-left:0;border-left:0}}

/* Latin dates inside right-to-left text keep their own order ("20 Jul 2026", not "Jul 2026 20"). */
[dir=rtl] time,[dir=rtl] .mono{unicode-bidi:plaintext}
/* A date line holds only its <time> (isolated, so it would count as left-to-right and sit on the left): it starts on
   the right, under its headline (1.1.2: Hijri dates in Persian digits). */
[dir=rtl] .mono:has(> time){text-align:right}
[dir=rtl] .ad::before,[dir=rtl] .ut.sp::before{letter-spacing:0}

/* Audit fixes (v1.3) */
.mapbox svg{direction:ltr}
[dir=rtl] .body .dc::first-letter{font-size:inherit;float:none;padding:0;margin:0;color:inherit;font-weight:inherit;line-height:inherit}
.ut .k,.st span,.mapbox text{font-size:12.5px}
.mono,.k{font-size:max(12.5px,1em)}
@media (max-width:1100px){.ut:nth-child(3){border-left:0}}
@media (max-width:760px){.ut:nth-child(3){border-left:1px solid var(--line);border-right:0}.ut:nth-child(2n){border-left:0}}
/* Very small phones: the same compact top bar and tiles as in English (wp.css). */
@media (max-width:420px){.theme{padding:3px}.ut:first-child{padding-left:10px;padding-right:10px}}
/* 1.1.0: the Shorts row title and the More menu's group names (spaced-out capitals in English). */
.pj-rowtitle,.pj-more .pj-more-h{letter-spacing:0;text-transform:none}
/* The sponsored story card's "Ad" label: on the left in right-to-left (the design puts it right). */
.row4 .card.spon .ad::before{right:auto;left:12px}
/* Headlines (1.1.2): Dari and Pashto letters reach higher and lower than English ones, so big headlines need more room
   between their lines than the English 1.05. */
[dir=rtl] .ahd h1{line-height:1.42}
[dir=rtl] .pj-archhd h1,[dir=rtl] .pj-profile h1{line-height:1.35}
[dir=rtl] .rep h3{line-height:1.55}
[dir=rtl] .pj-cine .lead.pj-tile h2,[dir=rtl] .pj-cine-photo .photo h3{line-height:1.32}
[dir=rtl] .pj-cine .card.pj-tile h3{line-height:1.42}
/* The story's date line under the centred headline stays centred when it wraps on a phone. */
[dir=rtl] .ahd .mono:has(> time){text-align:center}
/* News column story pages: the date line under the headline starts at the right, like the headline. */
[dir=rtl] .art.pj-col>.ahd .mono:has(> time){text-align:right}
/* Headline underline under the mouse: lower, clear of the dots below the letters. */
[dir=rtl] a:is(:hover,:focus-visible) :is(h2,h3,h4,.pj-hl),[dir=rtl] :is(h2,h3,h4)>a:is(:hover,:focus-visible){text-underline-offset:.32em}
/* Compact headlines in Dari and Pashto: the same sizes, with room between the lines. */
[dir=rtl] .pj-compact :is(.lead h2,.card h3,.fstory h3,.photo h3){line-height:1.5}
[dir=rtl] .pj-compact .ahd h1,[dir=rtl] .pj-compact .art.pj-col>.ahd h1{font-size:clamp(26px,2.9vw,38px);line-height:1.5}
/* The video list's titles: Dari and Pashto lines a little apart, as on staging (1.1.3). */
.pj-vside .vlist h3{line-height:1.6}
/* Widgets (1.1.3): Dari and Pashto letters in every part; no slanted or spaced-apart Arabic letters. */
.pj-w{--pj-ui:Vazirmatn,Tahoma,system-ui,sans-serif;--pj-serif:Vazirmatn,Tahoma,system-ui,sans-serif}
.pj-w-more svg{transform:scaleX(-1)}
.pj-w-more:hover svg{transform:scaleX(-1) translateX(3px)}
.pj-wop h3{font-style:normal;line-height:1.55}
.pj-wd-wd,.pj-wr thead th,.pj-wp li i,.pj-wz-pj-footer .pj-w-hd h2{letter-spacing:0;text-transform:none}
.pj-wtl h3,.pj-wrows h3,.pj-wps h3{line-height:1.6}
.pj-wlead h3,.pj-wv-main h3,.pj-wps-big h3{line-height:1.5}
.pj-wd-big>b,.pj-ww-t{letter-spacing:0}
/* Mega menus (1.1.3): Dari and Pashto letters. */
.pj-mega-h,.pj-mega-story b{font-family:Vazirmatn,Tahoma,system-ui,sans-serif}
.pj-mega-story b{line-height:1.6}
/* Province map panel (1.1.3): Dari and Pashto letters. */
.pj-pvp-list h4{font-family:Vazirmatn,Tahoma,system-ui,sans-serif;line-height:1.6}
.pj-pvp-hd h3{line-height:1.4}
/* Map layers and the full-screen stories (1.1.3): Dari and Pashto letters; the stories' bars fill from the right. */
.pj-lysw button,.pj-lylg,.mapbox .wxt,.mapbox .rlb,.pj-rdst,.pj-stv-txt .k,.pj-stv-read{font-family:Vazirmatn,Tahoma,system-ui,sans-serif;letter-spacing:0}
.pj-stv-txt h2{font-family:Vazirmatn,Tahoma,system-ui,sans-serif;line-height:1.55;font-size:clamp(20px,5.4vw,25px)}
.pj-stv-txt p{line-height:1.8}
.pj-stv-bars i{transform-origin:right}
.mapbox .wxn,.pj-wxp-now b{font-family:Vazirmatn,Tahoma,system-ui,sans-serif}
.pj-lylg-wx{direction:ltr} /* Cold on the left, as the bar and the map (never turned round). */
.pj-wxp-now b{font-size:40px}
/* Rows of lists (1.1.3): Dari and Pashto headlines with room between their lines; the play sign stays in the
   picture's bottom-left corner, as on staging. */
.pj-row h3{line-height:1.6}
.pj-row p{line-height:1.85}
[dir=rtl] .play.pj-vb b::after{margin:0 0 0 3px}
.play.pj-vb~.dur{left:auto;right:12px} /* The video's length on the other side from the play sign (bottom-left). */
.pj-intv h3,.pj-intvtop h3,.pj-archvid .vinfo h3{line-height:1.6}
[dir=rtl] :is(.pj-feat2,.pj-feat3) .fstory h3{line-height:1.6}
.pj-aldl,.mapbox :is(.alt,.alm,.alp),.pj-alnote,.pj-alsrc{font-family:Vazirmatn,Tahoma,system-ui,sans-serif;letter-spacing:0}
[dir=rtl] .pj-aldl{padding:6px 11px 6px 8px}
.pj-aldlm,.pj-aldlm .pj-aldlgo,.pj-aldlm textarea{font-family:Vazirmatn,Tahoma,system-ui,sans-serif;letter-spacing:0}
[dir=rtl] .pj-phhero-tx h1{line-height:1.35}
[dir=rtl] .pj-phset-tx h3{line-height:1.6}
