.chat-presence{display:inline-flex;align-items:center;gap:7px;font-size:.9rem;color:#596579}
.chat-presence i{flex:none;width:10px;height:10px;border-radius:50%;background:#e53935}
.chat-presence.is-online i{background:#20a464}
.chat-presence-label{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
.seller-contact-presence .seller-presence-label{position:static!important;width:auto!important;height:auto!important;padding:0!important;margin:0!important;overflow:visible!important;clip:auto!important;white-space:normal!important;border:0!important}
.chat-open-button{width:100%;margin:8px 0}
.chat-open-button,.first-contact-form button{background:#2ecc71;color:#fff}
.chat-open-button:hover,.first-contact-form button:hover{background:#27ae60}
.first-contact-form{display:flex;width:100%;gap:8px;margin-top:10px}
.first-contact-form textarea{flex:0 1 70%;min-width:0;min-height:56px;padding:12px;border:1px solid #cbd2dc;border-radius:8px;font:inherit;line-height:1.4;resize:vertical}
.first-contact-form button{flex:1;margin:0}
.first-contact-form[hidden],.chat-open-button[hidden]{display:none!important}
.hidden-inbox-link[hidden]{display:none!important}
.chat-modal[hidden]{display:none!important}
.chat-modal{position:fixed;inset:0;z-index:100010;display:grid;place-items:center;padding:16px;background:#101828a8}
.chat-dialog{display:flex;flex-direction:column;width:min(560px,100%);height:min(680px,90dvh);overflow:hidden;border-radius:14px;background:#fff;box-shadow:0 12px 40px #0004}
.mobile-detail-page .chat-modal{padding:0}
.mobile-detail-page .chat-dialog{width:100%;height:100vh;height:100dvh;max-height:100dvh;border-radius:0}
.mobile-detail-page .chat-dialog .chat-status{order:2}
.mobile-detail-page .chat-dialog .chat-messages{min-height:0}
.mobile-detail-page .chat-dialog #chatForm{position:relative;bottom:auto;order:3;flex:0 0 auto;margin-top:0}
.chat-dialog>header{display:flex;align-items:center;gap:12px;padding:12px 16px;border-bottom:1px solid #e5e9ef}
.chat-dialog>header h2{flex:1;min-width:0;margin:0;overflow:hidden;font-size:1.05rem;text-overflow:ellipsis;white-space:nowrap}
.chat-dialog>header h2 a{display:block;overflow:hidden;color:inherit;text-decoration:none;text-overflow:ellipsis;white-space:nowrap}
.chat-dialog>header h2 a[href]:hover,.chat-dialog>header h2 a[href]:focus-visible{text-decoration:underline}
.chat-dialog>header h2 a[aria-disabled=true]{cursor:default}
.chat-dialog>header button{border:0;background:transparent;font-size:26px;cursor:pointer}
.chat-messages{display:flex;flex:1;flex-direction:column;gap:9px;overflow-y:auto;padding:16px;overscroll-behavior:contain}
.chat-bubble{max-width:82%;padding:9px 12px;border-radius:14px;background:#edf1f5;overflow-wrap:anywhere;white-space:pre-wrap}
.chat-bubble.is-mine{align-self:flex-end;background:#d9f4e5}
.chat-bubble .chat-message-link,.chat-bubble .chat-message-link:visited{color:#0866cc;text-decoration:underline;overflow-wrap:anywhere}
.chat-bubble .chat-message-link:hover,.chat-bubble .chat-message-link:focus-visible{color:#064a96}
.chat-bubble.is-pending{opacity:.7;border:1px dashed #98a2b3}
.chat-pending-label{display:block;margin-top:4px;color:#667085;font-size:.7rem}
.chat-message-time{display:block;margin-top:4px;color:#667085;font-size:.7rem;text-align:right}
.chat-message-actions{display:flex;align-items:center;justify-content:flex-end;gap:6px;margin-top:3px}
.chat-message-status{display:block;color:#667085;font-size:.75rem;line-height:1;text-align:right}
.chat-message-status.is-read{color:#1685d1}
.chat-delete-button{display:grid;place-items:center;width:22px;height:22px;margin:0;padding:3px;border:0;border-radius:4px;background:transparent;color:#b42318;cursor:pointer}
.chat-delete-button:hover{background:#fee4e2}
.chat-delete-button svg{display:block;width:16px;height:16px;fill:currentColor}
.chat-delete-button:disabled{opacity:.55;cursor:wait}
.chat-bubble .chat-image-message{display:block;width:auto;max-width:min(320px,70vw);max-height:320px;border-radius:8px;object-fit:contain}
.chat-dialog form{position:sticky;bottom:0;z-index:1;display:flex;flex:0 0 auto;align-items:center;gap:8px;padding:12px;border-top:1px solid #e5e9ef;background:#fff}
.chat-dialog form input{flex:1;min-width:0;padding:11px;border:1px solid #cbd2dc;border-radius:8px;font:inherit;text-align:start}
.chat-dialog form button,.chat-conversation-list button{border:0;border-radius:8px;background:#16794b;color:#fff;padding:10px 14px;font:inherit;cursor:pointer}
.chat-dialog form .chat-image-button{display:grid;flex:none;place-items:center;width:40px;height:40px;padding:0;border:1px solid #cbd2dc;border-radius:50%;background:#fff;color:#16794b;font-size:26px;font-weight:400;line-height:1}
.chat-dialog form .chat-image-button:hover{background:#edf6f1}
.chat-dialog form .chat-image-input[hidden]{display:none}
.chat-dialog form .chat-record-button{flex:none;display:grid;place-items:center;width:42px;padding:8px;background:#e9eef2;color:#344054}
.chat-record-button svg{width:22px;height:22px;fill:currentColor}
.chat-dialog form .chat-record-button.is-recording{background:#e53935;color:#fff;animation:chat-record-pulse 1.2s ease-in-out infinite}
.chat-recording-status{align-self:center;max-width:45%;color:#b42318;font-size:.75rem;line-height:1.2}
.chat-recording-status[hidden]{display:none}
.chat-bubble audio{display:block;width:min(260px,70vw);height:40px}
@keyframes chat-record-pulse{50%{opacity:.6}}
.chat-status{order:2;min-height:1.2em;margin:0;padding:0 12px 8px;color:#667085;font-size:.85rem}
.chat-dialog form{order:3}
.chat-inbox-panel .chat-retention-note{margin:0;padding:12px 16px;color:#667085;font-size:.75rem;line-height:1.35}
.chat-inbox{display:grid;grid-template-columns:minmax(240px,340px) minmax(0,1fr);gap:18px;max-width:1180px;margin:24px auto;padding:0 16px}
.chat-inbox-panel,.chat-inbox-thread{min-width:0;border:1px solid #e1e6ed;border-radius:12px;background:#fff}
.chat-inbox-panel h1{margin:0;padding:16px;font-size:1.25rem}
.chat-conversation-list{display:flex;flex-direction:column}
.chat-conversation-list button{display:grid;grid-template-columns:36px minmax(0,1fr) auto;grid-template-rows:auto auto;align-items:center;column-gap:9px;row-gap:2px;width:100%;padding:9px 12px;border-radius:0;border-top:1px solid #e8ebf0;background:#fff;color:#202b3c;text-align:left}
.chat-conversation-list button[aria-current=true]{background:#edf6f1}
.chat-listing-thumb{display:block;grid-column:1;grid-row:1/3;align-self:center;width:36px;min-width:36px;max-width:36px;height:36px;min-height:36px;max-height:36px;overflow:hidden;border-radius:7px;background:#e8ebf0}
.chat-listing-thumb img{display:block!important;width:36px!important;min-width:36px!important;max-width:36px!important;height:36px!important;min-height:36px!important;max-height:36px!important;object-fit:cover}
.chat-conversation-list button>.chat-listing-bubble{display:flex;flex:0 0 36px;align-items:center;justify-content:center;width:36px;height:36px;min-width:36px;max-width:36px;overflow:hidden;margin:0;padding:0;border:0;border-radius:7px}
.chat-conversation-list button>.chat-listing-bubble img{display:block!important;width:36px!important;height:36px!important;min-width:36px!important;max-width:36px!important;max-height:36px!important;object-fit:cover}
.chat-conversation-list button>.chat-listing-bubble>span{display:none}
.chat-conversation-details{grid-column:2;grid-row:1/3;min-width:0}
.chat-conversation-heading{display:flex;align-items:center;gap:6px;min-width:0}
.chat-conversation-list strong,.chat-conversation-list small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.chat-conversation-list strong{flex:0 1 auto;max-width:40%}
.chat-listing-title{flex:1;min-width:0;overflow:hidden;color:#667085;font-size:.82rem;text-overflow:ellipsis;white-space:nowrap}
.chat-conversation-heading .chat-presence{flex:none}
.chat-conversation-preview{display:flex;align-items:center;justify-content:space-between;gap:5px;min-width:0;margin-top:2px}
.chat-conversation-preview small{flex:1;min-width:0;color:#667085;font-size:.76rem}
.chat-conversation-preview time{flex:none;color:#667085;font-size:.62rem;white-space:nowrap}
.chat-unread{min-width:20px;padding:2px 6px;border-radius:12px;background:#16794b;color:#fff;text-align:center;font-size:.75rem}
.chat-conversation-list button>.chat-unread{grid-column:3;grid-row:1/3;align-self:center}
.chat-inbox-thread .chat-dialog{width:100%;height:min(76dvh,760px);box-shadow:none}
.chat-inbox-empty{padding:18px;color:#667085}
#chatInboxBack{display:none}
@media(max-width:700px){.chat-inbox{grid-template-columns:1fr;margin:12px auto}.chat-inbox-thread:not([data-open=true]){display:none}.chat-inbox[data-thread-open=true] .chat-inbox-panel{display:none}.chat-inbox-thread .chat-dialog{height:calc(100dvh - 110px);min-height:320px}.chat-modal{padding:0}.chat-dialog{width:100%;height:100dvh;max-height:100dvh;border-radius:0}.chat-dialog form{display:grid;grid-template-columns:minmax(0,1fr) 42px;grid-template-rows:minmax(48px,auto) 42px;align-items:stretch}.chat-dialog form input[name=body]{grid-column:1;grid-row:1;width:100%;min-width:0;min-height:48px;padding-left:48px;flex:none}.chat-dialog form .chat-image-button{position:absolute;top:18px;left:18px;z-index:2;display:grid;width:32px;height:32px;font-size:23px}.chat-dialog form .chat-record-button{grid-column:2;grid-row:1/3;width:42px;height:100%;min-height:98px;align-self:stretch}.chat-dialog form>button[type=submit]{grid-column:1;grid-row:2;width:100%;min-height:42px}.chat-dialog form .chat-recording-status{grid-column:1/-1;grid-row:3;max-width:100%}}
@media(max-width:700px){#chatInboxBack:not([hidden]){display:inline-block}}
.mobile-chat-page{position:fixed;inset:0;width:100%;height:100vh;height:100dvh;overflow:hidden;overscroll-behavior:none}
.mobile-chat-page .chat-inbox{width:100%;height:100%;min-height:0;max-width:none;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr);gap:0;margin:0;padding:0}
.mobile-chat-page .chat-inbox-panel,.mobile-chat-page .chat-inbox-thread{min-height:0;border:0;border-radius:0}
.mobile-chat-page .chat-inbox-panel{overflow-y:auto}
.mobile-chat-page .chat-inbox-thread{height:100%;overflow:hidden}
.mobile-chat-page .chat-inbox-thread .chat-dialog{width:100%;height:100%;min-height:0;max-height:none;border-radius:0;box-shadow:none}
.mobile-chat-page .chat-messages{flex:1 1 0;min-height:0;overflow-y:auto;-webkit-overflow-scrolling:touch;overscroll-behavior-y:contain;touch-action:pan-y}
