/* Comptoir Auto — Messagerie 3.0. Presentation-only, based on V9.0.4-dev.1.
   Loaded last so older responsive layers and the PC consolidation cannot steal chat height. */
#messages{min-width:0}
#messages>.page-head{display:flex!important;align-items:center!important;min-height:0!important;padding:0 2px!important;margin:0 0 10px!important;background:transparent!important;border:0!important;border-radius:0!important;box-shadow:none!important}
#messages>.page-head::before,#messages>.page-head::after{display:none!important}
#messages>.page-head h1{font-family:Fraunces,Georgia,serif!important;font-size:clamp(21px,2vw,25px)!important;line-height:1.2!important;margin:0!important;color:#143b32!important}
#messages>.page-head .eyebrow,#messages>.page-head p{display:none!important}
#messages>.page-head>div:first-child{flex:1 1 auto!important}
#messages .message-scope-tabs-v781{max-width:415px;margin:0 0 10px!important;padding:3px;border-radius:12px;gap:3px;box-shadow:none}
#messages .message-scope-tabs-v781 button{padding:8px 10px!important;min-height:35px;border-radius:9px;font-size:12px!important;font-weight:750}
#messages .msg30-workspace{display:grid!important;grid-template-columns:minmax(248px,30%) minmax(0,1fr)!important;gap:0!important;padding:0!important;width:100%;height:clamp(470px,calc(100dvh - 220px),1100px)!important;min-height:470px!important;max-height:none!important;border:1px solid #dfd9cc!important;border-radius:17px!important;background:#fff!important;box-shadow:0 10px 34px #142d2312;overflow:hidden!important}
#messages .msg30-sidebar{min-width:0;min-height:0;height:100%;display:flex;flex-direction:column;border-right:1px solid #e6e0d5;background:#fff}
#messages .msg30-sidebar-toolbar{flex:0 0 auto;padding:14px 13px 10px;background:#fff;border-bottom:1px solid #eee8de}
#messages .msg30-inbox-title{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:10px;color:#163e33;font-size:15px}
#messages .msg30-inbox-title span{font-size:11px;color:#77766e;font-weight:600}
#messages .msg30-search{display:flex;align-items:center;gap:7px;min-width:0;border:1px solid #deddd4;background:#faf9f5;border-radius:11px;padding:0 10px;color:#587064}
#messages .msg30-search span{font-size:23px;line-height:1;flex:0 0 auto}
#messages .msg30-search input{border:0!important;background:transparent!important;box-shadow:none!important;outline:0!important;font-size:12px;min-height:38px;width:100%;min-width:0;flex:1;color:#193e33;padding:0!important}
#messages .msg30-search:focus-within{border-color:#0f5b47;box-shadow:0 0 0 3px #0f5b4718}
#messages .msg30-inbox-filters{display:flex;gap:5px;margin-top:10px}
#messages .msg30-filter{border:1px solid transparent;background:#f6f4ef;color:#635f56;padding:6px 12px;font-size:11px;font-weight:700;border-radius:99px;min-height:30px;cursor:pointer}
#messages .msg30-filter.active{border-color:#bfd4c8;background:#e8f1eb;color:#0f513e}
#messages .thread-list{flex:1 1 0;min-height:0;max-height:none!important;width:100%;overflow-y:auto!important;overflow-x:hidden;scrollbar-width:thin;background:#fff!important;border-right:0!important}
#messages .thread{display:block!important;position:relative;margin:0;padding:12px!important;min-height:66px!important;border-bottom:1px solid #f0ece4!important;border-left:3px solid transparent;cursor:pointer;transition:background-color .12s}
#messages .thread.active{background:#edf5ef!important;border-left-color:#b38d30}
#messages .thread:hover{background:#f7f7f2!important}
#messages .thread:focus-visible{outline:2px solid #0f614a!important;outline-offset:-3px}
#messages .thread.v761-unread{background:#f3f8f4}
#messages .thread.v761-unread:before{display:none}
#messages .thread .seller b{font-size:12px;font-weight:750;line-height:1.3;color:#213f37}
#messages .thread .v761-preview{max-width:100%;font-size:11px!important;margin:3px 0 0;line-height:1.45;color:#696d67}
#messages .v761-thread-meta{align-self:center;gap:6px}
#messages .v761-thread-meta time{font-size:10px}
#messages .v761-thread-meta b{background:#c09b3d;color:#132f27;font-size:10px}
#messages .thread[hidden],#messages .msg30-no-results[hidden]{display:none!important}
#messages .msg30-no-results{padding:16px;margin:0;text-align:center;color:#6b7068;font-size:12px}
#messages .chat{min-width:0;min-height:0;height:100%;display:flex;flex-direction:column!important;overflow:hidden;background:#fff}
#messages .chat-head{display:flex;align-items:center;flex-wrap:nowrap!important;gap:9px!important;min-height:65px!important;padding:10px 14px!important;border-bottom:1px solid #ebe5da;background:#fff!important;position:relative;z-index:5}
#messages .chat-head .avatar{width:38px;height:38px;min-width:38px;flex:0 0 38px;border-radius:50%;font-size:12px}
#messages .msg30-head-info{flex:1 1 auto;min-width:0!important;overflow:hidden}
#messages .msg30-head-info b{display:block;font-size:13px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#messages .msg30-head-info small{font-size:10px!important;color:#6d756e;margin-top:3px}
#messages .msg30-head-tools{margin-left:auto;flex:0 0 auto;display:flex;align-items:center}
#messages .msg30-actions{position:relative}
#messages .msg30-actions>summary{display:grid;place-items:center;list-style:none;cursor:pointer;width:37px;height:37px;border-radius:10px;border:1px solid #e1ded3;background:#fff;color:#173e34;font-size:23px;font-weight:750;line-height:1}
#messages .msg30-actions>summary::-webkit-details-marker{display:none}
#messages .msg30-actions[open]>summary{background:#e9f1eb}
#messages .msg30-actions-menu{position:absolute;z-index:20;right:0;top:43px;display:grid;gap:3px;min-width:185px;padding:6px;border-radius:12px;background:#fff;border:1px solid #dfded2;box-shadow:0 12px 32px #193c3229}
#messages .msg30-actions:not([open]) .msg30-actions-menu{display:none}
#messages .msg30-actions-menu button{margin:0!important;width:100%;display:flex!important;align-items:center;justify-content:flex-start;gap:8px;text-align:left;padding:10px 12px!important;font-size:12px!important;font-weight:650;min-height:38px;border:0!important;background:transparent!important;color:#183f33!important;border-radius:8px!important}
#messages .msg30-actions-menu button:hover{background:#f0f4ef!important}
#messages .msg30-actions-menu button.danger86{color:#a13836!important}
#messages .msg30-actions-menu button:disabled{opacity:.45}
#messages .msg30-back{display:none}
#messages .chat-head .v761-chat-context{font-size:11px!important;min-width:0;min-height:35px;max-width:155px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border-radius:10px;padding:8px!important}
#messages .chat-head .v761-chat-context:after{display:none!important}
#messages .chat-body{flex:1 1 0!important;min-height:0!important;overflow-y:auto!important;overflow-x:hidden;padding:18px 22px!important;scrollbar-width:thin;background:#f8f7f3!important;overscroll-behavior:contain}
#messages .chat-body .bubble{width:fit-content;max-width:min(73%,640px);box-sizing:border-box;padding:10px 14px!important;margin:0 0 10px!important;border:1px solid #e5e8e0;border-radius:15px 15px 15px 5px!important;box-shadow:0 1px 2px #132f2710;color:#173b30;font-size:13px!important;line-height:1.52!important;overflow-wrap:anywhere;white-space:pre-wrap}
#messages .chat-body .bubble.them{background:#fff!important}
#messages .chat-body .bubble.me{margin-left:auto!important;color:#fff!important;background:#0f4739!important;border-color:#0f4739!important;border-radius:15px 15px 5px 15px!important}
#messages .chat-body .bubble.msg30-continued{margin-top:-5px!important}
#messages .chat-body .bubble time{display:block;margin-top:5px!important;font-size:10px!important;line-height:1.2;color:inherit;opacity:.68;text-align:right;white-space:normal}
#messages .chat-body .bubble .message802-attachments{white-space:normal}
#messages .chat-body .bubble .message-document-card{max-width:100%;white-space:normal}
#messages .chat-body .message-history-control{padding:8px 0 18px}
#messages .composer,#messages .composer:has(.message-document-tools){display:grid!important;grid-template-columns:40px minmax(0,1fr) auto!important;grid-template-rows:auto!important;align-items:end!important;column-gap:9px!important;row-gap:0!important;min-height:67px;max-width:100%;margin:0;padding:10px 13px!important;background:#fff!important;border-top:1px solid #e5e2d8;box-sizing:border-box}
#messages .composer .message-document-tools{grid-column:1!important;grid-row:1!important;display:flex!important;align-items:center;justify-content:center;min-width:0;max-width:40px;margin:0;padding:0!important;border:0!important;background:transparent!important}
#messages .message-document-tools #messageDocumentButton{width:40px!important;min-width:40px!important;height:43px;min-height:43px!important;display:grid;place-items:center;border:1px solid #deded5!important;border-radius:12px;background:#f8f8f5!important;color:#1b513e!important;padding:0!important;font-size:20px!important;line-height:1}
#messages .message-document-tools small{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
#messages .message-document-tools #messageDocumentStatus:not(:empty){position:absolute;bottom:calc(100% + 8px);left:12px;width:max-content;max-width:min(320px,90vw);padding:8px 12px;border:1px solid #d7e3d9;background:#fff;color:#154734;border-radius:9px;font-size:12px;box-shadow:0 5px 16px #102f241a;white-space:normal;overflow-wrap:anywhere;z-index:9}
#messages .composer #msgInput{grid-column:2!important;grid-row:1!important;align-self:stretch;resize:none;overflow-y:auto;width:100%!important;min-width:0!important;min-height:43px!important;max-height:120px!important;height:43px;box-sizing:border-box;border:1px solid #dcdcd2!important;border-radius:12px!important;background:#f7f7f3!important;box-shadow:none!important;padding:10px 12px!important;font:400 13px/21px Inter,Arial,sans-serif!important;color:#173a2d;outline:0}
#messages .composer #msgInput:focus{border-color:#0e7453!important;box-shadow:0 0 0 3px #0f5b471a!important}
#messages .composer button.primary{grid-column:3!important;grid-row:1!important;align-self:stretch;min-height:43px!important;height:43px!important;min-width:84px!important;max-width:none!important;padding:0 14px!important;font-size:12px!important;border-radius:12px!important;margin:0}
@media(min-width:761px) and (max-width:1100px){#messages .msg30-workspace{height:clamp(480px,calc(100dvh - 195px),900px)!important;grid-template-columns:minmax(225px,36%) minmax(0,1fr)!important}}
@media(max-width:760px){
 #messages{padding-top:0!important;padding-bottom:0!important}
 #messages>.page-head{display:none!important}
 #messages .message-scope-tabs-v781{width:100%;max-width:none;box-sizing:border-box;margin:0 0 8px!important}
 #messages .message-scope-tabs-v781 button{min-height:38px;font-size:12px!important}
 #messages .msg30-workspace{display:block!important;position:relative!important;height:calc(100dvh - 195px)!important;min-height:280px!important;max-height:none!important;border-radius:14px!important}
 #messages .msg30-sidebar{height:100%;min-height:0;display:flex!important;border:0}
 #messages .msg30-sidebar-toolbar{padding:12px 13px 9px}
 #messages .msg30-inbox-title{font-size:14px}
 #messages .thread-list{height:auto!important;min-height:0!important;flex:1 1 0!important;max-height:none!important;visibility:visible!important;opacity:1!important}
 #messages.mobile-chat-open .msg30-sidebar{display:none!important}
 #messages .chat{display:none!important}
 #messages.mobile-chat-open .chat{display:grid!important;position:absolute!important;inset:0!important;width:100%;height:100%!important;min-height:0!important;grid-template-rows:auto minmax(0,1fr) auto!important}
 #messages.mobile-chat-open .msg30-workspace{position:fixed!important;z-index:74!important;top:var(--v645-topbar,68px)!important;right:0!important;bottom:var(--v645-nav-space,calc(70px + env(safe-area-inset-bottom)))!important;left:0!important;width:100%!important;height:auto!important;min-height:0!important;border:0!important;border-radius:0!important}
 #messages .chat-head{min-height:58px!important;padding:8px 9px!important;gap:8px!important}
 #messages .chat-head:before{display:none!important;content:none!important}
 #messages .msg30-back{display:grid;place-items:center;flex:0 0 35px;width:35px;height:40px;padding:0;border:0;background:transparent;color:#154233;font-size:30px;cursor:pointer}
 #messages .chat-head .avatar{width:33px;height:33px;min-width:33px;flex-basis:33px}
 #messages .msg30-head-info b{font-size:12px!important}
 #messages .msg30-head-info small{font-size:10px!important}
 #messages .chat-head .v761-chat-context{font-size:10px!important;padding:7px!important;max-width:75px;min-height:34px!important}
 #messages .msg30-actions>summary{width:36px;height:36px}
 #messages .msg30-actions-menu{right:0;top:42px}
 #messages .chat-body{padding:12px 11px 16px!important}
 #messages .chat-body .bubble{max-width:88%!important;padding:9px 11px!important;font-size:13px!important;margin-bottom:8px!important}
 #messages.mobile-chat-open .composer,#messages.mobile-chat-open .composer:has(.message-document-tools),#messages .composer:has(.message-document-tools){display:grid!important;grid-template-columns:40px minmax(0,1fr) auto!important;grid-template-rows:auto!important;column-gap:6px!important;row-gap:0!important;padding:8px 8px max(8px,env(safe-area-inset-bottom))!important;min-height:62px;position:relative!important;inset:auto!important;width:100%!important;box-sizing:border-box!important}
 #messages .composer #msgInput{font-size:16px!important;line-height:21px!important;min-height:44px!important;height:44px}
 #messages .composer button.primary{padding:0 10px!important;min-width:68px!important;max-width:none!important;height:44px!important;min-height:44px!important}
 #messages .message-document-tools #messageDocumentButton{width:40px!important;min-width:40px!important;height:44px;min-height:44px!important}
}
@media(max-width:355px){#messages .chat-head .v761-chat-context{max-width:62px;font-size:9px!important}#messages .chat-body .bubble{max-width:91%!important}#messages .composer button.primary{min-width:65px!important;padding:0 8px!important;font-size:11px!important}}
@media(prefers-reduced-motion:reduce){#messages .thread{transition:none!important}}
/* Explicit send contrast: the historical page has a transparent generic primary override. */
#messages .composer button.primary{background:#0f3d30!important;color:#fff!important;border:1px solid #0f3d30!important;box-shadow:none!important}
#messages .composer button.primary:not(:disabled):hover{background:#14614b!important}
#messages .composer button.primary:disabled{opacity:.55!important;cursor:not-allowed}
