@charset "utf-8";
/* CSS Document */

/* Chat bubble content */
.chatmytext {
    border: 0;
    padding: 10px;
    background: whitesmoke;
}

.chattext {
    width: 75%;
    display: flex;
    flex-direction: column;
}

.chattext > p:first-of-type {
    width: 100%;
    margin-top: 0;
    margin-bottom: auto;
    line-height: 13px;
    font-size: 12px;
}

/* Timestamp / meta line */
.chattext > p:last-of-type {
    width: 100%;
    text-align: right;
    color: silver;
    margin-bottom: -7px;
    margin-top: auto;
}



/* Default LTR fallback (optional) */
.chattext-l {
    float: left;
    padding-right: 10px;
}

.chattext-r {
    float: right;
    padding-left: 10px;
}

/* ================================
   DEFAULT (no lang) + PERSIAN → RTL
   ================================ */
html:not([lang]) .chattext-l,
html[lang="fa"] .chattext-l,
html[lang="fa-IR"] .chattext-l {
    float: right;
    padding-left: 10px;
    direction: rtl;
    text-align: right;
}

html:not([lang]) .chattext-r,
html[lang="fa"] .chattext-r,
html[lang="fa-IR"] .chattext-r {
    float: left;
    padding-right: 10px;
    direction: rtl;
    text-align: right;
}

/* ================================
   ENGLISH → LTR
   ================================ */
html[lang="en"] .chattext-l {
    float: left;
    padding-right: 10px;
    direction: ltr;
    text-align: left;
}

html[lang="en"] .chattext-r {
    float: right;
    padding-left: 10px;
    direction: ltr;
    text-align: left;
}







/* Avatar & message containers */
.chatavatar {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 25%;
    float: left;
    padding-right: 10px;
}

.macro {
    margin-top: 5px;
    width: 85%;
    border-radius: 5px;
    padding: 5px;
    display: flex;
}

.msj-rta {
    float: right;
    background: whitesmoke;
}

.msj {
    float: left;
    background: white;
}

/* Chat frame */
.frame {
    background: #e0e0de;
    height: 450px;
    overflow: hidden;
    padding: 0;
}

.frame > div:last-of-type {
    position: absolute;
    bottom: 0;
    width: 100%;
    display: flex;
}

/* Header icon */
body > div > div > div:nth-child(2) > span {
    background: whitesmoke;
    padding: 10px;
    font-size: 21px;
    border-radius: 50%;
}

body > div > div > div.msj-rta.macro {
    margin: auto;
    margin-left: 1%;
}

/* Chat messages list */
ul.chatol {
    width: 100%;
    list-style-type: none;
    padding: 18px;
    position: absolute;
    bottom: 47px;
    display: flex;
    flex-direction: column;
    top: 0;
    overflow-y: scroll;
}

/* Message bubbles tails */
.msj:before {
    width: 0;
    height: 0;
    content: "";
    top: -5px;
    left: -14px;
    position: relative;
    border-style: solid;
    border-width: 0 13px 13px 0;
    border-color: transparent #ffffff transparent transparent;
}

.msj-rta:after {
    width: 0;
    height: 0;
    content: "";
    top: -5px;
    left: 14px;
    position: relative;
    border-style: solid;
    border-width: 13px 13px 0 0;
    border-color: whitesmoke transparent transparent transparent;
}

/* Inputs & placeholders */
input:focus {
    outline: none;
}

::-webkit-input-placeholder { /* Chrome/Opera/Safari */
    color: #d4d4d4;
}
::-moz-placeholder { /* Firefox 19+ */
    color: #d4d4d4;
}
:-ms-input-placeholder { /* IE 10+ */
    color: #d4d4d4;
}
:-moz-placeholder { /* Firefox 18- */
    color: #d4d4d4;
}

/* Icons */
.fa-2x {
    font-size: 2.3em !important;
}

/* Layout: left sidebar / main */
.chatside {
    padding: 0;
    margin: 0;
    height: 100%;
}

.chatside-one {
    padding: 0;
    margin: 0;
    height: 100%;
    width: 100%;
    z-index: 1;
    position: relative;
    display: block;
    top: 0;
}

/* Top chat heading */
.chatheading {
    padding: 10px 16px 10px 15px;
    margin: 0;
    height: 60px;
    width: 100%;
    background-color: #eee;
    z-index: 1000;
}

.chatheading-avatar {
    padding: 0;
    cursor: pointer !important;
}

.chatheading-avatar-icon img {
    border-radius: 50%;
    height: 50px;
    width: 50px;
}

/* Sidebar list */
.chatsideBar {
    padding: 0 !important;
    margin: 0 !important;
    background-color: #fff;
    overflow-y: auto;
    border: 1px solid #f7f7f7;
    height: calc(100% - 120px);
}

.chatsideBar-body {
    position: relative;
    padding: 10px !important;
    border-bottom: 1px solid #f7f7f7;
    height: 72px;
    margin: 0 !important;
    cursor: pointer;
}

.chatsideBar-body:hover {
    background-color: #f2f2f2;
}

.chatsideBar-avatar {
    text-align: center;
    padding: 0 !important;
}

.chatavatar-icon img {
    border-radius: 50%;
    height: 49px;
    width: 49px;
}

.chatsideBar-main {
    padding: 0 !important;
}

.chatsideBar-main .row {
    padding: 0 !important;
    margin: 0 !important;
}

.chatsideBar-name {
    padding: 10px !important;
}

.chatsideBar-time {
    padding: 10px !important;
}

/* New message slide panel */
.newMessage {
    padding: 0 !important;
    margin: 0 !important;
    height: 100%;
    position: relative;
    left: -100%;
}

.newMessage-heading {
    padding: 10px 16px 10px 15px !important;
    margin: 0 !important;
    height: 100px;
    width: 100%;
    background-color: #00bfa5;
    z-index: 1001;
}

.newMessage-main {
    padding: 10px 16px 0 15px !important;
    margin: 0 !important;
    height: 60px;
    margin-top: 30px !important;
    width: 100%;
    z-index: 1001;
    color: #fff;
}

.newMessage-title {
    font-size: 18px;
    font-weight: 700;
    padding: 10px 5px !important;
}

.newMessage-back {
    text-align: center;
    vertical-align: baseline;
    padding: 12px 5px !important;
    display: block;
    cursor: pointer;
}

.newMessage-back i {
    margin: auto !important;
}

/* Header icons on right */
.chatheading-compose {
    padding: 5px !important;
}

.chatheading-compose i {
    color: #fff;
    cursor: pointer;
}

.chatheading-dot {
    padding: 5px !important;
    margin-left: 10px !important;
}

.chatheading-dot i {
    color: #fff;
    cursor: pointer;
}






/* =====================================
   FORCED RTL (Always Right-to-Left)
   ===================================== */

/* Main bubble text (RTL) */
.chattext-l9 {
    float: right !important;
    padding-left: 10px !important;
    direction: rtl !important;
    text-align: right !important;
}

/* Opposite bubble (also RTL aligned bubble) */
.chattext-r9 {
    float: left !important;
    padding-right: 10px !important;
    direction: rtl !important;
    text-align: right !important;
}

/* Internal text container forced RTL */
.chattext-l9 .chattext,
.chattext-r9 .chattext {
    direction: rtl !important;
    text-align: right !important;
}

/* Paragraphs inside forced RTL bubble */
.chattext-l9 p,
.chattext-r9 p {
    direction: rtl !important;
    text-align: right !important;
}
 