/* Action Centre chat - isolated floating panel; no header layout changes. */
.tc-root { position:fixed;right:22px;bottom:92px;z-index:1010;font-family:inherit;font-size:14px;line-height:1.42;color:#24313e;box-sizing:border-box; }
.tc-root *, .tc-root *::before,.tc-root *::after {box-sizing:border-box;}
.tc-root [hidden] {display:none!important;}
.tc-launcher {width:48px;height:48px;display:flex;align-items:center;justify-content:center;position:relative;margin-left:auto;background:#f8fafc;color:#263a4c;border:1px solid #cbd3db;border-radius:50%;box-shadow:0 3px 12px rgba(0,0,0,.13);font-size:21px;cursor:pointer;}
.tc-launcher:hover {background:#e9f0f5;}
.tc-launcher:focus-visible,.tc-root button:focus-visible,.tc-root textarea:focus-visible,.tc-root input:focus-visible {outline:2px solid #236aaf;outline-offset:2px;}
.tc-launcher-badge {position:absolute;top:-3px;right:-3px;width:12px;height:12px;min-width:12px;padding:0;background:#d5253a;border:2px solid var(--card-bg, var(--body-bg, #fff));border-radius:50%;box-shadow:0 0 0 1px rgba(50,50,50,.11);pointer-events:none;}
.tc-panel {position:absolute;right:0;bottom:58px;width:340px;max-width:calc(100vw - 30px);height:450px;max-height:calc(100vh - 155px);background:#fff;color:#253340;border:1px solid #cfd7df;border-radius:13px;box-shadow:0 12px 36px rgba(15,23,42,.21);display:flex;flex-direction:column;overflow:hidden;}
.tc-header {background:#f8fafc;display:flex;align-items:center;min-height:49px;padding:6px 12px;border-bottom:1px solid #e5e9ed;gap:5px;flex:0 0 auto;}
.tc-head-title {font-weight:650;font-size:15px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;}
.tc-spacer {flex:1;}
.tc-icon-btn {font:inherit;font-size:22px!important;line-height:1!important;width:29px;height:30px!important;min-width:29px;padding:0!important;cursor:pointer;border:0!important;background:transparent!important;color:#4d5964!important;border-radius:6px;}
.tc-icon-btn:hover {background:#e8edf3!important;}
.tc-search-line {padding:10px 12px 8px;flex:0 0 auto;}
.tc-search {width:100%;min-height:35px;padding:7px 10px!important;border:1px solid #cbd5e1!important;border-radius:8px!important;background:#fff!important;color:#222!important;font:inherit!important;}
.tc-people {min-height:0;overflow-y:auto;flex:1;padding:2px 7px 10px;}
.tc-person {font:inherit!important;width:100%;text-align:left;border:0!important;border-radius:9px;cursor:pointer;background:transparent!important;color:inherit!important;padding:9px!important;display:flex;gap:10px;align-items:center;min-height:58px;}
.tc-person:hover,.tc-person:focus-visible {background:#f0f5f9!important;}
.tc-avatar {width:37px;height:37px;flex:0 0 37px;display:flex;align-items:center;justify-content:center;border-radius:50%;background:#e5ebf1;color:#476073;font-weight:650;}
.tc-person-info {min-width:0;flex:1;display:flex;flex-direction:column;gap:2px;}
.tc-person-title {font-weight:600;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;}
.tc-preview {color:#6b7280;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;display:block;}
.tc-presence {display:inline-flex;align-items:center;gap:5px;color:#6b7280;font-size:11px;}
.tc-dot {height:7px;width:7px;border-radius:50%;background:#9ca3af;display:inline-block;}
.tc-online .tc-dot {background:#23975d;}.tc-away .tc-dot {background:#d59b22;}
.tc-person-unread {background:#be2938;color:white;border-radius:12px;padding:1px 6px;font-weight:bold;font-size:11px;}
.tc-empty {color:#6b7280;padding:22px 12px;text-align:center;font-size:13px;}
.tc-new-chat {width:calc(100% - 12px);margin:8px 6px!important;border:1px solid #cbd5e1!important;border-radius:7px!important;background:#fff!important;color:#275e91!important;padding:8px!important;font:inherit!important;cursor:pointer;}
.tc-new-chat:hover {background:#edf4fb!important;}
.tc-footnote {border-top:1px solid #e7eaee;padding:8px 12px;color:#6a717a;font-size:11px;flex:0 0 auto;}
.tc-peer-status {padding:4px 15px;border-bottom:1px solid #edf1f5;flex:0 0 auto;}
.tc-messages {flex:1;overflow:auto;min-height:0;display:flex;flex-direction:column;gap:9px;padding:12px;}
.tc-message {display:flex;flex-direction:column;align-items:flex-start;max-width:85%;flex:0 0 auto;}
.tc-message.tc-mine {align-self:flex-end;align-items:flex-end;}
.tc-message.tc-theirs {align-self:flex-start;}
.tc-bubble {background:#edf2f6;padding:9px 11px;border-radius:12px;word-break:break-word;white-space:pre-wrap;overflow-wrap:anywhere;max-width:100%;}
.tc-mine .tc-bubble {background:#dceefb;}
.tc-time {margin:3px 4px 0;color:#737d86;font-size:10px;}
.tc-load-older {margin:0 auto;padding:5px 8px!important;border:0!important;background:transparent!important;color:#1d6299!important;font-size:12px!important;cursor:pointer;}
.tc-compose {display:flex;gap:7px;border-top:1px solid #e5e9ed;padding:10px;align-items:flex-end;background:#fcfcfd;flex:0 0 auto;}
.tc-compose-input {min-height:43px;max-height:95px;width:100%;resize:vertical;flex:1;border:1px solid #d0d8df!important;background:#fff!important;color:#222!important;border-radius:8px!important;font:inherit!important;padding:7px!important;}
/* Native ERP .button-save colors; keep only chat-composer sizing. */
.tc-send {padding:9px 11px!important;border-radius:8px!important;cursor:pointer;font:inherit!important;font-weight:600!important;white-space:nowrap;}
.tc-send:disabled {opacity:.5;cursor:default;}
.tc-error {color:#a31a31;background:#fff0f1;border-radius:5px;margin:5px 10px;padding:8px;flex:0 0 auto;font-size:12px;}
.tc-toast {position:absolute;right:0;bottom:60px;width:240px;background:#263948;color:#fff;border-radius:8px;padding:12px;box-shadow:0 5px 20px rgba(0,0,0,.2);font-size:12px;}
@media(max-width:480px) {.tc-root{right:12px;bottom:86px;}.tc-panel{max-height:calc(100vh - 135px);height:425px;}.tc-launcher{width:45px;height:45px;}}

/* Respect ERP theme values where supplied; retain readable light-theme fallback. */
.tc-panel {background:var(--card-bg, var(--body-bg, #fff));color:var(--text-color, #253340);}
.tc-header {background:var(--card-bg, #f8fafc);}
.tc-root .tc-launcher {background:var(--card-bg, #f8fafc);color:var(--text-color, #263a4c);}
