/* ЖК Emirates — чат у картці лота. Самодостатній (поза .ev2), палітра «пісок». */
.em-chat { position: fixed; right: 20px; bottom: 20px; z-index: 80; width: min(380px, calc(100vw - 32px)); height: min(560px, calc(100vh - 110px));
  background: #FBF8F2; border: 1px solid #E7E0D2; box-shadow: 0 40px 90px -40px rgba(61,58,44,.6);
  display: none; flex-direction: column; font-family: "Jost", system-ui, sans-serif; color: #3D3A2C; }
.em-chat.open { display: flex; }
.em-chat__head { background: #3D3A2C; color: #F5F0E7; padding: 16px 18px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.em-chat__title { font-size: 14px; font-weight: 500; line-height: 1.3; }
.em-chat__status { font-size: 11px; font-weight: 400; color: #7CCB9A; margin-left: 4px; }
.em-chat__title span[data-chat-lotname] { display: block; font-size: 12px; color: rgba(245,240,231,.6); margin-top: 2px; }
.em-chat__close { background: none; border: none; color: #F5F0E7; font-size: 22px; line-height: 1; cursor: pointer; padding: 0 4px; }
.em-chat__body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.em-chat__msg { max-width: 82%; padding: 10px 13px; font-size: 14px; line-height: 1.5; border-radius: 12px; white-space: pre-wrap; word-wrap: break-word; }
.em-chat__msg--visitor { align-self: flex-end; background: #3D3A2C; color: #F5F0E7; border-bottom-right-radius: 3px; }
.em-chat__msg--ai, .em-chat__msg--admin { align-self: flex-start; background: #EEE6D8; color: #3D3A2C; border-bottom-left-radius: 3px; }
.em-chat__msg--sys { align-self: center; background: none; color: #9C967F; font-size: 12.5px; text-align: center; max-width: 100%; }
.em-chat__who { display: block; font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: #B07A52; margin-bottom: 3px; }
.em-chat__typing { align-self: flex-start; color: #9C967F; font-size: 13px; display: inline-flex; align-items: center; }
.em-chat__dots { display: inline-flex; gap: 3px; margin-left: 6px; }
.em-chat__dots i { width: 5px; height: 5px; border-radius: 50%; background: #B07A52; display: block; animation: emdot 1.1s infinite ease-in-out; }
.em-chat__dots i:nth-child(2) { animation-delay: .18s; }
.em-chat__dots i:nth-child(3) { animation-delay: .36s; }
@keyframes emdot { 0%, 60%, 100% { opacity: .25; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-3px); } }
.em-chat__foot { border-top: 1px solid #E7E0D2; padding: 12px; display: flex; gap: 8px; align-items: flex-end; }
.em-chat__input { flex: 1; resize: none; border: 1px solid #DCD4C2; background: #fff; border-radius: 8px; padding: 10px 12px; font: inherit; font-size: 14px; color: #3D3A2C; outline: none; max-height: 120px; }
.em-chat__input:focus { border-color: #B07A52; }
.em-chat__send { background: #3D3A2C; color: #F5F0E7; border: none; border-radius: 8px; padding: 0 16px; height: 42px; cursor: pointer; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; }
.em-chat__send:hover { background: #B07A52; }
.em-chat__send[disabled] { opacity: .5; cursor: default; }
