/* OK Safe Space v71: Free chat Arabic/RTL CSS module.
   Split from chat-mobile-qa.css v70.
   Load order: after chat-base.css so Arabic mobile header fixes can override base/mobile rules.
   Scope: Arabic/RTL Free chat header and mobile direction fixes only. */

/* v68: Arabic mobile header polish after phone QA.
   Keep Free chat on the first header line and move the Arabic private-chat hint to the second line.
   Scope: Free chat modal on mobile only; no backend or chat logic change. */
@media (max-width:760px){
  html[lang="ar"] #chatModal.chat-mobile-qa-v68 .chat-modal-titleline,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v68 .chat-modal-titleline,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v68 .chat-modal-titleline,
  body.is-rtl #chatModal.chat-mobile-qa-v68 .chat-modal-titleline,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v68 .chat-modal-titleline,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v68 .chat-modal-titleline{
    display:flex !important;
    flex-direction:column !important;
    flex-wrap:nowrap !important;
    align-items:flex-end !important;
    justify-content:flex-start !important;
    row-gap:3px !important;
    column-gap:0 !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    text-align:right !important;
    direction:rtl !important;
    white-space:normal !important;
    overflow:visible !important;
  }

  html[lang="ar"] #chatModal.chat-mobile-qa-v68 #chatModalTitle,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v68 #chatModalTitle,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v68 #chatModalTitle,
  body.is-rtl #chatModal.chat-mobile-qa-v68 #chatModalTitle,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v68 #chatModalTitle,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v68 #chatModalTitle{
    order:1 !important;
    flex:0 0 auto !important;
    width:100% !important;
    max-width:100% !important;
    margin:0 !important;
    text-align:right !important;
    direction:ltr !important;
    unicode-bidi:isolate !important;
    white-space:nowrap !important;
  }

  html[lang="ar"] #chatModal.chat-mobile-qa-v68 #chatPrivateHint,
  html[lang="ar"] #chatModal.chat-mobile-qa-v68 .chat-private-hint,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v68 #chatPrivateHint,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v68 .chat-private-hint,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v68 #chatPrivateHint,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v68 .chat-private-hint,
  body.is-rtl #chatModal.chat-mobile-qa-v68 #chatPrivateHint,
  body.is-rtl #chatModal.chat-mobile-qa-v68 .chat-private-hint,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v68 #chatPrivateHint,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v68 .chat-private-hint,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v68 #chatPrivateHint,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v68 .chat-private-hint{
    order:2 !important;
    display:block !important;
    flex:0 0 auto !important;
    width:100% !important;
    max-width:100% !important;
    margin:0 !important;
    padding:0 !important;
    text-align:right !important;
    direction:rtl !important;
    unicode-bidi:plaintext !important;
    white-space:normal !important;
    overflow:visible !important;
    font-size:11px !important;
    line-height:1.3 !important;
  }
}

/* v69: Arabic mobile chat header one-line brand + title.
   Keep "OK Safe Space" and "Free chat" on the same first line, with the Arabic private-chat hint on line two.
   Scope: mobile + Arabic Free chat modal only; no chat logic/backend change. */
@media (max-width:760px){
  html[lang="ar"] #chatModal.chat-mobile-qa-v69 .chat-modal-titlewrap,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-titlewrap,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-titlewrap,
  body.is-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-titlewrap,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-titlewrap,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v69 .chat-modal-titlewrap{
    flex:1 1 auto !important;
    min-width:0 !important;
    width:auto !important;
    max-width:100% !important;
    overflow:visible !important;
    text-align:right !important;
  }

  html[lang="ar"] #chatModal.chat-mobile-qa-v69 .chat-modal-titleline,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-titleline,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-titleline,
  body.is-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-titleline,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-titleline,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v69 .chat-modal-titleline{
    display:flex !important;
    flex-direction:row !important;
    flex-wrap:wrap !important;
    align-items:baseline !important;
    justify-content:flex-end !important;
    column-gap:8px !important;
    row-gap:3px !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    text-align:right !important;
    direction:ltr !important;
    white-space:normal !important;
    overflow:visible !important;
  }

  html[lang="ar"] #chatModal.chat-mobile-qa-v69 .chat-modal-head .modal-kicker,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-head .modal-kicker,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-head .modal-kicker,
  body.is-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-head .modal-kicker,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-head .modal-kicker,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v69 .chat-modal-head .modal-kicker{
    order:1 !important;
    display:inline-flex !important;
    flex:0 1 auto !important;
    width:auto !important;
    max-width:calc(100% - 104px) !important;
    margin:0 !important;
    padding:0 !important;
    font-size:14px !important;
    line-height:1.08 !important;
    letter-spacing:.08em !important;
    white-space:nowrap !important;
    text-align:left !important;
    direction:ltr !important;
    unicode-bidi:isolate !important;
  }

  html[lang="ar"] #chatModal.chat-mobile-qa-v69 #chatModalTitle,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v69 #chatModalTitle,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v69 #chatModalTitle,
  body.is-rtl #chatModal.chat-mobile-qa-v69 #chatModalTitle,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v69 #chatModalTitle,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v69 #chatModalTitle{
    order:2 !important;
    display:inline-flex !important;
    flex:0 0 auto !important;
    width:auto !important;
    max-width:none !important;
    margin:0 !important;
    padding:0 !important;
    font-size:24px !important;
    line-height:1.08 !important;
    white-space:nowrap !important;
    text-align:left !important;
    direction:ltr !important;
    unicode-bidi:isolate !important;
  }

  html[lang="ar"] #chatModal.chat-mobile-qa-v69 #chatPrivateHint,
  html[lang="ar"] #chatModal.chat-mobile-qa-v69 .chat-private-hint,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v69 #chatPrivateHint,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-private-hint,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v69 #chatPrivateHint,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-private-hint,
  body.is-rtl #chatModal.chat-mobile-qa-v69 #chatPrivateHint,
  body.is-rtl #chatModal.chat-mobile-qa-v69 .chat-private-hint,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v69 #chatPrivateHint,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v69 .chat-private-hint,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v69 #chatPrivateHint,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v69 .chat-private-hint{
    order:3 !important;
    display:block !important;
    flex:0 0 100% !important;
    width:100% !important;
    max-width:100% !important;
    margin:2px 0 0 !important;
    padding:0 !important;
    text-align:right !important;
    direction:rtl !important;
    unicode-bidi:plaintext !important;
    white-space:normal !important;
    overflow:visible !important;
    font-size:11px !important;
    line-height:1.3 !important;
  }

  html[lang="ar"] #chatModal.chat-mobile-qa-v69 .chat-modal-titleline::after,
  html[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-titleline::after,
  body[dir="rtl"] #chatModal.chat-mobile-qa-v69 .chat-modal-titleline::after,
  body.is-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-titleline::after,
  body.is-chat-rtl #chatModal.chat-mobile-qa-v69 .chat-modal-titleline::after,
  body.is-arabic-mobile-chat-fix #chatModal.chat-mobile-qa-v69 .chat-modal-titleline::after{
    content:none !important;
    display:none !important;
  }
}
