/* TeleHub 2.4 — tema claro estilo WhatsApp Web: menu lateral de ícones, barra verde com abas, lista e chat em tela cheia */
:root{--bg:#f0f2f5;--panel:#fff;--panel2:#f5f6f6;--panel3:#e9edef;--line:#e3e7ea;--line2:#cfd6db;--text:#111b21;--muted:#667781;
--accent:#0f8f62;--accent2:#0b7a55;--th-accent:#0f8f62;--bar:#1d8a6a;--bar-dark:#16755a;--rail:#eaf1ed;--rail-ic:#3d6b59;
--in:#fff;--bubble-in:#fff;--bubble-out:#d9fdd3;--note:#fff3c4;--note-line:#e8d27a;--chat-bg:#efeae2;
--danger:#d93f3f;--warn:#b97a00;--ok-soft:#dcf3e8;--ok-text:#0b6b49;--grad:linear-gradient(135deg,#12a06d,#0f8f62);--top:64px;
--shadow:0 1px 2px rgba(11,20,26,.08),0 4px 14px rgba(11,20,26,.05)}
*{box-sizing:border-box}
html,body{margin:0;height:100%;font-family:Inter,"Segoe UI",system-ui,-apple-system,Arial,sans-serif;background:var(--bg);color:var(--text);font-size:14px}
button,input,textarea,select{font:inherit;color:inherit}
button{cursor:pointer}
a{color:var(--accent2)}
code{background:var(--panel3);padding:2px 6px;border-radius:6px}
::-webkit-scrollbar{width:10px;height:10px}::-webkit-scrollbar-thumb{background:#c5cdd2;border-radius:8px;border:2px solid transparent;background-clip:content-box}::-webkit-scrollbar-thumb:hover{background:#aab5bc;background-clip:content-box;border:2px solid transparent}
svg.i,.nav-icon{fill:none;stroke:currentColor;stroke-width:1.75;stroke-linecap:round;stroke-linejoin:round}
svg.i{width:18px;height:18px;flex:none}
:focus-visible{outline:2px solid rgba(15,143,98,.55);outline-offset:2px}

/* Estrutura */
#app{display:grid;grid-template-columns:76px 1fr;height:100vh;background:var(--bg)}
main{min-width:0;display:flex;flex-direction:column;background:var(--bg)}
#content{flex:1;min-height:0;padding:22px 26px;overflow:auto}
#content:has(.split){padding:0;overflow:hidden;display:flex}
h1{font-size:19px;font-weight:700;letter-spacing:-.2px;margin:0}
h3{margin:0 0 12px;font-size:15px}.card h3:not(:first-child){margin-top:22px}

/* Barra verde do topo */
main>header{height:var(--top);flex:none;padding:0 20px;display:flex;align-items:center;gap:18px;background:var(--bar);color:#fff}
main>header h1{color:#fff}
main>header p{margin:2px 0 0;color:rgba(255,255,255,.82);font-size:12.5px}
.head-title{min-width:0}
.top-tabs{display:none;align-self:stretch;align-items:stretch;gap:2px}
body[data-view=queue] .top-tabs,body[data-view=mine] .top-tabs,body[data-view=closed] .top-tabs,body[data-view=search] .top-tabs{display:flex}
body[data-view=queue] .head-title,body[data-view=mine] .head-title,body[data-view=closed] .head-title,body[data-view=search] .head-title{display:none}
body[data-view=search] .head-title{display:block}body[data-view=search] .top-tabs{display:none}
.top-tabs button{height:auto;padding:0 16px;gap:8px;border:0;border-radius:0;background:transparent;color:rgba(255,255,255,.78);font-size:14px;font-weight:600;position:relative;white-space:nowrap}
.top-tabs button:hover{background:rgba(255,255,255,.09);border:0;color:#fff}
.top-tabs button.active{color:#fff}
.top-tabs button.active::after{content:"";position:absolute;left:10px;right:10px;bottom:0;height:3px;border-radius:3px 3px 0 0;background:#fff}
.tab-count{min-width:22px;height:20px;padding:0 7px;border-radius:999px;background:rgba(255,255,255,.22);color:#fff;font-size:11.5px;font-weight:700;display:inline-flex;align-items:center;justify-content:center}
.tab-count:empty{display:none}
.head-actions{display:flex;gap:12px;align-items:center;margin-left:auto}
.head-search,.search-box{position:relative;display:block;margin:0}
.head-search{width:320px}
.head-search svg,.search-box svg{position:absolute;left:13px;top:50%;transform:translateY(-50%);color:var(--muted);pointer-events:none}
.head-search input,.search-box input{width:100%;height:40px;padding:0 14px 0 40px}
.head-search input{background:rgba(255,255,255,.96);border:0;border-radius:12px;color:var(--text)}
.head-search input:focus{box-shadow:0 0 0 3px rgba(255,255,255,.35)}
.status-pill{display:flex;align-items:center;gap:8px;padding:8px 14px;border:1px solid rgba(255,255,255,.3);border-radius:999px;background:rgba(255,255,255,.14);color:#fff;font-size:12.5px;font-weight:500;white-space:nowrap}
.status-pill span{width:8px;height:8px;border-radius:50%;background:#ffb4b4}
.status-pill.connected span{background:#7dffc6;box-shadow:0 0 0 3px rgba(125,255,198,.25)}

/* Menu lateral só de ícones */
.sidebar{background:var(--rail);border-right:1px solid #d9e5de;padding:0;min-height:0;position:relative;z-index:20}
.sidebar-shell{height:100%;display:flex;flex-direction:column;align-items:center;padding:12px 0 14px;min-height:0}
.brand{padding:2px 0 14px}.brand-logo{display:none}.brand-icon{display:block;width:44px;height:44px;border-radius:14px;box-shadow:0 4px 12px rgba(15,143,98,.28)}
.nav-menu{display:flex;flex-direction:column;align-items:center;gap:6px}
.nav-menu button{width:50px;height:50px;min-height:0;padding:0;gap:0;justify-content:center;border:0;border-radius:15px;background:transparent;color:var(--rail-ic);position:relative;font-weight:500;transition:background-color .15s,color .15s,box-shadow .15s}
.nav-menu button:hover{background:rgba(255,255,255,.75);color:var(--accent2)}
.nav-menu button.active{background:#fff;color:var(--accent);box-shadow:0 1px 4px rgba(16,60,40,.18)}
.nav-icon{width:24px;height:24px;flex:none}
.nav-label{display:none}
.nav-menu button>span[id]{position:absolute;top:3px;right:2px;min-width:19px;height:19px;padding:0 5px;border-radius:999px;background:var(--accent);color:#fff;font-size:10.5px;font-weight:700;display:inline-flex;align-items:center;justify-content:center;border:2px solid var(--rail)}
.nav-menu button.active>span[id]{border-color:#fff}
.nav-menu button>span[id]:empty{display:none}
.nav-menu button::after,#logoutBtn::after{content:attr(data-tip);position:absolute;left:calc(100% + 12px);top:50%;transform:translateY(-50%);background:#111b21;color:#fff;padding:7px 11px;border-radius:9px;font-size:12.5px;font-weight:600;white-space:nowrap;opacity:0;pointer-events:none;transition:opacity .12s;z-index:60;box-shadow:0 6px 18px rgba(0,0,0,.25)}
.nav-menu button:hover::after,#logoutBtn:hover::after{opacity:1}
.sidebar-footer{margin-top:auto;padding-top:12px;display:grid;gap:10px;justify-items:center}
#me{width:42px;height:42px;border-radius:50%;background:linear-gradient(135deg,#cfefdf,#9ed9bc);display:grid;place-items:center;font-size:0;line-height:1;color:#0b5e40;font-weight:800}
#me strong{display:block;font-size:0}#me strong::first-letter{font-size:17px}#me .muted{display:none}
.ghost{border:0;background:transparent;color:var(--muted);text-align:left;padding:10px 12px;border-radius:12px;transition:background-color .15s,color .15s}
.ghost:hover{background:var(--panel3);color:var(--text)}
#logoutBtn{font-size:0;width:44px;height:44px;padding:0;display:grid;place-items:center;position:relative;color:var(--rail-ic);border-radius:14px}
#logoutBtn:hover{background:rgba(255,255,255,.75);color:var(--danger)}
#logoutBtn::before{content:"";width:22px;height:22px;background:currentColor;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4'/%3E%3Cpath d='M16 17l5-5-5-5M21 12H9'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4'/%3E%3Cpath d='M16 17l5-5-5-5M21 12H9'/%3E%3C/svg%3E") center/contain no-repeat}

/* Componentes */
.muted{color:var(--muted);font-size:12px}
.card{background:var(--panel);border:1px solid var(--line);border-radius:16px;padding:20px;box-shadow:var(--shadow)}
.grid4{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.grid2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:start}
.metric{position:relative}
.metric small{color:var(--muted);font-size:13px}.metric strong{display:block;font-size:32px;margin-top:8px;letter-spacing:-.5px}
.m-ic{position:absolute;right:16px;top:16px;width:40px;height:40px;border-radius:12px;background:var(--ok-soft);display:grid;place-items:center;color:var(--accent)}
.m-ic svg{width:21px;height:21px}
.section-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 14px}.section-title h3{margin:0}
.row{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
label{display:grid;gap:6px;margin-bottom:14px;color:#41525b;font-size:13px}
input,textarea,select{background:#fff;color:var(--text);border:1px solid var(--line2);border-radius:12px;padding:0 14px;height:42px;outline:none;transition:border-color .15s,box-shadow .15s;width:100%}
textarea{padding:12px 14px;height:auto;resize:vertical}
input::placeholder,textarea::placeholder{color:#8696a0}
input:focus,textarea:focus,select:focus{border-color:var(--accent);box-shadow:0 0 0 3px rgba(15,143,98,.16)}
input[type=checkbox]{width:16px;height:16px;accent-color:var(--accent);padding:0}
label:has(>input[type=checkbox]){display:flex;align-items:center;gap:10px}
button{display:inline-flex;align-items:center;justify-content:center;gap:8px;height:38px;padding:0 14px;border:1px solid var(--line2);border-radius:10px;background:#fff;color:var(--text);font-weight:600;font-size:13px;transition:background-color .15s,border-color .15s,filter .15s}
button:hover{border-color:#b7c2c9;background:var(--panel2)}
button:disabled{opacity:.5;cursor:not-allowed}
button.primary{border:0;background:var(--grad);color:#fff;font-weight:700}button.primary:hover{filter:brightness(1.07);background:var(--grad)}
button.danger{background:#fdeeee;border-color:#f3c0c0;color:#b42323}button.danger:hover{background:#fbdede}
button.ghost{height:auto}
.actions{display:flex;justify-content:flex-end;gap:8px;margin-top:18px}
.badge{display:inline-flex;align-items:center;padding:3px 10px;border-radius:999px;background:#edf0f2;border:0;color:#54656f;font-size:11.5px;font-weight:600}
.badge.assigned{background:var(--ok-soft);color:var(--ok-text)}
.badge.waiting{background:#fff0c8;color:#855400}
.badge.closed{background:#edf0f2;color:var(--muted)}.badge.high{background:#fde4e4;color:#b42323}
.badge.unread{background:#1fa463;color:#fff;font-weight:700;min-width:22px;height:22px;padding:0 6px;justify-content:center;font-size:12px}
.test-badge{background:var(--ok-soft);color:var(--ok-text);letter-spacing:.04em}
.table{width:100%;border-collapse:collapse}.table th,.table td{padding:12px;border-bottom:1px solid var(--line);text-align:left;font-size:13px}.table th{color:var(--muted);font-weight:600}.table tbody tr:hover{background:var(--panel2)}.click-row{cursor:pointer}
.user-row{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:13px 0;border-bottom:1px solid var(--line)}.user-row:last-child{border-bottom:0}
.priority-dot,.online-dot{display:inline-block;width:8px;height:8px;border-radius:50%;margin-right:6px;background:var(--warn)}.priority-dot.high{background:var(--danger)}.online-dot{background:#a0adb4}.online-dot.online{background:#1fa463}
.star{width:14px;height:14px;vertical-align:-2px;color:var(--warn)}
.empty{height:100%;display:grid;place-items:center;color:var(--muted);text-align:center;padding:20px}.empty-ic{width:64px;height:64px;margin:0 auto 10px;border-radius:20px;background:var(--ok-soft);display:grid;place-items:center;color:var(--accent)}.empty-ic svg{width:30px;height:30px}
.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.form-grid .full{grid-column:1/-1}
.bar-chart{height:220px;display:flex;align-items:end;gap:5px;border-bottom:1px solid var(--line);padding-top:20px}
.bar-chart .bar{flex:1;background:linear-gradient(#1fb57f,#0f8f62);min-height:2px;border-radius:5px 5px 0 0;position:relative}
.bar-chart .bar:hover{filter:brightness(1.1)}.bar-chart .bar:hover:after{content:attr(data-label);position:absolute;bottom:100%;left:50%;transform:translateX(-50%);background:#111b21;color:#fff;padding:5px 8px;border-radius:6px;font-size:11px;white-space:nowrap;margin-bottom:4px}
.modal{position:fixed;inset:0;background:rgba(17,27,33,.55);backdrop-filter:blur(3px);display:grid;place-items:center;z-index:70;padding:20px}
.modal-card{width:min(620px,100%);max-height:88vh;overflow:auto;background:#fff;border:1px solid var(--line);border-radius:18px;padding:24px;box-shadow:0 24px 70px rgba(0,0,0,.28)}.modal-card h3{font-size:18px;margin-bottom:16px}
#toast{position:fixed;right:20px;bottom:20px;max-width:380px;background:#111b21;color:#fff;border-left:4px solid #25d366;padding:13px 16px;border-radius:12px;opacity:0;transform:translateY(10px);pointer-events:none;transition:.2s;z-index:80;box-shadow:0 12px 36px rgba(0,0,0,.3)}#toast.show{opacity:1;transform:none}
.sector-switch{display:inline-flex;align-items:center;gap:10px;margin:0;cursor:pointer;user-select:none;font-size:13px}.sector-switch input{position:absolute;opacity:0;pointer-events:none}
.switch-track{width:44px;height:24px;border-radius:999px;background:#c5cdd2;position:relative;transition:.18s}.switch-thumb{position:absolute;width:18px;height:18px;left:3px;top:3px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.25);transition:.18s}
.sector-switch input:checked+.switch-track{background:var(--accent)}.sector-switch input:checked+.switch-track .switch-thumb{transform:translateX(20px)}.sector-switch input:focus-visible+.switch-track{outline:2px solid rgba(15,143,98,.5);outline-offset:2px}.sector-switch input:disabled+.switch-track{opacity:.55}.switch-state{min-width:76px}
.wa-connect-card{border:1px solid var(--line);border-radius:16px;padding:16px;background:var(--panel2)}.wa-status-line{display:flex;align-items:center;gap:12px;margin-bottom:14px}
.wa-dot{width:11px;height:11px;border-radius:50%;background:var(--danger);box-shadow:0 0 0 4px rgba(217,63,63,.12)}.wa-dot.on{background:#1fa463;box-shadow:0 0 0 4px rgba(31,164,99,.16)}.wa-dot.wait{background:#e2a100;box-shadow:0 0 0 4px rgba(226,161,0,.16)}
.wa-qr{display:flex;flex-direction:column;align-items:center;text-align:center;padding:16px;margin:12px 0;background:#fff;border:1px solid var(--line);border-radius:16px;color:#0b141a}.wa-qr img{width:min(310px,100%);height:auto}.wa-qr p{margin:6px 0 0;color:#52616a;font-size:13px}.wa-actions{margin-top:12px}
.test-mode-grid textarea{min-height:130px}

/* Conversas: lista à esquerda + chat à direita, em tela cheia (estilo WhatsApp Web) */
.split{display:grid;grid-template-columns:clamp(320px,33%,430px) minmax(0,1fr);gap:0;flex:1;height:auto;min-height:0}
.conv-list{background:#fff;border-right:1px solid var(--line);overflow:hidden;min-height:0;min-width:0;display:flex;flex-direction:column}
.chat{background:var(--bg);overflow:hidden;min-height:0;min-width:0;display:flex;flex-direction:column}
.list-head{padding:14px 16px 10px;display:flex;flex-direction:column;gap:10px;flex:none}
.mine-list-title{display:flex;align-items:center;justify-content:space-between;gap:10px}.mine-list-title strong{font-size:17px;font-weight:700}.mine-count{font-size:12px;color:var(--muted)}
.search-box input{background:var(--bg);border:0;border-radius:12px;height:40px}
.search-box input:focus{background:#fff;box-shadow:0 0 0 2px rgba(15,143,98,.35)}
.list-head select{background:var(--bg);border:0;height:38px;border-radius:12px}
#convItems{overflow:auto;flex:1}
.conv-item{position:relative;display:grid;grid-template-columns:48px minmax(0,1fr) auto;gap:14px;padding:12px 16px;border-top:0;cursor:pointer;align-items:start}
.conv-item::after{content:"";position:absolute;left:78px;right:0;bottom:0;height:1px;background:#eef0f2}
.conv-item:hover{background:var(--panel2)}.conv-item.active{background:var(--bg)}
.avatar{width:48px;height:48px;border-radius:50%;display:grid;place-items:center;font-weight:700;font-size:18px;color:#0b5e40;background:linear-gradient(135deg,#d3f1e2,#98d8b9)}
.conv-title{display:flex;justify-content:space-between;gap:8px;align-items:baseline}.conv-title strong{font-size:15px;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conv-title small{font-size:12px;color:var(--muted)}
.conv-preview{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--muted);font-size:13.5px;margin:3px 0 7px}
.tags{display:flex;gap:6px;flex-wrap:wrap}
.chat-head{display:flex;align-items:center;gap:14px;flex-wrap:wrap;padding:10px 18px;background:#f0f2f5;border-bottom:1px solid var(--line);flex:none}
.mine-who{flex:1;min-width:220px}.mine-who>strong{font-size:16px;font-weight:600}.mine-who .muted{margin-top:3px}
.toolbar{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.toolbar button{height:34px;border-radius:999px;padding:0 13px}
.back-btn{display:none;width:38px;padding:0}
.chat-body{flex:1;min-height:0;overflow:auto;padding:22px 7%;display:flex;flex-direction:column;gap:8px;background-color:var(--chat-bg);background-image:radial-gradient(rgba(11,20,26,.045) 1.3px,transparent 1.6px);background-size:22px 22px}
.bubble{position:relative;max-width:min(560px,78%);padding:8px 12px 6px;border-radius:12px;line-height:1.4;white-space:pre-wrap;word-break:break-word;align-self:flex-start;box-shadow:0 1px 1px rgba(11,20,26,.13);color:var(--text)}
.bubble.in{background:var(--bubble-in);border-top-left-radius:3px}
.bubble.out{background:var(--bubble-out);border-top-right-radius:3px;align-self:flex-end}
.bubble.internal{background:var(--note);border:1px solid var(--note-line);color:#5c4700;align-self:center;max-width:86%;box-shadow:none}
.note-label{display:flex;align-items:center;gap:6px;font-size:11px;font-weight:800;letter-spacing:.06em;margin-bottom:3px}
.msg-sender{display:flex;flex-direction:column;gap:1px;margin-bottom:4px}.msg-sender strong{font-size:12px;font-weight:700;color:var(--accent2)}.msg-sender span{font-size:11.5px;color:var(--muted)}
.bubble small{display:flex;align-items:center;justify-content:flex-end;gap:5px;margin-top:3px;font-size:11px;color:var(--muted);white-space:nowrap}
.tick{display:inline-flex}.tick svg{width:15px;height:15px}.tick.read{color:#34a9e0}.tick.fail{color:var(--danger)}
.reply-preview{border-left:4px solid var(--accent);background:rgba(11,20,26,.06);padding:6px 9px;margin-bottom:6px;font-size:12.5px;border-radius:6px}
.message-menu{position:absolute;top:6px;right:-36px;width:28px;height:28px;padding:0;border-radius:8px;display:none;color:var(--muted)}
.bubble.out .message-menu{right:auto;left:-36px}.bubble:hover .message-menu{display:inline-flex}
.file-link{display:inline-flex;align-items:center;gap:6px;margin-top:6px}
.chat-image-link img{transition:filter .15s}.chat-image-link:hover img{filter:brightness(1.05)}
.chat-audio{margin-top:6px;min-width:250px}audio{height:38px;max-width:100%}.chat-audio audio{width:min(320px,100%)}
.composer-wrap{background:#f0f2f5;border-top:1px solid var(--line);flex:none}
.reply-bar{display:none;align-items:center;justify-content:space-between;gap:10px;padding:8px 18px;background:var(--panel3);border-bottom:1px solid var(--line);font-size:12px}.reply-bar.show{display:flex}.reply-bar button{height:28px;padding:0 8px}
.attachment-preview,.audio-preview{padding:10px 18px 0;font-size:12px;color:var(--muted)}.attachment-preview:empty,.audio-preview:empty{display:none}
.composer{display:grid;grid-template-columns:44px 44px 44px minmax(0,1fr) auto;gap:8px;padding:12px 18px;align-items:end}
.composer>button.secondary{width:44px;height:44px;padding:0;border-radius:50%;border:0;background:transparent;color:#54656f}.composer>button.secondary:hover{background:var(--panel3);color:var(--text)}
.composer textarea{min-height:44px;max-height:140px;padding:12px 16px;resize:none;border:0;border-radius:22px;background:#fff}
.composer #sendBtn{height:44px;padding:0 20px;border-radius:22px;font-size:14px}
.mic-btn.recording{background:#fde4e4!important;color:#b42323!important}
.recording-bar,.audio-review{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:9px 12px;border-radius:12px;background:#fff;border:1px solid var(--line)}
.recording-dot{width:10px;height:10px;border-radius:50%;background:var(--danger);animation:thPulse 1s infinite}.audio-review audio{flex:1;min-width:200px}
@keyframes thPulse{50%{opacity:.35;transform:scale(.8)}}
.paste-preview{padding:12px;background:#fff;border:1px solid var(--line2);border-radius:14px;max-width:520px;color:var(--text)}
.paste-preview-head{display:flex;justify-content:space-between;gap:14px;align-items:center;margin-bottom:10px;font-size:13px}
.paste-preview img{display:block;max-width:100%;max-height:300px;object-fit:contain;border-radius:10px;border:1px solid var(--line);background:var(--bg)}
.paste-preview-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:10px}

/* Telas menores */
@media(max-height:800px){.nav-menu{gap:3px}.nav-menu button{width:44px;height:44px}.brand{padding-bottom:8px}.brand-icon{width:40px;height:40px}}
@media(max-height:660px){.nav-menu{overflow-y:auto;overflow-x:hidden}.nav-menu button::after{display:none}}
@media(max-width:1180px){.head-search{width:230px}}
@media(max-width:900px){
  .split{grid-template-columns:minmax(0,1fr)}
  .split .chat{display:none}.split.chat-open .chat{display:flex}.split.chat-open .conv-list{display:none}
  .back-btn{display:inline-flex}
  .grid4{grid-template-columns:repeat(2,1fr)}.grid2{grid-template-columns:1fr}
  .chat-body{padding:18px 14px}
}
@media(max-width:700px){
  :root{--top:60px}
  #app{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto;height:100dvh}
  .sidebar{order:2;border-right:0;border-top:1px solid #d9e5de}
  .sidebar-shell{flex-direction:row;align-items:center;padding:6px;gap:4px}
  .brand{display:none}.nav-menu{flex-direction:row;overflow-x:auto;flex:1;gap:2px;justify-content:flex-start}.nav-menu button{width:46px;height:46px;flex:none}.nav-menu button::after{display:none}
  .sidebar-footer{margin:0;padding:0;display:flex;gap:4px}#logoutBtn::after{display:none}
  main>header{padding:0 12px;gap:10px}main>header p{display:none}h1{font-size:17px}.head-search{display:none}
  .top-tabs{overflow-x:auto;flex:1;min-width:0;scrollbar-width:none}.top-tabs::-webkit-scrollbar{display:none}.top-tabs button{padding:0 11px;font-size:13px;flex:none}.head-actions{margin-left:0}.status-pill{font-size:0;gap:0;padding:11px}
  #content{padding:12px}.split{height:auto}
  .grid4,.form-grid{grid-template-columns:1fr}.bubble{max-width:88%}
  .message-menu{display:none!important}.composer{grid-template-columns:40px 40px 40px minmax(0,1fr)}.composer #sendBtn{grid-column:1/-1}
  .table{display:block;overflow-x:auto}
}


/* Modo escuro */
.theme-toggle{width:40px;height:40px;display:inline-grid;place-items:center;padding:0;border:1px solid rgba(255,255,255,.28);border-radius:12px;background:rgba(255,255,255,.13);color:#fff;font-size:21px;line-height:1;transition:.18s;flex:none}
.theme-toggle:hover{background:rgba(255,255,255,.22);border-color:rgba(255,255,255,.42)}
.theme-icon{display:block;transform:translateY(-1px)}
html[data-theme="dark"]{color-scheme:dark}
html[data-theme="dark"] body{
  --bg:#15191d;--panel:#1d2328;--panel2:#232a30;--panel3:#2a3238;--line:#343d44;--line2:#45515a;--text:#edf2f4;--muted:#a8b3ba;
  --accent:#22a879;--accent2:#39bd8c;--bar:#20272c;--bar-dark:#171c20;--rail:#111518;--rail-ic:#a8bbb3;
  --in:#20262b;--bubble-in:#242b30;--bubble-out:#174f3d;--note:#4a401d;--note-line:#76692d;--chat-bg:#111619;
  --danger:#ff6b6b;--warn:#e5ae42;--ok-soft:#17382d;--ok-text:#74ddb3;
  --shadow:0 1px 2px rgba(0,0,0,.38),0 8px 24px rgba(0,0,0,.18)
}
html[data-theme="dark"] body,html[data-theme="dark"] main,html[data-theme="dark"] #app{background:var(--bg);color:var(--text)}
html[data-theme="dark"] .sidebar{background:#111518;border-color:#252d32}
html[data-theme="dark"] .sidebar-shell{background:#111518}
html[data-theme="dark"] .nav-menu button{color:#aeb9bf}
html[data-theme="dark"] .nav-menu button:hover{background:#20272c;color:#fff}
html[data-theme="dark"] .nav-menu button.active{background:#1d3c32;color:#67d3a9}
html[data-theme="dark"] main>header{background:#20272c;border-bottom:1px solid #30383e}
html[data-theme="dark"] .head-search input{background:#2a3238;color:#f3f7f8}
html[data-theme="dark"] .head-search input::placeholder,html[data-theme="dark"] input::placeholder,html[data-theme="dark"] textarea::placeholder{color:#84929a}
html[data-theme="dark"] .card,html[data-theme="dark"] .panel,html[data-theme="dark"] .modal-card{background:var(--panel);border-color:var(--line);color:var(--text)}
html[data-theme="dark"] input,html[data-theme="dark"] textarea,html[data-theme="dark"] select{background:#20272c;border-color:#3a444b;color:#edf2f4}
html[data-theme="dark"] input:focus,html[data-theme="dark"] textarea:focus,html[data-theme="dark"] select:focus{border-color:#3bb78c;box-shadow:0 0 0 3px rgba(59,183,140,.14)}
html[data-theme="dark"] button.secondary,html[data-theme="dark"] button.ghost{background:#262e34;border-color:#3b464e;color:#e5ecef}
html[data-theme="dark"] button.secondary:hover,html[data-theme="dark"] button.ghost:hover{background:#303a41}
html[data-theme="dark"] .muted,html[data-theme="dark"] .conv-preview,html[data-theme="dark"] .mine-count,html[data-theme="dark"] .conv-title small{color:var(--muted)}
html[data-theme="dark"] .conv-list{background:#171c20;border-color:#30383e}
html[data-theme="dark"] .conv-item::after{background:#283036}
html[data-theme="dark"] .conv-item:hover{background:#20272c}
html[data-theme="dark"] .conv-item.active{background:#263038}
html[data-theme="dark"] .search-box input,html[data-theme="dark"] .list-head select{background:#252d33;color:#edf2f4}
html[data-theme="dark"] .search-box input:focus{background:#2b343a}
html[data-theme="dark"] .chat{background:#111619}
html[data-theme="dark"] .chat-head,html[data-theme="dark"] .composer-wrap{background:#20272c;border-color:#30383e}
html[data-theme="dark"] .chat-body{background-color:#111619;background-image:radial-gradient(rgba(255,255,255,.025) 1.2px,transparent 1.5px)}
html[data-theme="dark"] .bubble.in{background:#242b30;color:#f1f5f6}
html[data-theme="dark"] .bubble.out{background:#174f3d;color:#f1f7f5}
html[data-theme="dark"] .bubble.internal{background:#4a401d;border-color:#76692d;color:#f5e9a9}
html[data-theme="dark"] .reply-preview{background:rgba(255,255,255,.065)}
html[data-theme="dark"] .composer textarea,html[data-theme="dark"] .recording-bar,html[data-theme="dark"] .audio-review,html[data-theme="dark"] .paste-preview{background:#2a3238;color:#edf2f4;border-color:#3a444b}
html[data-theme="dark"] .reply-bar{background:#252d33;border-color:#343d44}
html[data-theme="dark"] .wa-connect-card{background:#20272c;border-color:#364047}
html[data-theme="dark"] .wa-qr{background:#fff;color:#0b141a}
html[data-theme="dark"] .table th,html[data-theme="dark"] .table td{border-color:#343d44}
html[data-theme="dark"] .table tbody tr:hover{background:#222a30}
html[data-theme="dark"] code{background:#2a3238;color:#e7eef1}
html[data-theme="dark"] ::-webkit-scrollbar-thumb{background:#4b565d;border:2px solid transparent;background-clip:content-box}
html[data-theme="dark"] ::-webkit-scrollbar-thumb:hover{background:#657179;background-clip:content-box;border:2px solid transparent}
@media(max-width:700px){html[data-theme="dark"] .sidebar{border-top-color:#2b343a}}

/* Mensagens agendadas */
.scheduled-head{align-items:flex-start;margin-bottom:8px}.scheduled-head p{margin:5px 0 0}.scheduled-list{display:flex;flex-direction:column;gap:10px;margin-top:14px}.scheduled-item{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:15px 16px;border:1px solid var(--line);border-radius:14px;background:var(--panel2)}.scheduled-main{min-width:0;flex:1}.scheduled-top{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.scheduled-text{margin-top:8px;white-space:pre-wrap;overflow-wrap:anywhere;color:var(--text)}.scheduled-meta{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin-top:9px;color:var(--muted);font-size:13px}.scheduled-meta .i{width:15px;height:15px}.scheduled-actions{display:flex;gap:8px;flex:none}.scheduled-error{margin-top:8px;color:var(--danger);font-size:13px}.badge.danger{background:rgba(220,53,69,.12);color:var(--danger)}
html[data-theme="dark"] .scheduled-item{background:#20272c;border-color:#343d44}
@media(max-width:700px){.scheduled-item{align-items:stretch;flex-direction:column}.scheduled-actions{width:100%}.scheduled-actions button{flex:1}}

/* Contatos e nova mensagem */
.contacts-head{align-items:flex-end;gap:14px}.contacts-head .row{align-items:center;flex-wrap:wrap}.contacts-table td{vertical-align:middle}.contact-actions-col{min-width:290px}.contact-actions{display:flex;gap:7px;justify-content:flex-end;flex-wrap:wrap}.compact{padding:7px 10px;min-height:34px}.new-message-hint{margin-top:12px;padding:11px 12px;border:1px solid var(--line);border-radius:12px;background:var(--panel2);color:var(--muted);font-size:13px}
html[data-theme="dark"] .new-message-hint{background:#20272c;border-color:#343d44;color:#a8b3ba}
@media(max-width:900px){.contacts-head{align-items:stretch;flex-direction:column}.contacts-head .row{width:100%}.contacts-head #contactSearch{width:100%!important;flex:1}.contact-actions{justify-content:flex-start}.contact-actions-col{min-width:270px}}

/* Busca estilo WhatsApp: conversas + contatos */
.whatsapp-search{position:relative}.whatsapp-search input{padding-right:42px}.search-clear{position:absolute;right:7px;top:50%;transform:translateY(-50%);width:30px;height:30px;border:0;background:transparent;color:var(--muted);font-size:24px;line-height:1;display:none;place-items:center;padding:0;border-radius:50%}.search-clear:hover{background:var(--panel3);color:var(--text)}
.search-group{padding-bottom:8px}.search-section-title{padding:16px 20px 10px;font-size:13px;font-weight:700;color:var(--muted);background:var(--panel);position:sticky;top:0;z-index:2}.search-empty{padding:16px 20px;color:var(--muted);font-size:13px}.contacts-results{border-top:8px solid var(--bg)}
.search-contact-item{width:100%;border:0;background:transparent;color:var(--text);display:grid;grid-template-columns:48px minmax(0,1fr) 32px;gap:14px;align-items:center;text-align:left;padding:11px 16px;cursor:pointer;position:relative}.search-contact-item::after{content:"";position:absolute;left:78px;right:0;bottom:0;height:1px;background:#eef0f2}.search-contact-item:hover{background:var(--panel2)}.contact-avatar{flex:none}.search-contact-body{display:flex;flex-direction:column;min-width:0;gap:3px}.search-contact-body strong{font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.search-contact-body small{font-size:12.5px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.search-contact-action{display:grid;place-items:center;color:var(--accent)}.search-contact-action svg{width:18px;height:18px}.badge.search-hit{background:rgba(15,143,98,.10);color:var(--accent2)}
html[data-theme="dark"] .search-section-title{background:#171c20}html[data-theme="dark"] .contacts-results{border-top-color:#11171a}html[data-theme="dark"] .search-contact-item::after{background:#283036}html[data-theme="dark"] .search-contact-item:hover{background:#20272c}

/* ==========================================================
   TeleHub 3.0 — redesign inspirado no layout atual do WhatsApp Web
   Mantém todas as funções do TeleHub e reorganiza a experiência.
   ========================================================== */

/* Conversas ocupam a tela inteira, como no WhatsApp Web */
body[data-view="queue"] main>header,
body[data-view="mine"] main>header,
body[data-view="closed"] main>header,
body[data-view="search"] main>header{display:none}
body[data-view="queue"] #content,
body[data-view="mine"] #content,
body[data-view="closed"] #content,
body[data-view="search"] #content{height:100vh}

html[data-theme="dark"] body{
  --bg:#0b141a;--panel:#111b21;--panel2:#202c33;--panel3:#2a3942;
  --line:#222d34;--line2:#38464f;--text:#e9edef;--muted:#8696a0;
  --accent:#00a884;--accent2:#00a884;--bar:#202c33;--bar-dark:#111b21;
  --rail:#202c33;--rail-ic:#aebac1;--chat-bg:#0b141a;
  --bubble-in:#202c33;--bubble-out:#005c4b;
}

/* Rail lateral esquerdo */
html[data-theme="dark"] #app{grid-template-columns:72px minmax(0,1fr);background:#0b141a}
html[data-theme="dark"] .sidebar{background:#202c33;border-right:1px solid #313d45}
html[data-theme="dark"] .sidebar-shell{background:#202c33;padding:10px 0 12px}
html[data-theme="dark"] .brand{padding:0 0 12px}
html[data-theme="dark"] .brand-icon{width:42px;height:42px;border-radius:50%;box-shadow:none;background:#111b21;padding:5px}
html[data-theme="dark"] .nav-menu{gap:5px}
html[data-theme="dark"] .nav-menu button{width:48px;height:48px;border-radius:50%;color:#aebac1;background:transparent;position:relative}
html[data-theme="dark"] .nav-menu button:hover{background:#2a3942;color:#e9edef}
html[data-theme="dark"] .nav-menu button.active{background:#374248;color:#e9edef}
html[data-theme="dark"] .nav-menu button.active::before{content:"";position:absolute;right:-12px;top:9px;width:4px;height:30px;border-radius:4px;background:#00a884}
html[data-theme="dark"] .nav-icon{width:23px;height:23px}
html[data-theme="dark"] .sidebar-footer{border-top:1px solid #313d45;padding-top:10px}
html[data-theme="dark"] #me{width:44px;height:44px;border-radius:50%;overflow:hidden;background:#374248;display:grid;place-items:center;font-size:0}
html[data-theme="dark"] #me::after{content:"TH";font-size:12px;font-weight:800;color:#00a884}
html[data-theme="dark"] #logoutBtn{width:44px;height:44px;border-radius:50%;font-size:0;padding:0;background:transparent;border:0}
html[data-theme="dark"] #logoutBtn::before{content:"↪";font-size:21px;color:#aebac1}

/* Split principal — coluna de conversas + chat */
body[data-view="queue"] .split,
body[data-view="mine"] .split,
body[data-view="closed"] .split,
body[data-view="search"] .split{grid-template-columns:minmax(430px,35vw) minmax(0,1fr);height:100vh;background:#0b141a}
html[data-theme="dark"] .conv-list{background:#111b21;border-right:1px solid #313d45}
html[data-theme="dark"] .chat{background:#0b141a}

/* Cabeçalho da lista, igual ao print */
.wa-list-head{padding:0 20px 8px!important;gap:10px!important;background:var(--panel)!important}
.wa-list-top{height:62px;display:flex;align-items:center;justify-content:space-between;gap:16px}
.wa-list-brand{display:flex;align-items:baseline;gap:10px;min-width:0}
.wa-list-brand>strong{font-size:22px;letter-spacing:-.45px;color:var(--text)}
.wa-view-name{font-size:12px;font-weight:600;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.wa-list-actions{display:flex;align-items:center;gap:8px}
.wa-icon-btn,.wa-new-btn{border:0;display:grid;place-items:center;flex:none}
.wa-icon-btn{width:40px;height:40px;border-radius:50%;background:transparent;color:var(--text);font-size:27px;line-height:1}
.wa-icon-btn:hover{background:var(--panel3)}
.wa-new-btn{width:44px;height:44px;border-radius:50%;background:#00a884;color:#061f1a;font-size:28px;font-weight:400;box-shadow:none}
.wa-new-btn:hover{background:#06cf9c}

/* Busca principal */
.wa-list-head .search-box{margin:0;width:100%}
.wa-list-head .search-box input{height:44px;border:1px solid transparent!important;border-radius:22px!important;padding:0 46px 0 49px!important;background:#202c33!important;color:#e9edef!important;font-size:14px;box-shadow:none!important}
.wa-list-head .search-box input::placeholder{color:#aebac1!important}
.wa-list-head .search-box svg{left:18px;color:#aebac1}
.wa-list-head .search-box:focus-within input{border-color:#00a884!important;box-shadow:inset 0 0 0 1px #00a884!important}
.wa-list-head .search-clear{right:10px;color:#c6d1d6}

/* Chips de filtro */
.wa-filter-row{display:flex;align-items:center;gap:8px;overflow-x:auto;padding:1px 0 3px;scrollbar-width:none}
.wa-filter-row::-webkit-scrollbar{display:none}
.wa-filter{height:36px;border-radius:18px;border:1px solid #313d45;background:#111b21;color:#aebac1;padding:0 14px;font-weight:600;white-space:nowrap}
.wa-filter:hover{background:#202c33;color:#e9edef}
.wa-filter.active{background:#103529;border-color:#103529;color:#d9fdd3}
.wa-filter-plus{width:38px;padding:0;font-size:21px}
.wa-filter span:empty{display:none}
.wa-sector-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:2px 0 4px}
.wa-sector-row select{height:34px!important;max-width:220px;padding:0 30px 0 12px;border-radius:17px!important;background:#202c33!important;color:#cbd5da!important;font-size:12px;border:0!important}
.wa-sector-row .mine-count{font-size:11px;color:#8696a0;white-space:nowrap}

/* Lista de conversas */
#convItems{overflow:auto;min-height:0;flex:1;background:#111b21}
html[data-theme="dark"] .conv-item{grid-template-columns:52px minmax(0,1fr) auto;gap:12px;padding:12px 14px 11px 20px;min-height:72px;align-items:center;background:#111b21}
html[data-theme="dark"] .conv-item::after{left:84px;background:#222d34}
html[data-theme="dark"] .conv-item:hover{background:#202c33}
html[data-theme="dark"] .conv-item.active{background:#2a3942}
html[data-theme="dark"] .avatar{width:52px;height:52px;border-radius:50%;background:linear-gradient(145deg,#33444e,#1c2b33);color:#d9fdd3;font-size:17px;border:1px solid #3a4850}
html[data-theme="dark"] .conv-title strong{font-size:16px;color:#e9edef;font-weight:500}
html[data-theme="dark"] .conv-title small{color:#8696a0;font-size:11.5px}
html[data-theme="dark"] .conv-preview{font-size:13.5px;color:#8696a0;margin:4px 0 4px}
html[data-theme="dark"] .conv-item .tags{display:flex;gap:4px;overflow:hidden;max-height:20px}
html[data-theme="dark"] .conv-item .badge{padding:2px 7px;font-size:9.5px;background:#202c33;color:#aebac1}
html[data-theme="dark"] .conv-item .badge.unread{background:#00a884;color:#062a21;font-size:11px;min-width:20px;height:20px;padding:0 6px}
html[data-theme="dark"] .search-section-title{background:#111b21;color:#8696a0;padding:18px 20px 10px;font-size:12px;text-transform:none}
html[data-theme="dark"] .contacts-results{border-top:8px solid #0b141a}

/* Estado vazio do painel direito */
.wa-empty-state{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:40px;color:#8696a0;background:#0b141a;border-bottom:6px solid #00a884}
.wa-empty-illustration{width:150px;height:120px;border-radius:28px;background:#111b21;display:grid;place-items:center;margin-bottom:24px;border:1px solid #18242b}
.wa-empty-illustration svg{width:62px;height:62px;color:#00a884}
.wa-empty-state h2{margin:0 0 8px;font-size:26px;font-weight:400;color:#e9edef}
.wa-empty-state p{margin:0 0 28px;font-size:14px}
.wa-empty-shortcuts{display:flex;gap:36px;justify-content:center;flex-wrap:wrap}
.wa-empty-shortcuts button{border:0;background:transparent;color:#d7e0e4;display:flex;flex-direction:column;align-items:center;gap:9px;font-size:12px}
.wa-empty-shortcuts button svg{width:25px;height:25px;padding:13px;box-sizing:content-box;border-radius:50%;background:#202c33;color:#e9edef}
.wa-empty-shortcuts button:hover svg{background:#2a3942;color:#00a884}

/* Chat aberto */
html[data-theme="dark"] .chat-head{min-height:64px;padding:9px 14px 9px 18px;background:#202c33;border-bottom:1px solid #2f3b43;gap:11px}
html[data-theme="dark"] .chat-head .mine-who{min-width:170px;margin-right:auto}
html[data-theme="dark"] .chat-head .mine-who strong{font-size:15px;font-weight:600;color:#e9edef}
html[data-theme="dark"] .chat-head .mine-who .muted{font-size:11.5px;color:#8696a0;margin-top:2px}
html[data-theme="dark"] .chat-head .toolbar{gap:5px;flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none}
html[data-theme="dark"] .chat-head .toolbar::-webkit-scrollbar{display:none}
html[data-theme="dark"] .chat-head .toolbar button{height:36px;padding:0 10px;border-radius:18px;font-size:11.5px;white-space:nowrap;background:#2a3942;border:0;color:#dce4e7}
html[data-theme="dark"] .chat-head .toolbar button:hover{background:#37464f}
html[data-theme="dark"] .chat-head .toolbar button.danger{background:#482a2e;color:#ffb4b4}
html[data-theme="dark"] .chat-head .toolbar button.primary{background:#005c4b;color:#e9edef}
html[data-theme="dark"] .chat-head .toolbar .badge{display:none}
html[data-theme="dark"] .chat-body{padding:22px clamp(22px,7vw,96px);background-color:#0b141a;background-image:linear-gradient(rgba(11,20,26,.92),rgba(11,20,26,.92)),radial-gradient(rgba(255,255,255,.05) 1px,transparent 1px);background-size:auto,22px 22px}
html[data-theme="dark"] .bubble{border-radius:8px;box-shadow:0 1px .5px rgba(0,0,0,.22)}
html[data-theme="dark"] .bubble.in{background:#202c33;color:#e9edef}
html[data-theme="dark"] .bubble.out{background:#005c4b;color:#e9edef}
html[data-theme="dark"] .composer-wrap{background:#202c33;border-top:1px solid #2f3b43}
html[data-theme="dark"] .composer{padding:10px 14px;grid-template-columns:42px 42px 42px minmax(0,1fr) auto;align-items:center}
html[data-theme="dark"] .composer>button.secondary{width:42px;height:42px;color:#aebac1}
html[data-theme="dark"] .composer>button.secondary:hover{background:#2a3942;color:#e9edef}
html[data-theme="dark"] .composer textarea{min-height:44px;background:#2a3942;border-radius:22px;color:#e9edef;padding:12px 16px}
html[data-theme="dark"] .composer #sendBtn{width:44px;height:44px;border-radius:50%;padding:0;font-size:0;background:#00a884;color:#062a21}
html[data-theme="dark"] .composer #sendBtn svg{width:20px;height:20px}

/* Demais telas do sistema no mesmo padrão visual */
html[data-theme="dark"] main>header{background:#202c33;border-bottom:1px solid #313d45;color:#e9edef}
html[data-theme="dark"] main>header h1{color:#e9edef}
html[data-theme="dark"] main>header p{color:#8696a0}
html[data-theme="dark"] .head-search input{background:#2a3942;color:#e9edef;border-radius:22px}
html[data-theme="dark"] .status-pill{background:#111b21;border-color:#313d45;color:#aebac1}
html[data-theme="dark"] #content:not(:has(.split)){background:#0b141a}
html[data-theme="dark"] .card{background:#111b21;border-color:#222d34;border-radius:12px;box-shadow:none}
html[data-theme="dark"] .table th{color:#8696a0;background:#111b21}
html[data-theme="dark"] .table tbody tr:hover{background:#202c33}
html[data-theme="dark"] input,html[data-theme="dark"] textarea,html[data-theme="dark"] select{background:#202c33;border-color:#313d45;color:#e9edef}
html[data-theme="dark"] button.primary{background:#00a884;color:#062a21;border-color:#00a884}
html[data-theme="dark"] button.primary:hover{background:#06cf9c}

@media(max-width:1100px){
  body[data-view="queue"] .split,body[data-view="mine"] .split,body[data-view="closed"] .split,body[data-view="search"] .split{grid-template-columns:minmax(340px,42vw) minmax(0,1fr)}
  .wa-list-head{padding-left:14px!important;padding-right:14px!important}
  html[data-theme="dark"] .chat-head .toolbar button{font-size:0;width:36px;padding:0;display:grid;place-items:center}
  html[data-theme="dark"] .chat-head .toolbar button svg{width:18px;height:18px}
}

@media(max-width:700px){
  body[data-view="queue"] .split,body[data-view="mine"] .split,body[data-view="closed"] .split,body[data-view="search"] .split{grid-template-columns:1fr;height:calc(100dvh - 60px)}
  body[data-view="queue"] #content,body[data-view="mine"] #content,body[data-view="closed"] #content,body[data-view="search"] #content{height:calc(100dvh - 60px)}
  .wa-view-name{display:none}
  .wa-list-brand>strong{font-size:20px}
}

/* === Correções TeleHub 2.4.1: rail fixo, filtros funcionais e etiquetas coloridas === */
html,body{height:100%;min-height:100%;overflow:hidden}
#app{position:fixed;inset:0;width:100%;height:100dvh;min-height:100dvh;overflow:hidden}
main{height:100dvh;min-height:0;overflow:hidden}
.sidebar{height:100dvh;min-height:0;overflow:hidden}
.sidebar-shell{height:100dvh;max-height:100dvh;min-height:0;overflow:hidden}
.nav-menu{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden;scrollbar-width:none}
.nav-menu::-webkit-scrollbar{display:none}
.sidebar-footer{flex:none;margin-top:8px}
#content{min-height:0;overflow:auto}
#content:has(.split){height:100%;min-height:0;overflow:hidden}
.split{height:100%!important;min-height:0}
.conv-list,.chat{height:100%;min-height:0}

/* Etiquetas: sem etiqueta continua no estilo normal */
html[data-theme="dark"] .conv-item .badge.conv-tag.tag-important,
.badge.conv-tag.tag-important{background:#5f1d24!important;color:#ffb3ba!important;border-color:#8e2f39!important}
html[data-theme="dark"] .conv-item .badge.conv-tag.tag-work,
.badge.conv-tag.tag-work{background:#5a4813!important;color:#ffe48a!important;border-color:#8c711e!important}
html[data-theme="dark"] .conv-item .badge.conv-tag.tag-progress,
.badge.conv-tag.tag-progress{background:#143d63!important;color:#9fd0ff!important;border-color:#245f93!important}
html[data-theme="dark"] .conv-item .badge.conv-tag.tag-done,
.badge.conv-tag.tag-done{background:#123f31!important;color:#9ee8c8!important;border-color:#226b55!important}

/* O filtro ativo fica claramente selecionado */
.wa-filter.active{box-shadow:inset 0 0 0 1px rgba(0,168,132,.35)}

/* Mesmo com zoom alto, a barra continua lateral e ocupa toda a tela */
@media(max-width:700px){
  #app{grid-template-columns:64px minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr)!important;height:100dvh!important}
  .sidebar{order:0!important;height:100dvh!important;border-right:1px solid #313d45!important;border-top:0!important}
  .sidebar-shell{height:100dvh!important;flex-direction:column!important;align-items:center!important;padding:8px 0!important;gap:0!important}
  .brand{display:block!important;padding:0 0 8px!important}
  .brand-icon{width:38px!important;height:38px!important}
  .nav-menu{flex-direction:column!important;overflow-y:auto!important;overflow-x:hidden!important;flex:1!important;width:100%!important;align-items:center!important;gap:3px!important}
  .nav-menu button{width:44px!important;height:44px!important;flex:none!important}
  .sidebar-footer{margin-top:6px!important;padding:6px 0 0!important;display:grid!important;gap:6px!important}
  main{height:100dvh!important;min-width:0!important}
  body[data-view="queue"] .split,body[data-view="mine"] .split,body[data-view="closed"] .split,body[data-view="search"] .split{height:100%!important}
  body[data-view="queue"] #content,body[data-view="mine"] #content,body[data-view="closed"] #content,body[data-view="search"] #content{height:auto!important}
}

/* === TeleHub 3.0.2 — correção completa do modo claro + seletor de etiquetas === */
html[data-theme="light"]{color-scheme:light}
html[data-theme="light"] body{
  --bg:#f0f2f5;--panel:#ffffff;--panel2:#f7f9fa;--panel3:#e9edef;
  --line:#e4e8eb;--line2:#d3dade;--text:#111b21;--muted:#667781;
  --accent:#00a884;--accent2:#008f72;--bar:#ffffff;--bar-dark:#f0f2f5;
  --rail:#f0f2f5;--rail-ic:#54656f;--chat-bg:#efeae2;
  --bubble-in:#ffffff;--bubble-out:#d9fdd3;
}
html[data-theme="light"] body,html[data-theme="light"] #app,html[data-theme="light"] main{background:var(--bg);color:var(--text)}
html[data-theme="light"] #app{grid-template-columns:72px minmax(0,1fr);background:#f0f2f5}
html[data-theme="light"] .sidebar{background:#f0f2f5;border-right:1px solid #d8dfe3}
html[data-theme="light"] .sidebar-shell{background:#f0f2f5;padding:10px 0 12px}
html[data-theme="light"] .brand{padding:0 0 12px}
html[data-theme="light"] .brand-icon{width:42px;height:42px;border-radius:50%;box-shadow:none;background:#fff;padding:5px}
html[data-theme="light"] .nav-menu{gap:5px}
html[data-theme="light"] .nav-menu button{width:48px;height:48px;border-radius:50%;color:#54656f;background:transparent;position:relative}
html[data-theme="light"] .nav-menu button:hover{background:#dfe5e8;color:#111b21}
html[data-theme="light"] .nav-menu button.active{background:#fff;color:#00a884;box-shadow:0 1px 4px rgba(11,20,26,.12)}
html[data-theme="light"] .nav-menu button.active::before{content:"";position:absolute;right:-12px;top:9px;width:4px;height:30px;border-radius:4px;background:#00a884}
html[data-theme="light"] .sidebar-footer{border-top:1px solid #d8dfe3;padding-top:10px}
html[data-theme="light"] #me{width:44px;height:44px;border-radius:50%;overflow:hidden;background:#d9fdd3;display:grid;place-items:center;font-size:0}
html[data-theme="light"] #me::after{content:"TH";font-size:12px;font-weight:800;color:#008f72}
html[data-theme="light"] #logoutBtn{width:44px;height:44px;border-radius:50%;font-size:0;padding:0;background:transparent;border:0}

html[data-theme="light"] body[data-view="queue"] .split,
html[data-theme="light"] body[data-view="mine"] .split,
html[data-theme="light"] body[data-view="closed"] .split,
html[data-theme="light"] body[data-view="search"] .split{background:#f0f2f5}
html[data-theme="light"] .conv-list{background:#fff;border-right:1px solid #d8dfe3}
html[data-theme="light"] .chat{background:#efeae2}
html[data-theme="light"] .wa-list-head{background:#fff!important;border-bottom:1px solid #eef1f2}
html[data-theme="light"] .wa-list-brand>strong{color:#111b21}
html[data-theme="light"] .wa-icon-btn{color:#111b21}
html[data-theme="light"] .wa-icon-btn:hover{background:#f0f2f5}
html[data-theme="light"] .wa-new-btn{background:#00a884;color:#062a21}
html[data-theme="light"] .wa-list-head .search-box input{background:#f0f2f5!important;color:#111b21!important;border-color:transparent!important}
html[data-theme="light"] .wa-list-head .search-box input::placeholder{color:#667781!important}
html[data-theme="light"] .wa-list-head .search-box svg,html[data-theme="light"] .wa-list-head .search-clear{color:#667781}
html[data-theme="light"] .wa-list-head .search-box:focus-within input{background:#fff!important;border-color:#00a884!important;box-shadow:inset 0 0 0 1px #00a884!important}
html[data-theme="light"] .wa-filter{background:#fff;border-color:#d8dfe3;color:#54656f}
html[data-theme="light"] .wa-filter:hover{background:#f0f2f5;color:#111b21}
html[data-theme="light"] .wa-filter.active{background:#e7f7f1;border-color:#bfe8d9;color:#008f72;box-shadow:inset 0 0 0 1px rgba(0,168,132,.16)}
html[data-theme="light"] .wa-sector-row select{background:#f0f2f5!important;color:#3b4a54!important;border:1px solid #e0e5e8!important}
html[data-theme="light"] .wa-sector-row .mine-count{color:#8696a0}
html[data-theme="light"] #convItems{background:#fff}
html[data-theme="light"] .conv-item{grid-template-columns:52px minmax(0,1fr) auto;gap:12px;padding:12px 14px 11px 20px;min-height:72px;align-items:center;background:#fff}
html[data-theme="light"] .conv-item::after{left:84px;background:#eef1f2}
html[data-theme="light"] .conv-item:hover{background:#f5f6f6}
html[data-theme="light"] .conv-item.active{background:#f0f2f5}
html[data-theme="light"] .avatar{width:52px;height:52px;border-radius:50%;background:linear-gradient(145deg,#d9fdd3,#b9eadc);color:#08765e;font-size:17px;border:1px solid #c8e8de}
html[data-theme="light"] .conv-title strong{font-size:16px;color:#111b21;font-weight:500}
html[data-theme="light"] .conv-title small{color:#667781;font-size:11.5px}
html[data-theme="light"] .conv-preview{font-size:13.5px;color:#667781;margin:4px 0 4px}
html[data-theme="light"] .conv-item .tags{display:flex;gap:4px;overflow:hidden;max-height:21px}
html[data-theme="light"] .conv-item .badge{padding:2px 7px;font-size:9.5px;background:#f0f2f5;color:#54656f;border-color:#e4e8eb}
html[data-theme="light"] .conv-item .badge.unread{background:#25d366;color:#063a2a;font-size:11px;min-width:20px;height:20px;padding:0 6px}
html[data-theme="light"] .search-section-title{background:#fff;color:#667781}
html[data-theme="light"] .contacts-results{border-top-color:#f0f2f5}
html[data-theme="light"] .search-contact-item::after{background:#eef1f2}
html[data-theme="light"] .search-contact-item:hover{background:#f5f6f6}

html[data-theme="light"] .wa-empty-state{background:#f7f9fa;color:#667781;border-bottom-color:#25d366}
html[data-theme="light"] .wa-empty-illustration{background:#fff;border-color:#e4e8eb;box-shadow:0 1px 2px rgba(11,20,26,.05)}
html[data-theme="light"] .wa-empty-illustration svg{color:#00a884}
html[data-theme="light"] .wa-empty-state h2{color:#3b4a54}
html[data-theme="light"] .wa-empty-shortcuts button{color:#3b4a54}
html[data-theme="light"] .wa-empty-shortcuts button svg{background:#fff;color:#54656f;border:1px solid #e4e8eb}
html[data-theme="light"] .wa-empty-shortcuts button:hover svg{background:#e7f7f1;color:#00a884}

html[data-theme="light"] .chat-head{min-height:64px;padding:9px 14px 9px 18px;background:#f0f2f5;border-bottom:1px solid #d8dfe3;gap:11px}
html[data-theme="light"] .chat-head .mine-who strong{color:#111b21}
html[data-theme="light"] .chat-head .mine-who .muted{color:#667781}
html[data-theme="light"] .chat-head .toolbar button{height:36px;padding:0 10px;border-radius:18px;font-size:11.5px;white-space:nowrap;background:#fff;border:1px solid #d8dfe3;color:#3b4a54}
html[data-theme="light"] .chat-head .toolbar button:hover{background:#e9edef}
html[data-theme="light"] .chat-head .toolbar button.danger{background:#fff1f1;color:#b42323;border-color:#f2cccc}
html[data-theme="light"] .chat-head .toolbar button.primary{background:#00a884;color:#fff;border-color:#00a884}
html[data-theme="light"] .chat-head .toolbar .badge{display:none}
html[data-theme="light"] .chat-body{padding:22px clamp(22px,7vw,96px);background-color:#efeae2;background-image:radial-gradient(rgba(11,20,26,.055) 1px,transparent 1px);background-size:22px 22px}
html[data-theme="light"] .bubble{border-radius:8px;box-shadow:0 1px .5px rgba(11,20,26,.13)}
html[data-theme="light"] .bubble.in{background:#fff;color:#111b21}
html[data-theme="light"] .bubble.out{background:#d9fdd3;color:#111b21}
html[data-theme="light"] .composer-wrap{background:#f0f2f5;border-top:1px solid #d8dfe3}
html[data-theme="light"] .composer{padding:10px 14px;grid-template-columns:42px 42px 42px minmax(0,1fr) auto;align-items:center}
html[data-theme="light"] .composer>button.secondary{width:42px;height:42px;color:#54656f;background:transparent;border-color:transparent}
html[data-theme="light"] .composer>button.secondary:hover{background:#e1e6e9;color:#111b21}
html[data-theme="light"] .composer textarea{min-height:44px;background:#fff;border:1px solid #e0e5e8;border-radius:22px;color:#111b21;padding:12px 16px}
html[data-theme="light"] .composer #sendBtn{width:44px;height:44px;border-radius:50%;padding:0;font-size:0;background:#00a884;color:#fff;border-color:#00a884}
html[data-theme="light"] .reply-bar{background:#f7f9fa;border-color:#e0e5e8}

/* Cores das etiquetas no modo claro */
html[data-theme="light"] .badge.conv-tag.tag-important{background:#fde7e9!important;color:#b4232c!important;border-color:#f5b6bc!important}
html[data-theme="light"] .badge.conv-tag.tag-work{background:#fff4cc!important;color:#8b6500!important;border-color:#f0d36c!important}
html[data-theme="light"] .badge.conv-tag.tag-progress{background:#e5f1ff!important;color:#175ea8!important;border-color:#a8cdf5!important}
html[data-theme="light"] .badge.conv-tag.tag-done{background:#e1f5eb!important;color:#087a55!important;border-color:#a9dfc8!important}

/* Seletor visual de etiqueta */
.tag-choice-preview{min-height:40px;display:flex;align-items:center;padding:6px 0 2px}
.tag-choice-preview .badge.conv-tag{font-size:12px;padding:6px 10px;border-radius:999px}

/* Correção de contraste dos botões Cancelar */
#cancel,
#cancelPaste,
#cancelAudio,
.modal-card .actions > button:not(.primary):not(.danger),
.paste-preview-actions > button:not(.primary):not(.danger),
.audio-review > button:not(.primary):not(.danger){
  background:#334155 !important;
  border-color:#334155 !important;
  color:#ffffff !important;
  box-shadow:none !important;
}
#cancel:hover,
#cancelPaste:hover,
#cancelAudio:hover,
.modal-card .actions > button:not(.primary):not(.danger):hover,
.paste-preview-actions > button:not(.primary):not(.danger):hover,
.audio-review > button:not(.primary):not(.danger):hover{
  background:#1f2937 !important;
  border-color:#1f2937 !important;
  color:#ffffff !important;
}
html[data-theme="dark"] #cancel,
html[data-theme="dark"] #cancelPaste,
html[data-theme="dark"] #cancelAudio,
html[data-theme="dark"] .modal-card .actions > button:not(.primary):not(.danger),
html[data-theme="dark"] .paste-preview-actions > button:not(.primary):not(.danger),
html[data-theme="dark"] .audio-review > button:not(.primary):not(.danger){
  background:#37434b !important;
  border-color:#4a5963 !important;
  color:#f2f6f7 !important;
}
html[data-theme="dark"] #cancel:hover,
html[data-theme="dark"] #cancelPaste:hover,
html[data-theme="dark"] #cancelAudio:hover,
html[data-theme="dark"] .modal-card .actions > button:not(.primary):not(.danger):hover,
html[data-theme="dark"] .paste-preview-actions > button:not(.primary):not(.danger):hover,
html[data-theme="dark"] .audio-review > button:not(.primary):not(.danger):hover{
  background:#45545e !important;
  border-color:#5c6c76 !important;
  color:#ffffff !important;
}

/* ===== MÓDULO COMERCIAL ===== */
.commercial-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:14px}.commercial-tabs button{border:1px solid var(--border);background:var(--panel);color:var(--text);border-radius:999px;padding:10px 16px;font-weight:700}.commercial-tabs button.active{background:var(--green);color:#fff;border-color:var(--green)}
.commercial-flow{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:18px}.commercial-flow span{padding:10px 14px;border-radius:12px;background:var(--soft);font-weight:700}.commercial-flow b{color:var(--muted)}
.lead-filters{display:grid;grid-template-columns:minmax(220px,1.3fr) minmax(180px,1fr) minmax(220px,1fr) auto;gap:10px;margin:16px 0}.bulk-bar{display:flex;gap:12px;align-items:center;flex-wrap:wrap;padding:12px;border-radius:14px;background:var(--soft);margin-bottom:12px}.bulk-bar strong{margin-right:auto}.lead-table td{vertical-align:middle}.lead-table td:nth-child(5){max-width:260px}.lead-table td:nth-child(5),.lead-table td:nth-child(4){white-space:normal}.cstatus-novo{background:#e8eef5;color:#34495e}.cstatus-abordado{background:#dbeafe;color:#1d4ed8}.cstatus-respondido{background:#fef3c7;color:#92400e}.cstatus-convertido{background:#dcfce7;color:#166534}.cstatus-sem_interesse{background:#fee2e2;color:#991b1b}
.wizard-steps{display:flex;gap:8px;margin:10px 0 16px}.wizard-steps span{padding:7px 10px;border-radius:999px;background:var(--soft);font-size:12px;font-weight:800}.wizard-steps span.active{background:var(--green);color:white}.approach-preview{max-height:240px;overflow:auto;margin:12px 0}.approach-preview>div{border:1px solid var(--border);border-radius:12px;padding:10px;margin-bottom:8px}.approach-preview p{white-space:pre-wrap;margin:5px 0 0}
.campaign-row{display:flex;align-items:center;gap:14px;border-top:1px solid var(--border);padding:16px 0}.campaign-row>div{flex:1}.progress{height:7px;border-radius:999px;background:var(--soft);overflow:hidden;margin-top:8px}.progress i{display:block;height:100%;background:var(--green);border-radius:inherit}.commercial-chat-layout{display:grid;grid-template-columns:340px minmax(0,1fr);gap:14px;min-height:65vh}.commercial-conv-list{padding:12px}.commercial-conv{display:grid;width:100%;text-align:left;padding:13px;border:0;border-bottom:1px solid var(--border);background:transparent;color:var(--text)}.commercial-conv:hover{background:var(--soft)}.commercial-conv span{color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:4px}.commercial-conv small{color:var(--muted);margin-top:4px}.cchat-messages{height:52vh;overflow:auto;background:var(--chat-bg,var(--soft));border-radius:14px;padding:14px;margin-bottom:12px}.cmsg{max-width:72%;padding:10px 12px;border-radius:12px;background:var(--panel);margin:8px 0;border:1px solid var(--border)}.cmsg.out{margin-left:auto;background:color-mix(in srgb,var(--green) 16%,var(--panel))}.cmsg p{white-space:pre-wrap;margin:0}.cmsg small{display:block;text-align:right;color:var(--muted);margin-top:5px}.empty.compact{height:180px}
@media(max-width:1050px){.lead-filters{grid-template-columns:1fr 1fr}.commercial-chat-layout{grid-template-columns:1fr}.commercial-conv-list{max-height:280px;overflow:auto}}
@media(max-width:700px){.lead-filters{grid-template-columns:1fr}.commercial-flow b{display:none}}

/* ===== Comercial: menu lateral + construtor de abordagem ===== */
.approach-builder{border:1px solid var(--border);background:var(--panel);border-radius:16px;padding:14px;margin:12px 0}
.approach-builder-head,.whatsapp-preview-title{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:10px}
.approach-token-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:10px 0 14px}
.approach-token{min-width:0;border:1px solid var(--border);background:var(--soft);color:var(--text);border-radius:12px;padding:9px 10px;text-align:left;cursor:pointer;display:grid;gap:3px;transition:.15s ease}
.approach-token:hover{border-color:var(--green);transform:translateY(-1px)}
.approach-token code{font-size:12px;font-weight:900;color:var(--green);overflow-wrap:anywhere}
.approach-token small{font-size:11px;color:var(--muted)}
.whatsapp-preview-wrap{margin:14px 0}
.whatsapp-preview{border:1px solid var(--border);border-radius:16px;overflow:hidden;background:#efeae2}
.wa-preview-chat{min-height:210px;background:#efeae2}
.wa-preview-contact{height:58px;background:#f0f2f5;display:flex;align-items:center;gap:10px;padding:8px 12px;color:#111b21;border-bottom:1px solid #d8dfe3}
.wa-preview-contact>div{display:grid;gap:2px}.wa-preview-contact small{color:#667781;font-size:11px}
.wa-preview-avatar{width:40px;height:40px;border-radius:50%;display:grid;place-items:center;background:#d9fdd3;color:#08775b;font-weight:900}
.wa-preview-bg{padding:24px 18px;background-color:#efeae2;background-image:radial-gradient(rgba(17,27,33,.045) 1px,transparent 1px);background-size:14px 14px;min-height:150px}
.wa-preview-bubble{margin-left:auto;max-width:min(82%,620px);background:#d9fdd3;color:#111b21;border-radius:9px 9px 2px 9px;padding:9px 11px 7px;line-height:1.45;box-shadow:0 1px 1px rgba(0,0,0,.08);white-space:normal}
.wa-preview-time{float:right;font-size:10px;color:#667781;margin:8px 0 0 12px;white-space:nowrap}
.preview-loading{padding:28px;color:#667781;text-align:center}
html[data-theme="dark"] .approach-builder{background:#111b21}
html[data-theme="dark"] .approach-token{background:#202c33;border-color:#34414a;color:#e9edef}
html[data-theme="dark"] .approach-token small{color:#8696a0}
html[data-theme="dark"] .whatsapp-preview{border-color:#34414a}
@media(max-width:760px){.approach-token-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:480px){.approach-token-grid{grid-template-columns:1fr}.wa-preview-bubble{max-width:92%}}

/* Comercial V2 */
.commercial-metrics{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}.commercial-metrics .metric strong{font-size:28px}.funnel{display:grid;gap:8px}.funnel>div{display:flex;align-items:center;justify-content:space-between;padding:11px 13px;border:1px solid var(--border);border-radius:12px;background:var(--panel)}.funnel b{font-size:18px}.alert-card{margin-top:12px;padding:12px 14px;border:1px solid var(--border);border-radius:12px;display:flex;justify-content:space-between;gap:12px}.alert-card.warn{border-color:#d97706}.task-row{display:grid;grid-template-columns:auto 1fr auto;gap:12px;align-items:center;padding:12px 0;border-bottom:1px solid var(--border)}.task-row.done{opacity:.55}.template-row{padding:14px 0;border-bottom:1px solid var(--border)}.template-row .badge{margin-left:8px}.template-row p{white-space:pre-wrap;margin:7px 0 0;color:var(--muted)}.link-btn{background:none!important;border:0!important;padding:0!important;color:inherit!important;text-align:left!important;cursor:pointer}.compact-select{min-width:130px;padding:7px 9px!important}.lead-profile{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:10px 0 14px}.lead-profile>div{display:flex;flex-direction:column;padding:10px;border:1px solid var(--border);border-radius:10px}.lead-profile small{color:var(--muted);margin-bottom:3px}.timeline{display:grid;gap:8px;max-height:260px;overflow:auto}.timeline>div{display:grid;grid-template-columns:150px 1fr;gap:10px;padding:9px 0;border-bottom:1px solid var(--border)}.timeline b{font-size:12px;color:var(--muted)}
@media(max-width:1100px){.commercial-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}}@media(max-width:700px){.commercial-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.lead-profile{grid-template-columns:1fr}.timeline>div{grid-template-columns:1fr}}


/* ===== TeleHub visual atualizado — sem Perfil/Chat interno ===== */
.theme-toggle .theme-icon{display:grid;place-items:center}.theme-toggle svg.i{width:20px;height:20px}
html[data-theme] .nav-menu button{border-radius:14px}
html[data-theme] .nav-menu button.active::before{right:auto;left:-12px;width:4px;height:26px;top:11px;border-radius:0 4px 4px 0;background:#00a884}
html[data-theme="dark"] .nav-menu button.active{background:rgba(0,168,132,.16);color:#3ddbb0}
html[data-theme="light"] .nav-menu button.active{background:rgba(0,168,132,.12);color:#008069;box-shadow:none}
.cmsg.internal{margin:10px auto!important;max-width:80%;background:var(--soft)!important;border:1px dashed var(--border);color:var(--text);text-align:center}.cmsg.internal small{display:block;color:var(--muted)}
button.success{background:#16a34a!important;border-color:#16a34a!important;color:#fff!important;font-weight:800}
.danger-text{margin-top:7px;color:#dc2626;font-weight:700;font-size:12px}

/* Abordagens comerciais - erros de envio visíveis */
.campaign-errors{margin-top:9px;display:grid;gap:5px}
.campaign-error{font-size:12px;line-height:1.35;padding:7px 9px;border-radius:8px;background:rgba(239,68,68,.10);color:#ef4444;border:1px solid rgba(239,68,68,.18)}
body.light .campaign-error{background:#fff1f2;color:#b91c1c;border-color:#fecdd3}


/* Tele Hub: alertas sonoros e instalação como aplicativo */
.sound-toggle.sound-off{opacity:.68}.sound-toggle .sound-icon{font-size:18px;line-height:1}
.install-app-btn{font-size:11px!important;line-height:1.1!important;padding:8px 6px!important;white-space:normal}
.install-app-preview{display:flex;align-items:center;gap:14px;padding:14px;border:1px solid var(--border,#d8dfe3);border-radius:12px;margin:14px 0;background:var(--surface-2,rgba(127,127,127,.06))}
.install-app-preview img{width:56px;height:56px;border-radius:14px}.install-app-preview div{display:grid;gap:3px}.install-app-preview strong{font-size:17px}.install-app-preview span{font-size:12px;color:var(--muted,#687781);word-break:break-all}
html.pwa-installable .install-app-btn{outline:2px solid rgba(37,211,102,.32);outline-offset:2px}
@media(max-width:900px){.install-app-btn{font-size:0!important;width:38px;height:38px;padding:0!important}.install-app-btn::before{content:'↧';font-size:20px}}

/* Conversas comerciais — lista limpa + funil Kanban */
.commercial-conv-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:14px}.commercial-conv-toolbar h3{margin:0 0 3px}.commercial-view-switch{display:flex;gap:6px;padding:4px;background:var(--soft);border:1px solid var(--border);border-radius:12px}.commercial-view-switch button{border:0;background:transparent;color:var(--muted);padding:9px 13px;border-radius:9px;font-weight:700;cursor:pointer}.commercial-view-switch button.active{background:var(--green);color:#fff}.commercial-conv-search-wrap{padding:4px 4px 10px}.commercial-conv-search-wrap input{width:100%}.commercial-conv-list{overflow:hidden}.commercial-conv-list #commercialConvItems{max-height:62vh;overflow:auto}.commercial-conv{position:relative;display:grid!important;grid-template-columns:44px minmax(0,1fr) auto!important;gap:11px;align-items:center;width:100%;padding:12px 9px!important;border-bottom:1px solid var(--border)!important}.commercial-avatar{width:44px;height:44px;border-radius:50%;display:grid;place-items:center;background:color-mix(in srgb,var(--green) 18%,var(--panel));color:var(--green);font-weight:800;flex:none}.commercial-avatar.small{width:34px;height:34px;font-size:13px}.commercial-conv-main{min-width:0;display:block}.commercial-conv-top{display:flex;align-items:center;justify-content:space-between;gap:8px}.commercial-conv-top strong{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.commercial-conv-top small,.commercial-conv-phone{color:var(--muted);font-size:11px}.commercial-conv-phone{display:block;margin-top:1px}.commercial-conv-preview{display:block;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:4px;font-size:13px}.commercial-stage-pill{display:inline-flex;margin-top:7px;padding:3px 8px;border-radius:999px;font-size:10px;font-weight:800;background:color-mix(in srgb,var(--green) 13%,var(--panel));color:var(--green)}.commercial-unread{min-width:22px;height:22px;border-radius:99px;display:grid;place-items:center;background:var(--green);color:#fff;font-size:11px;font-weight:800}.commercial-chat-head{padding-bottom:10px;border-bottom:1px solid var(--border)}.commercial-chat-compose{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:center}.commercial-chat-compose input{width:100%}
.commercial-kanban{display:flex;gap:12px;overflow-x:auto;padding:2px 2px 14px;align-items:flex-start}.commercial-kanban-col{width:285px;min-width:285px;border:1px solid var(--border);border-radius:14px;background:var(--panel);overflow:hidden}.commercial-kanban-col>header{display:flex;align-items:center;justify-content:space-between;padding:12px 13px;background:linear-gradient(135deg,color-mix(in srgb,var(--green) 88%,#07120e),color-mix(in srgb,var(--green) 65%,#07120e));color:#fff}.commercial-kanban-col>header strong{font-size:13px}.commercial-kanban-col>header span{display:grid;place-items:center;min-width:24px;height:24px;border-radius:99px;background:rgba(255,255,255,.18);font-size:11px;font-weight:800}.commercial-kanban-drop{min-height:190px;max-height:65vh;overflow-y:auto;padding:8px;background:color-mix(in srgb,var(--soft) 58%,var(--panel))}.commercial-kanban-drop.drag-over{outline:2px dashed var(--green);outline-offset:-5px;background:color-mix(in srgb,var(--green) 8%,var(--panel))}.commercial-kanban-card{background:var(--panel);border:1px solid var(--border);border-radius:11px;padding:10px;margin-bottom:8px;cursor:pointer;box-shadow:0 1px 2px rgba(0,0,0,.06)}.commercial-kanban-card[draggable="true"]{cursor:grab}.commercial-kanban-card.dragging{opacity:.45}.commercial-kanban-card:hover{border-color:color-mix(in srgb,var(--green) 55%,var(--border))}.kanban-card-top{display:grid;grid-template-columns:34px minmax(0,1fr) auto;gap:8px;align-items:center}.kanban-card-top>div{min-width:0}.kanban-card-top strong,.kanban-card-top small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kanban-card-top small{color:var(--muted);font-size:10px;margin-top:2px}.kanban-card-top b{min-width:20px;height:20px;border-radius:99px;display:grid;place-items:center;background:var(--green);color:#fff;font-size:10px}.commercial-kanban-card p{margin:9px 0 8px;color:var(--muted);font-size:12px;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.commercial-kanban-card footer{display:flex;align-items:center;justify-content:space-between;gap:7px;color:var(--muted);font-size:10px}.commercial-kanban-card footer em{font-style:normal;padding:2px 6px;border-radius:999px;background:color-mix(in srgb,var(--green) 10%,var(--panel));color:var(--green)}.kanban-empty{padding:24px 10px;text-align:center;color:var(--muted);font-size:11px;border:1px dashed var(--border);border-radius:9px}.stage-convertido{background:color-mix(in srgb,var(--green) 22%,var(--panel));color:var(--green)}
@media(max-width:900px){.commercial-conv-toolbar{align-items:flex-start;flex-direction:column}.commercial-view-switch{width:100%}.commercial-view-switch button{flex:1}.commercial-chat-compose{grid-template-columns:1fr}.commercial-chat-compose button{width:100%}}

/* Conversas comerciais no mesmo padrão visual do atendimento ADM */
.commercial-adm-split{height:calc(100vh - 92px);min-height:620px;gap:0;background:var(--panel);border:1px solid var(--border);border-radius:0;overflow:hidden}
.commercial-adm-list{min-width:0;border-right:1px solid var(--border);background:var(--panel)}
.commercial-adm-list #commercialConvItems{height:calc(100% - 210px);overflow:auto}
.commercial-adm-chat{min-width:0;background:var(--chat-bg,#0b141a)}
.commercial-adm-conv{cursor:pointer}
.commercial-adm-conv.active{background:var(--soft)}
.commercial-adm-conv-body{min-width:0}
.commercial-adm-conv .commercial-stage-pill{margin-top:6px}
.commercial-funnel-btn{font-size:19px;line-height:1}
.commercial-funnel-chip{font-weight:800}
.commercial-filter-row{flex-wrap:wrap}
.commercial-funnel-top{display:flex;align-items:center;gap:14px;margin-bottom:14px}.commercial-funnel-top h3{margin:0 0 3px}
.commercial-wa-empty{border-bottom:0}
.commercial-adm-chat .cchat-messages{height:calc(100% - 150px);min-height:380px;border-radius:0;margin:0;padding:22px 5%;background:var(--chat-bg,#0b141a)}
.commercial-adm-chat .commercial-chat-head{padding:12px 16px;margin:0;background:var(--panel)}
.commercial-adm-chat .commercial-chat-compose{padding:12px 16px;background:var(--panel);border-top:1px solid var(--border)}
html[data-theme="light"] .commercial-adm-chat{background:#efeae2}
html[data-theme="light"] .commercial-adm-chat .cchat-messages{background:#efeae2}
@media(max-width:900px){.commercial-adm-split{height:auto;min-height:0;grid-template-columns:1fr}.commercial-adm-list #commercialConvItems{max-height:360px;height:auto}.commercial-adm-chat .cchat-messages{height:420px;min-height:0}}

/* Chat Comercial CRM 3 colunas */
.commercial-crm-shell{height:100%;display:grid;grid-template-columns:minmax(0,1fr) 330px;min-width:0;background:var(--chat-bg,#0b141a)}
.commercial-chat-main{min-width:0;display:flex;flex-direction:column;height:100%;position:relative}
.commercial-chat-person{display:flex;align-items:center;gap:10px;min-width:0}.commercial-chat-person h3{margin:0}.commercial-chat-person .avatar{width:40px;height:40px;flex:none}
.commercial-chat-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.commercial-chat-actions button{white-space:nowrap}
.commercial-crm-shell .cchat-messages{flex:1;height:auto!important;min-height:0!important;overflow:auto}
.commercial-chat-compose{grid-template-columns:minmax(0,1fr) auto!important}.commercial-chat-compose textarea{width:100%;min-height:44px;max-height:120px;resize:vertical;border:1px solid var(--border);border-radius:12px;padding:11px 13px;background:var(--input-bg,var(--soft));color:var(--text);font:inherit}
.commercial-crm-panel{border-left:1px solid var(--border);background:var(--panel);overflow:auto;padding:14px;min-width:0}.commercial-adm-chat.crm-hidden .commercial-crm-shell{grid-template-columns:minmax(0,1fr)}.commercial-adm-chat.crm-hidden .commercial-crm-panel{display:none}
.commercial-crm-title{display:flex;justify-content:space-between;align-items:center;padding-bottom:12px;border-bottom:1px solid var(--border)}.commercial-crm-title>div{display:grid;gap:2px}.commercial-crm-title span{font-size:11px;color:var(--muted)}
.commercial-client-card{display:flex;align-items:center;gap:11px;padding:15px 0}.commercial-client-avatar{width:46px;height:46px;border-radius:50%;display:grid;place-items:center;background:color-mix(in srgb,var(--green) 18%,var(--panel));color:var(--green);font-weight:900}.commercial-client-card>div:last-child{min-width:0;display:grid}.commercial-client-card span{font-size:12px;color:var(--muted)}
.commercial-crm-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}.commercial-crm-grid label{font-size:10px;color:var(--muted);text-transform:uppercase;font-weight:800}.commercial-crm-grid select{display:block;width:100%;margin-top:5px;text-transform:none;font-weight:600}
.commercial-crm-info{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:12px}.commercial-crm-info>div{border:1px solid var(--border);border-radius:10px;padding:9px;min-width:0}.commercial-crm-info span,.commercial-crm-info strong{display:block}.commercial-crm-info span{font-size:10px;color:var(--muted);margin-bottom:3px}.commercial-crm-info strong{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.commercial-crm-section{border-top:1px solid var(--border);padding-top:13px;margin-top:13px}.commercial-crm-section-title{display:flex;justify-content:space-between;gap:8px;align-items:center;margin-bottom:9px}.commercial-crm-section-title span{font-size:10px;color:var(--muted)}.commercial-crm-section textarea{width:100%;resize:vertical}.crm-full{width:100%;margin-top:7px}
.crm-followup-actions{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}.crm-followup-actions button,.crm-custom-followup button{border:1px solid var(--border);background:var(--soft);color:var(--text);border-radius:9px;padding:8px;cursor:pointer}.crm-custom-followup{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;margin-top:7px}.crm-custom-followup input{min-width:0}.crm-next-task{font-size:11px;color:var(--green);margin-top:8px;font-weight:700}
.crm-timeline{display:grid;gap:10px}.crm-timeline-item{display:grid;grid-template-columns:10px minmax(0,1fr);gap:7px}.crm-timeline-item i{width:7px;height:7px;border-radius:50%;background:var(--green);margin-top:5px}.crm-timeline-item strong,.crm-timeline-item span{display:block}.crm-timeline-item strong{font-size:11px}.crm-timeline-item span{font-size:10px;color:var(--muted);margin-top:2px}
.commercial-quick-wrap{padding:7px 16px 0;background:var(--panel);position:relative}.quick-toggle{border:0;background:transparent;color:var(--green);font-weight:800;cursor:pointer;padding:5px 0}.commercial-quick-list{position:absolute;left:16px;bottom:38px;z-index:20;width:min(420px,calc(100% - 32px));max-height:240px;overflow:auto;background:var(--panel);border:1px solid var(--border);border-radius:12px;padding:7px;box-shadow:0 12px 30px rgba(0,0,0,.22)}.commercial-quick-list button{display:block;width:100%;text-align:left;border:0;background:transparent;color:var(--text);padding:9px;border-radius:8px;cursor:pointer}.commercial-quick-list button:hover{background:var(--soft)}
.commercial-slash-suggestions{position:absolute;left:16px;right:16px;bottom:78px;z-index:25;background:var(--panel);border:1px solid var(--border);border-radius:12px;padding:6px;max-height:260px;overflow:auto;box-shadow:0 12px 30px rgba(0,0,0,.22)}.commercial-slash-suggestions button{width:100%;display:grid;text-align:left;border:0;background:transparent;color:var(--text);padding:9px;border-radius:8px;cursor:pointer}.commercial-slash-suggestions button:hover{background:var(--soft)}.commercial-slash-suggestions span{font-size:11px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cmsg.internal{margin-left:auto;margin-right:auto;max-width:86%;background:color-mix(in srgb,var(--green) 8%,var(--panel));border-style:dashed;text-align:center}.cmsg.internal small{text-align:center}
@media(max-width:1180px){.commercial-crm-shell{grid-template-columns:minmax(0,1fr) 285px}.commercial-crm-info{grid-template-columns:1fr}}
@media(max-width:900px){.commercial-crm-shell{grid-template-columns:1fr}.commercial-crm-panel{display:none}.commercial-adm-chat:not(.crm-hidden) .commercial-crm-panel{display:block;border-left:0;border-top:1px solid var(--border)}.commercial-chat-head{align-items:flex-start!important;gap:10px}.commercial-chat-actions{justify-content:flex-end}.commercial-crm-grid,.commercial-crm-info{grid-template-columns:1fr 1fr}}

/* Comercial: barra de mensagem e mídia no padrão WhatsApp */
.whatsapp-composer{display:grid!important;grid-template-columns:44px 44px minmax(0,1fr) auto!important;gap:7px!important;align-items:end!important;padding:10px 12px!important}
.composer-icon-btn{width:42px;height:42px;border:0;border-radius:50%;display:grid;place-items:center;background:transparent;color:var(--muted);cursor:pointer}
.composer-icon-btn:hover{background:var(--soft);color:var(--text)}
.composer-icon-btn.recording{background:#d93025;color:#fff}
.c-send-btn{min-height:42px;display:flex;gap:7px;align-items:center;justify-content:center}
.commercial-media-preview{padding:0 14px;background:var(--panel)}
.commercial-preview-card{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:12px;border:1px solid var(--border);border-radius:14px;background:var(--soft);margin:10px 0}
.commercial-preview-content{display:flex;align-items:center;gap:12px;min-width:0;flex:1}.commercial-preview-content img,.commercial-preview-content video{max-width:210px;max-height:170px;border-radius:10px;object-fit:contain;background:#000}.commercial-preview-content audio{max-width:320px;width:100%}
.media-file-icon{width:48px;height:48px;border-radius:12px;background:var(--panel);display:grid;place-items:center;color:var(--green);border:1px solid var(--border)}.media-file-meta{display:flex;flex-direction:column;min-width:0}.media-file-meta strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.media-file-meta span{font-size:12px;color:var(--muted)}
.commercial-preview-actions{display:flex;gap:8px;flex:none}.cancel-visible{background:#3f4850!important;color:#fff!important;border-color:#3f4850!important}.cancel-visible:hover{background:#2f363c!important}
.commercial-recording{display:flex;align-items:center;gap:10px;padding:12px;border:1px solid var(--border);border-radius:14px;background:var(--soft);margin:10px 0}.commercial-recording .recording-dot{width:10px;height:10px;border-radius:50%;background:#e53935;animation:pulseRecord 1s infinite}.commercial-recording button{margin-left:auto}
@keyframes pulseRecord{50%{opacity:.35}}
.cmsg .chat-image-link img{max-width:min(340px,100%)!important}.cmsg .chat-audio audio{width:min(330px,100%)}.cmsg video{max-width:min(360px,100%)!important}.cmsg .file-link{display:flex;align-items:center;gap:8px;padding:10px 12px;border-radius:10px;background:color-mix(in srgb,var(--soft) 85%,transparent);color:var(--text);text-decoration:none;border:1px solid var(--border)}
/* CRM: X sempre legível nos temas claro e escuro */
.crm-close-btn{width:36px;height:36px;display:grid;place-items:center;border:1px solid var(--border)!important;border-radius:10px;background:var(--soft)!important;color:var(--text)!important;font-size:24px;line-height:1;cursor:pointer}.crm-close-btn:hover{background:color-mix(in srgb,var(--soft) 70%,var(--text) 10%)!important;color:var(--text)!important}
/* Dados do CRM arrastáveis para o campo da mensagem */
.crm-all-data{display:grid!important;grid-template-columns:1fr!important;gap:0!important;border:1px solid var(--border);border-radius:12px;overflow:hidden}.crm-drag-row{display:grid;grid-template-columns:92px minmax(0,1fr);gap:7px 10px;padding:9px 10px;background:var(--panel);border-bottom:1px solid var(--border);cursor:grab}.crm-drag-row:last-child{border-bottom:0}.crm-drag-row:hover{background:var(--soft)}.crm-drag-row:active{cursor:grabbing}.crm-drag-row span{font-size:11px;color:var(--muted);align-self:center}.crm-drag-row strong{min-width:0;word-break:break-word}.crm-drag-row small{grid-column:2;font-size:9px;color:var(--muted);opacity:.7}
@media(max-width:900px){.whatsapp-composer{grid-template-columns:42px 42px minmax(0,1fr)!important}.c-send-btn{grid-column:1/-1;width:100%}.commercial-preview-card{align-items:stretch;flex-direction:column}.commercial-preview-actions{justify-content:flex-end}}

/* FIX 2026-10-05: manter a barra de mensagem do Comercial sempre visível */
.commercial-adm-chat{
  height:100%;
  min-height:0;
  overflow:hidden;
}
.commercial-crm-shell{
  height:100%;
  min-height:0;
  overflow:hidden;
}
.commercial-chat-main{
  height:100%;
  min-height:0;
  overflow:hidden;
}
.commercial-chat-main > .commercial-chat-head,
.commercial-chat-main > .commercial-quick-wrap,
.commercial-chat-main > .commercial-media-preview,
.commercial-chat-main > .commercial-chat-compose{
  flex:0 0 auto;
}
.commercial-crm-shell .cchat-messages{
  flex:1 1 auto;
  height:auto!important;
  min-height:0!important;
  overflow-y:auto!important;
  overflow-x:hidden;
  overscroll-behavior:contain;
  margin:0!important;
}
.commercial-chat-main > .commercial-chat-compose{
  position:relative;
  z-index:30;
  width:100%;
  box-sizing:border-box;
  margin:0;
  bottom:auto;
}
.commercial-chat-main > .commercial-quick-wrap,
.commercial-chat-main > .commercial-media-preview{
  position:relative;
  z-index:31;
}
.commercial-chat-compose textarea{
  resize:none!important;
  overflow-y:auto;
}
@media(max-width:900px){
  .commercial-adm-chat{height:auto;min-height:620px}
  .commercial-crm-shell{height:auto;min-height:620px}
  .commercial-chat-main{height:620px;min-height:0}
  .commercial-crm-shell .cchat-messages{height:auto!important;min-height:0!important}
}

/* 2026-10-05 — contraste do cabeçalho no modo claro */
html:not([data-theme="dark"]) #themeToggle{
  background:#ffffff;
  border:1px solid #c9d8d1;
  color:#0b5e40;
  box-shadow:0 1px 4px rgba(11,20,26,.18);
}
html:not([data-theme="dark"]) #themeToggle:hover{
  background:#f2f8f5;
  border-color:#a9c7b9;
  color:#07563a;
}
html:not([data-theme="dark"]) #themeToggle .theme-icon,
html:not([data-theme="dark"]) #themeToggle svg{
  color:#0b5e40;
  stroke:#0b5e40;
}
html:not([data-theme="dark"]) #waHeaderStatus{
  background:#ffffff;
  border:1px solid #c9d8d1;
  color:#173c31;
  box-shadow:0 1px 4px rgba(11,20,26,.14);
  font-weight:700;
}
html:not([data-theme="dark"]) #waHeaderStatus span{
  background:#d73a49;
  box-shadow:0 0 0 3px rgba(215,58,73,.14);
}
html:not([data-theme="dark"]) #waHeaderStatus.connected span{
  background:#0f9d68;
  box-shadow:0 0 0 3px rgba(15,157,104,.18);
}
html:not([data-theme="dark"]) #soundToggle{
  background:#ffffff;
  border:1px solid #c9d8d1;
  color:#174c3d;
  box-shadow:0 1px 4px rgba(11,20,26,.14);
}
html:not([data-theme="dark"]) #soundToggle:hover{
  background:#f2f8f5;
  border-color:#a9c7b9;
}

/* 2026-10-05 — correção do texto do cabeçalho e seleção no modo claro */
html[data-theme="light"] main>header,
html:not([data-theme="dark"]) main>header{
  background:#ffffff!important;
  color:#111b21!important;
  border-bottom:1px solid #e4e8eb;
}
html[data-theme="light"] main>header .head-title h1,
html[data-theme="light"] main>header .head-title strong,
html:not([data-theme="dark"]) main>header .head-title h1,
html:not([data-theme="dark"]) main>header .head-title strong{
  color:#111b21!important;
  -webkit-text-fill-color:#111b21!important;
}
html[data-theme="light"] main>header .head-title p,
html:not([data-theme="dark"]) main>header .head-title p{
  color:#54656f!important;
  -webkit-text-fill-color:#54656f!important;
  opacity:1!important;
}
html[data-theme="light"] ::selection,
html:not([data-theme="dark"]) ::selection{
  background:#b7ead7;
  color:#0b141a;
  -webkit-text-fill-color:#0b141a;
}
html[data-theme="light"] main>header ::selection,
html:not([data-theme="dark"]) main>header ::selection{
  background:#9fe3cd;
  color:#062a21;
  -webkit-text-fill-color:#062a21;
}

/* ==========================================================================
   TeleHub 5.0 — Visual fiel ao WhatsApp Web (mesma paleta de cores)
   Camada final: ícones novos, menu, lista, conversa, cabeçalho e barra de mensagem
   ========================================================================== */
html body:not(.x){
  --wa-bg:#fff;--wa-head:#f0f2f5;--wa-hover:#f5f6f6;--wa-sel:#f0f2f5;--wa-search:#f0f2f5;--wa-line:#e9edef;
  --wa-text:#111b21;--wa-sub:#667781;--wa-icon:#54656f;--wa-in:#fff;--wa-out:#d9fdd3;--wa-input:#fff;--wa-ripple:rgba(11,20,26,.07);
  --wa-chip:#f0f2f5;--wa-chip-on:#d9fdd3;--wa-chip-on-t:#0b6b49;--wa-wall:url(/assets/chat-bg-light.svg);--wa-wall-bg:#efeae2;
  font-family:"Segoe UI","Helvetica Neue",Helvetica,"Lucida Grande",Arial,Ubuntu,Cantarell,"Fira Sans",sans-serif;
  font-size:14.2px;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
html[data-theme="dark"] body:not(.x){
  --wa-bg:#111b21;--wa-head:#202c33;--wa-hover:#202c33;--wa-sel:#2a3942;--wa-search:#202c33;--wa-line:#222d34;
  --wa-text:#e9edef;--wa-sub:#8696a0;--wa-icon:#aebac1;--wa-in:#202c33;--wa-out:#005c4b;--wa-input:#2a3942;--wa-ripple:rgba(255,255,255,.08);
  --wa-chip:#202c33;--wa-chip-on:#103529;--wa-chip-on-t:#21c063;--wa-wall:url(/assets/chat-bg-dark.svg);--wa-wall-bg:#0b141a}

/* Rolagem fina */
html body:not(.x) ::-webkit-scrollbar{width:6px;height:6px}
html body:not(.x) ::-webkit-scrollbar-thumb{background:rgba(134,150,160,.38);border:0;border-radius:6px}
html body:not(.x) ::-webkit-scrollbar-thumb:hover{background:rgba(134,150,160,.6);border:0}
html body:not(.x) ::-webkit-scrollbar-track{background:transparent}

/* Ícones: traço único, sem pontos coloridos */
html body:not(.x) svg.i{width:20px;height:20px;stroke-width:1.8}
html body:not(.x) .nav-icon{width:24px;height:24px;stroke-width:1.7}

/* ---------- Menu lateral (rail) ---------- */
html body:not(.x) #app{grid-template-columns:64px minmax(0,1fr)}
html body:not(.x) .sidebar{background:var(--wa-head);border-right:1px solid var(--wa-line)}
html[data-theme="dark"] body:not(.x) .sidebar{background:#202c33;border-right:1px solid #222d34}
html body:not(.x) .sidebar-shell{padding:12px 0 12px}
html body:not(.x) .brand{padding:2px 0 12px}
html body:not(.x) .brand-icon{width:34px;height:34px;border-radius:10px;box-shadow:none}
html body:not(.x) .nav-menu{gap:2px;overflow-y:auto;overflow-x:visible;scrollbar-width:none}
html body:not(.x) .nav-menu::-webkit-scrollbar{display:none}
html body:not(.x) .nav-menu button{width:44px;height:44px;border-radius:50%;color:var(--wa-icon);background:transparent;border:0;transition:background .15s,color .15s}
html body:not(.x) .nav-menu button:hover{background:var(--wa-ripple);color:var(--wa-text)}
html body:not(.x) .nav-menu button.active{background:rgba(134,150,160,.22);color:var(--wa-text);box-shadow:none}
html[data-theme="dark"] body:not(.x) .nav-menu button.active{background:#374248}
html body:not(.x) .nav-menu button.active .nav-icon{color:var(--accent)}
html body:not(.x) .sidebar-footer{gap:4px;border-top:0;padding-top:8px}
html[data-theme="dark"] body:not(.x) .sidebar-footer{border-top:0}
html body:not(.x) #logoutBtn,html body:not(.x) #installAppBtn{width:44px;height:44px;border-radius:50%;padding:0;display:grid;place-items:center;background:transparent;border:0;color:var(--wa-icon);font-size:0;line-height:0;position:relative}
html body:not(.x) #logoutBtn::before,html[data-theme="dark"] body:not(.x) #logoutBtn::before{content:none;display:none}
html body:not(.x) #installAppBtn{white-space:nowrap;min-height:0}
html body:not(.x) #logoutBtn .nav-icon,html body:not(.x) #installAppBtn .nav-icon{width:22px;height:22px}
html body:not(.x) #logoutBtn:hover,html body:not(.x) #installAppBtn:hover{background:var(--wa-ripple);color:var(--wa-text)}
html body:not(.x) #logoutBtn:hover{color:var(--danger)}
html body:not(.x) #me{width:36px;height:36px;font-size:0}
html body:not(.x) #me strong::first-letter{font-size:15px}

/* ---------- Coluna de conversas ---------- */
html body:not(.x) .split{grid-template-columns:clamp(340px,30%,440px) minmax(0,1fr)}
html[data-theme] body:not(.x) .conv-list,html body:not(.x) .conv-list{background:var(--wa-bg);border-right:1px solid var(--wa-line)}
html body:not(.x) .wa-list-head,html[data-theme] body:not(.x) .wa-list-head{padding:10px 16px 6px;background:var(--wa-bg);border-bottom:0;gap:8px}
html body:not(.x) .wa-list-top{min-height:48px;margin:0;align-items:center}
html body:not(.x) .wa-list-brand{display:flex;align-items:baseline;gap:10px;min-width:0}
html body:not(.x) .wa-list-brand strong{font-size:22px;font-weight:700;letter-spacing:-.2px;color:var(--wa-text)}
html body:not(.x) .wa-view-name{font-size:12.5px;font-weight:500;color:var(--wa-sub);white-space:nowrap}
html body:not(.x) .wa-list-actions{display:flex;gap:2px;align-items:center}
html body:not(.x) .wa-icon-btn,html body:not(.x) .wa-new-btn{width:40px;height:40px;border-radius:50%;padding:0;display:grid;place-items:center;background:transparent;border:0;box-shadow:none;color:var(--wa-icon);font-size:0;line-height:0}
html body:not(.x) .wa-icon-btn:hover,html body:not(.x) .wa-new-btn:hover{background:var(--wa-ripple);color:var(--wa-text)}
html body:not(.x) .wa-icon-btn svg,html body:not(.x) .wa-new-btn svg{width:22px;height:22px}
html body:not(.x) .whatsapp-search,html body:not(.x) .search-box.whatsapp-search{margin:4px 0 8px}
html body:not(.x) .whatsapp-search input{height:36px;border-radius:8px;border:0;background:var(--wa-search);color:var(--wa-text);padding:0 38px 0 52px;font-size:14px;box-shadow:none}
html body:not(.x) .whatsapp-search input::placeholder{color:var(--wa-sub)}
html body:not(.x) .whatsapp-search input:focus{outline:0;box-shadow:inset 0 -2px 0 var(--accent)}
html body:not(.x) .whatsapp-search>svg{left:18px;width:17px;height:17px;color:var(--wa-sub)}
html body:not(.x) .wa-filter-row{gap:6px;padding:2px 0 6px;flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none}
html body:not(.x) .wa-filter-row::-webkit-scrollbar{display:none}
html body:not(.x) .wa-filter{height:30px;padding:0 13px;border-radius:999px;border:1px solid var(--wa-line);background:var(--wa-chip);color:var(--wa-sub);font-size:13.5px;font-weight:500;display:inline-flex;align-items:center;gap:6px;flex:none;box-shadow:none}
html[data-theme="dark"] body:not(.x) .wa-filter{border-color:transparent}
html body:not(.x) .wa-filter:hover{background:var(--wa-sel)}
html body:not(.x) .wa-filter.active{background:var(--wa-chip-on);color:var(--wa-chip-on-t);border-color:transparent}
html body:not(.x) .wa-filter span{font-size:12px;font-weight:600}
html body:not(.x) .wa-filter-plus{width:30px;padding:0;justify-content:center}
html body:not(.x) .wa-filter-plus svg{width:16px;height:16px}
html body:not(.x) .wa-sector-row{padding:2px 0 4px;gap:8px}
html body:not(.x) .wa-sector-row select{height:32px;border-radius:8px;border:0;background:var(--wa-search);color:var(--wa-text);font-size:13px;padding:0 10px}
html body:not(.x) .mine-count{color:var(--wa-sub);font-size:12.5px}

html body:not(.x) #convItems{overflow-y:auto}
html[data-theme] body:not(.x) .conv-item,html body:not(.x) .conv-item{grid-template-columns:49px minmax(0,1fr) auto;gap:15px;padding:0 15px 0 15px;min-height:72px;align-items:center;background:var(--wa-bg);border:0;position:relative}
html body:not(.x) .conv-item:hover{background:var(--wa-hover)}
html body:not(.x) .conv-item.active{background:var(--wa-sel)}
html body:not(.x) .conv-item>div:nth-child(2){padding:11px 0;border-bottom:1px solid var(--wa-line);min-width:0;align-self:stretch;display:flex;flex-direction:column;justify-content:center;gap:2px}
html body:not(.x) .conv-item>div:nth-child(3){align-self:stretch;display:flex;align-items:center;border-bottom:1px solid var(--wa-line);padding-top:0}
html body:not(.x) .conv-item::after{content:none}
html body:not(.x) .conv-item .avatar,html body:not(.x) .avatar{width:49px;height:49px;border-radius:50%;background:linear-gradient(160deg,#6a7c86,#4f616b);color:#fff;font-weight:500;font-size:19px;display:grid;place-items:center;border:0;box-shadow:none}
html[data-theme="light"] body:not(.x) .avatar{background:linear-gradient(160deg,#aebac1,#8a9ba4)}
html body:not(.x) .conv-title{display:flex;justify-content:space-between;align-items:baseline;gap:8px}
html body:not(.x) .conv-title strong{font-size:16.5px;font-weight:400;color:var(--wa-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html body:not(.x) .conv-title small{font-size:12px;color:var(--wa-sub);font-weight:400;flex:none}
html body:not(.x) .conv-preview{font-size:14px;color:var(--wa-sub);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:flex;align-items:center;gap:6px}
html body:not(.x) .conv-item .tags{display:flex;gap:4px;flex-wrap:nowrap;overflow:hidden;margin-top:1px}
html body:not(.x) .conv-item .tags .badge{height:18px;padding:0 6px;border-radius:4px;font-size:10.5px;font-weight:600;letter-spacing:.1px;line-height:18px;text-transform:none;border:0;flex:none}
html body:not(.x) .badge.unread{min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:var(--accent);color:#fff;font-size:12px;font-weight:600;display:inline-flex;align-items:center;justify-content:center;border:0}
html[data-theme="dark"] body:not(.x) .badge.unread{color:#111b21}

/* ---------- Conversa ---------- */
html body:not(.x) .chat{background:var(--wa-wall-bg);min-width:0}
html[data-theme] body:not(.x) .chat-head,html body:not(.x) .chat-head{min-height:59px;padding:8px 16px;background:var(--wa-head);border-bottom:0;gap:14px;flex-wrap:nowrap;align-items:center;box-shadow:0 1px 0 var(--wa-line)}
html[data-theme="dark"] body:not(.x) .chat-head{box-shadow:none;background:#202c33}
html body:not(.x) .chat-head .chat-avatar{width:40px;height:40px;font-size:16px;flex:none}
html body:not(.x) .chat-head .mine-who{min-width:0;flex:1 1 auto;display:flex;flex-direction:column;gap:1px}
html body:not(.x) .chat-head .mine-who strong{font-size:16px;font-weight:500;color:var(--wa-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html body:not(.x) .chat-head .mine-who .muted{font-size:13px;color:var(--wa-sub);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html body:not(.x) .chat-head .back-btn{width:40px;height:40px;padding:0;border-radius:50%;background:transparent;border:0;color:var(--wa-icon);font-size:0}
html body:not(.x) .chat-head .toolbar{display:flex;align-items:center;gap:2px;margin:0 0 0 auto;flex:none;flex-wrap:nowrap}
html body:not(.x) .chat-head .toolbar button.secondary{width:40px;height:40px;padding:0;border-radius:50%;border:0;background:transparent;color:var(--wa-icon);font-size:0;line-height:0;display:grid;place-items:center;box-shadow:none}
html body:not(.x) .chat-head .toolbar button.secondary svg{width:21px;height:21px}
html body:not(.x) .chat-head .toolbar button.secondary:hover{background:var(--wa-ripple);color:var(--wa-text)}
html body:not(.x) .chat-head .toolbar button.primary,html body:not(.x) .chat-head .toolbar button.danger{height:34px;padding:0 14px 0 11px;border-radius:999px;font-size:13px;font-weight:600;display:inline-flex;align-items:center;gap:6px;margin-right:6px;box-shadow:none}
html body:not(.x) .chat-head .toolbar button.primary{background:var(--accent);border:0;color:#fff}
html[data-theme="dark"] body:not(.x) .chat-head .toolbar button.primary{color:#0b141a}
html body:not(.x) .chat-head .toolbar button.primary:hover{background:var(--accent2)}
html body:not(.x) .chat-head .toolbar button.danger{background:transparent;border:1px solid rgba(217,63,63,.45);color:var(--danger)}
html body:not(.x) .chat-head .toolbar button.danger:hover{background:rgba(217,63,63,.1)}
html body:not(.x) .chat-head .toolbar button svg{width:18px;height:18px}
html body:not(.x) .chat-head .toolbar .badge{margin-left:8px;height:22px;padding:0 9px;border-radius:999px;font-size:11.5px;font-weight:600}

/* Mensagens */
html[data-theme] body:not(.x) .chat-body,html body:not(.x) .chat-body{padding:18px clamp(16px,6%,72px) 14px;gap:2px;background-color:var(--wa-wall-bg);background-image:var(--wa-wall);background-size:400px 360px;background-repeat:repeat}
html[data-theme] body:not(.x) .bubble,html body:not(.x) .bubble{max-width:min(65%,620px);padding:6px 8px 7px 9px;border-radius:8px;font-size:14.2px;line-height:19px;background:var(--wa-in);color:var(--wa-text);box-shadow:0 1px .5px rgba(11,20,26,.13);margin-top:0;display:block}
html body:not(.x) .bubble.out{background:var(--wa-out);color:var(--wa-text)}
html[data-theme="dark"] body:not(.x) .bubble.out{color:#e9edef}
html body:not(.x) .bubble.in{border-top-left-radius:0;margin-top:0}
html body:not(.x) .bubble.out{border-top-right-radius:0}
html body:not(.x) .bubble.in::before,html body:not(.x) .bubble.out::before{content:"";position:absolute;top:0;width:8px;height:13px}
html body:not(.x) .bubble.in::before{left:-8px;background:var(--wa-in);clip-path:polygon(100% 0,0 0,100% 100%)}
html body:not(.x) .bubble.out::before{right:-8px;background:var(--wa-out);clip-path:polygon(0 0,100% 0,0 100%)}
html body:not(.x) .bubble.in+.bubble.in::before,html body:not(.x) .bubble.out+.bubble.out::before{display:none}
html body:not(.x) .bubble.in+.bubble.in{border-top-left-radius:8px}
html body:not(.x) .bubble.out+.bubble.out{border-top-right-radius:8px}
html body:not(.x) .bubble.in:not(.in+.in),html body:not(.x) .bubble.out:not(.out+.out){margin-top:10px}
html body:not(.x) .bubble:first-child{margin-top:0}
html body:not(.x) .bubble:not(:has(audio,img,video,.attachment,.file-card)) .msg-text{display:inline}
html body:not(.x) .bubble small{float:right;margin:7px 0 -4px 12px;font-size:11px;line-height:15px;color:var(--wa-sub);display:inline-flex;align-items:center;gap:3px;white-space:nowrap}
html body:not(.x) .bubble.out small{color:rgba(17,27,33,.55)}
html[data-theme="dark"] body:not(.x) .bubble.out small{color:rgba(233,237,239,.6)}
html body:not(.x) .bubble .tick svg,html body:not(.x) .bubble small svg{width:16px;height:16px;stroke-width:2}
html body:not(.x) .bubble .tick.read{color:#53bdeb}
html body:not(.x) .message-menu{width:26px;height:26px;border-radius:50%;background:var(--wa-in);color:var(--wa-icon);border:0;box-shadow:0 1px 3px rgba(11,20,26,.3)}

/* Barra de mensagem */
html[data-theme] body:not(.x) .composer-wrap,html body:not(.x) .composer-wrap{background:var(--wa-head);border-top:0;padding:0}
html[data-theme="dark"] body:not(.x) .composer-wrap{background:#202c33}
html[data-theme] body:not(.x) .composer,html body:not(.x) .composer{display:flex;align-items:flex-end;gap:2px;padding:8px 16px 10px;background:transparent}
html body:not(.x) .composer>button.secondary{width:42px;height:42px;padding:0;border-radius:50%;border:0;background:transparent;color:var(--wa-icon);display:grid;place-items:center;flex:none;box-shadow:none;font-size:0}
html body:not(.x) .composer>button.secondary svg{width:23px;height:23px}
html body:not(.x) .composer>button.secondary:hover:not(:disabled){background:var(--wa-ripple);color:var(--wa-text)}
html body:not(.x) .composer>button.secondary:disabled{opacity:.4}
html body:not(.x) .composer textarea{flex:1 1 auto;min-width:0;min-height:42px;max-height:140px;margin:0 6px;padding:10px 14px;border-radius:8px;border:0;background:var(--wa-input);color:var(--wa-text);font-size:15px;line-height:20px;resize:none;box-shadow:none}
html body:not(.x) .composer textarea::placeholder{color:var(--wa-sub)}
html body:not(.x) .composer textarea:focus{outline:0}
html body:not(.x) .composer #sendBtn{width:42px;height:42px;padding:0;border-radius:50%;border:0;background:var(--accent);color:#fff;display:grid;place-items:center;font-size:0;line-height:0;flex:none;box-shadow:none}
html[data-theme="dark"] body:not(.x) .composer #sendBtn{color:#0b141a}
html body:not(.x) .composer #sendBtn svg{width:21px;height:21px;margin-left:2px}
html body:not(.x) .composer #sendBtn:disabled{background:transparent;color:var(--wa-icon);opacity:.55}
html body:not(.x) .composer #sendBtn:hover:not(:disabled){background:var(--accent2)}
html body:not(.x) .reply-bar{margin:8px 16px 0;border-radius:8px;background:var(--wa-input);border-left:4px solid var(--accent);color:var(--wa-sub)}

/* Estado vazio (nenhuma conversa aberta) */
html body:not(.x) .wa-empty-state,html body:not(.x) .empty-chat{color:var(--wa-sub)}
html[data-theme="dark"] body:not(.x) .chat{background:#222e35}
html[data-theme="light"] body:not(.x) .chat{background:#f0f2f5}
html body:not(.x) .chat:has(.chat-body){background:var(--wa-wall-bg)}

/* ---------- Barra superior das demais telas ---------- */
html body:not(.x) main>header{height:59px;padding:0 16px;background:var(--wa-head);color:var(--wa-text);border-bottom:1px solid var(--wa-line)}
html body:not(.x) main>header h1{color:var(--wa-text);font-size:18px;font-weight:600}
html body:not(.x) main>header p{color:var(--wa-sub);font-size:12.5px}
html body:not(.x) .head-search input{height:36px;border-radius:8px;background:var(--wa-search);border:0;color:var(--wa-text)}
html[data-theme="light"] body:not(.x) .head-search input{background:#fff}
html body:not(.x) .theme-toggle{width:38px;height:38px;border-radius:50%;border:0;background:transparent;color:var(--wa-icon);font-size:0}
html body:not(.x) .theme-toggle:hover{background:var(--wa-ripple)}
html body:not(.x) .status-pill{background:transparent;border:1px solid var(--wa-line);color:var(--wa-sub);font-size:12.5px}
html body:not(.x) .top-tabs button{color:var(--wa-sub)}
html body:not(.x) .top-tabs button.active{color:var(--wa-text)}
html body:not(.x) .top-tabs button.active::after{background:var(--accent)}
html body:not(.x) .top-tabs button:hover{background:var(--wa-ripple);color:var(--wa-text)}
html body:not(.x) .tab-count{background:var(--accent);color:#fff}

/* Cartões e tabelas no mesmo tom */
html body:not(.x) .card,html body:not(.x) .stat{border-radius:12px;box-shadow:none}

/* --- ajustes finos 5.0 --- */
/* texto escondido dentro dos botões de ícone não pode virar linha extra */
html body:not(.x) .chat-head .toolbar button.secondary,html body:not(.x) .composer #sendBtn,html body:not(.x) .composer>button.secondary{display:flex;align-items:center;justify-content:center}
html body:not(.x) .composer{align-items:center}
html body:not(.x) .composer textarea{field-sizing:content;height:auto;min-height:42px;max-height:140px;overflow-y:auto}
/* lista: divisória até a borda e badge fixo no canto */
html[data-theme] body:not(.x) .conv-item,html body:not(.x) .conv-item{grid-template-columns:49px minmax(0,1fr);gap:15px;padding:0 0 0 15px}
html body:not(.x) .conv-item>div:nth-child(2){padding:11px 15px 11px 0}
html body:not(.x) .conv-item>div:nth-child(3){position:absolute;right:15px;bottom:13px;border:0;align-self:auto;padding:0}
html body:not(.x) .conv-item .conv-preview{padding-right:30px}
html body:not(.x) .whatsapp-search input{padding:0 12px 0 52px;font-size:13.5px}
html body:not(.x) .whatsapp-search input:not(:placeholder-shown){padding-right:38px}
/* avatar do usuário no menu */
html[data-theme] body:not(.x) #me::after{content:none;display:none}
html body:not(.x) #me{background:linear-gradient(160deg,#6a7c86,#4f616b);color:#fff;overflow:hidden}
html[data-theme="light"] body:not(.x) #me{background:linear-gradient(160deg,#aebac1,#8a9ba4)}
html body:not(.x) #me strong{font-size:0;font-weight:500}
html body:not(.x) #me strong::first-letter{font-size:16px;color:#fff;text-transform:uppercase}
html body:not(.x) #soundToggle{width:38px;height:38px;border-radius:50%;border:0;background:transparent;color:var(--wa-icon);display:inline-flex;align-items:center;justify-content:center;padding:0;font-size:0}
html body:not(.x) #soundToggle:hover{background:var(--wa-ripple);color:var(--wa-text)}
html body:not(.x) #soundToggle .sound-icon{display:inline-flex;font-size:0}
html body:not(.x) #soundToggle .sound-icon svg{width:21px;height:21px}
html body:not(.x) #soundToggle.sound-off{opacity:.65}
html[data-theme="dark"] body:not(.x) .head-search input{background:#2a3942}
html body:not(.x) .head-search svg{left:12px}
html[data-theme="dark"] body:not(.x) button.danger:not(.chat-head .toolbar *){background:rgba(255,107,107,.12);border:1px solid rgba(255,107,107,.35);color:#ff8f8f}
/* Fotos de perfil do WhatsApp */
.avatar.has-photo,.commercial-avatar.has-photo,.commercial-client-avatar.has-photo{overflow:hidden;padding:0;background:var(--surface-2,#e9edef);display:grid;place-items:center}
.avatar.has-photo img,.commercial-avatar.has-photo img,.commercial-client-avatar.has-photo img{width:100%;height:100%;object-fit:cover;display:block;border-radius:inherit}

/* === TeleHub 2.5: logos, wallpaper, WhatsApp bubbles, top install === */
.brand-logo-light{display:none!important}.brand-logo-dark{display:block!important}
html[data-theme="light"] .brand-logo-dark{display:none!important}html[data-theme="light"] .brand-logo-light{display:block!important}
html[data-theme="dark"] .brand-logo-dark{display:block!important}html[data-theme="dark"] .brand-logo-light{display:none!important}
.brand-logo{max-width:150px;max-height:42px;object-fit:contain}.brand-icon{width:38px;height:38px}
.top-install-btn{height:40px;display:inline-flex;align-items:center;gap:8px;padding:0 13px;border:1px solid var(--border);border-radius:10px;background:var(--panel);color:var(--text);font-weight:700;cursor:pointer;white-space:nowrap}.top-install-btn:hover{background:var(--soft)}.top-install-btn .i{width:18px;height:18px}
@media(max-width:1200px){.top-install-btn span{display:none}.top-install-btn{width:40px;padding:0;justify-content:center}}

/* fundos próprios do chat */
html[data-theme="dark"]{--wa-wall:url('/assets/chat-bg-dark.png')!important;--wa-wall-bg:#0b141a}
html[data-theme="light"]{--wa-wall:url('/assets/chat-bg-light.png')!important;--wa-wall-bg:#efeae2}
.chat-body,.cchat-messages{background-color:var(--wa-wall-bg)!important;background-image:linear-gradient(rgba(0,0,0,.035),rgba(0,0,0,.035)),var(--wa-wall)!important;background-repeat:repeat!important;background-size:720px 400px!important;background-attachment:local!important}
html[data-theme="light"] .chat-body,html[data-theme="light"] .cchat-messages{background-image:linear-gradient(rgba(255,255,255,.2),rgba(255,255,255,.2)),var(--wa-wall)!important}

/* balões próximos do WhatsApp Web */
.bubble,.cmsg{position:relative;width:fit-content;max-width:min(72%,760px);border-radius:8px!important;padding:7px 9px 5px!important;margin:3px 0!important;box-shadow:0 1px 1px rgba(0,0,0,.14);line-height:1.32}
.bubble.in,.cmsg.in{background:var(--wa-in,#202c33)!important;margin-right:auto!important;border-top-left-radius:0!important}
.bubble.out,.cmsg.out{background:var(--wa-out,#005c4b)!important;margin-left:auto!important;border-top-right-radius:0!important}
html[data-theme="light"] .bubble.in,html[data-theme="light"] .cmsg.in{background:#fff!important;color:#111b21!important}
html[data-theme="light"] .bubble.out,html[data-theme="light"] .cmsg.out{background:#d9fdd3!important;color:#111b21!important}
.bubble small,.cmsg small{display:block;text-align:right;margin-top:3px;font-size:10.5px;opacity:.72;min-height:14px;padding-right:22px}.bubble .msg-text,.cmsg p{white-space:pre-wrap;margin:0;padding-right:18px}.bubble.internal,.cmsg.internal{margin:7px auto!important;max-width:75%;background:#fff3c4!important;color:#3b3423!important;border-radius:8px!important}
.message-menu,.commercial-message-menu{position:absolute!important;right:3px!important;top:2px!important;width:24px!important;height:24px!important;border:0!important;border-radius:50%!important;background:transparent!important;color:inherit!important;opacity:0;display:grid!important;place-items:center!important;padding:0!important;cursor:pointer;transition:opacity .15s}.bubble:hover .message-menu,.cmsg:hover .commercial-message-menu,.message-menu:focus,.commercial-message-menu:focus{opacity:.72}.message-menu:hover,.commercial-message-menu:hover{background:rgba(0,0,0,.08)!important;opacity:1!important}
.message-actions-popover{position:fixed;z-index:9999;min-width:190px;padding:6px;background:var(--panel);border:1px solid var(--border);border-radius:10px;box-shadow:0 8px 30px rgba(0,0,0,.32)}.message-actions-popover button{width:100%;display:flex;align-items:center;gap:10px;border:0;background:transparent;color:var(--text);padding:10px 12px;border-radius:8px;text-align:left;cursor:pointer;font:inherit}.message-actions-popover button:hover{background:var(--soft)}.message-actions-popover button.danger-action{color:#e5484d}.message-actions-popover .i{width:18px;height:18px}
.deleted-message{font-style:italic;opacity:.72}.history-separator{display:flex;align-items:center;gap:10px;margin:16px 0;color:var(--muted);font-size:11px}.history-separator:before,.history-separator:after{content:"";height:1px;background:var(--border);flex:1}

/* modal de edição */
.edit-message-textarea{width:100%;min-height:120px;resize:vertical}

/* cabeçalho e logo no modo claro/escuro */
html[data-theme="light"] .brand{background:#fff}html[data-theme="dark"] .brand{background:transparent}

/* TeleHub 2.5.1 — correções de logo, topo e interruptor de tema */
.sidebar .brand{display:flex;align-items:center;justify-content:center;width:100%;padding:8px 0 14px;overflow:visible}
.sidebar .brand-logo{display:none!important}
.sidebar .brand-icon{display:block!important;width:46px!important;height:46px!important;max-width:46px!important;max-height:46px!important;object-fit:contain!important;object-position:center!important;border-radius:13px}
.head-actions{display:flex!important;align-items:center!important;gap:8px!important;min-height:44px}
.top-install-btn,.top-tool-btn,.theme-switch-control{height:40px;flex:none;align-self:center}
.top-tool-btn{width:40px;display:inline-grid;place-items:center;padding:0;border:1px solid var(--border);border-radius:10px;background:var(--panel);color:var(--text);cursor:pointer}
.top-tool-btn:hover{background:var(--soft)}
.top-tool-btn .sound-icon{display:grid;place-items:center;font-size:0}.top-tool-btn .sound-icon svg{width:20px;height:20px}
.theme-switch-control{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-width:92px;padding:0 8px;border:1px solid var(--border);border-radius:999px;background:var(--panel);color:var(--text);cursor:pointer;transition:.18s}
.theme-switch-control:hover{background:var(--soft)}
.theme-switch-control .i{width:16px;height:16px}
.theme-switch-sun,.theme-switch-moon{display:grid;place-items:center;color:var(--muted)}
.theme-switch-track{width:34px;height:20px;border-radius:999px;background:#c7d0d5;position:relative;transition:.2s;box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}
.theme-switch-thumb{position:absolute;left:3px;top:3px;width:14px;height:14px;border-radius:50%;background:#fff;box-shadow:0 1px 4px rgba(0,0,0,.25);transition:.2s}
html[data-theme="dark"] .theme-switch-control{background:#202c33;border-color:#3a464d;color:#e9edef}
html[data-theme="dark"] .theme-switch-track{background:#00a884}
html[data-theme="dark"] .theme-switch-thumb{transform:translateX(14px)}
html[data-theme="dark"] .theme-switch-moon{color:#e9edef}
html[data-theme="light"] .theme-switch-sun{color:#0f8f62}
html[data-theme="light"] .theme-switch-moon{color:#7c8b94}
html[data-theme="light"] .top-tool-btn,html[data-theme="light"] .top-install-btn{background:#fff;border-color:#d6dde1;color:#1f2c33}
html[data-theme="dark"] .top-tool-btn,html[data-theme="dark"] .top-install-btn{background:#202c33;border-color:#3a464d;color:#e9edef}
html[data-theme="light"] .status-pill,html[data-theme="dark"] .status-pill{height:40px;display:inline-flex;align-items:center;margin:0}
.commercial-reply-bar{margin:0;padding:8px 12px;border-top:1px solid var(--line);background:var(--panel2)}
.commercial-reply-bar.show{display:flex}
@media(max-width:1100px){.theme-switch-control{min-width:72px}.theme-switch-sun,.theme-switch-moon{display:none}.head-actions{gap:6px}}

/* === TeleHub 2.6 — Visual Comercial alinhado à referência WhatsApp/CRM === */
body[data-view="commercial"] #app{grid-template-columns:190px minmax(0,1fr)}
body[data-view="commercial"] .sidebar{background:var(--wa-side,var(--rail));border-right:1px solid var(--wa-line,var(--line))}
body[data-view="commercial"] .sidebar-shell{align-items:stretch;padding:10px 8px 12px}
body[data-view="commercial"] .sidebar .brand{height:64px;padding:2px 8px 10px;justify-content:flex-start;background:transparent!important;overflow:hidden}
body[data-view="commercial"] .sidebar .brand-icon{display:none!important}
body[data-view="commercial"] .sidebar .brand-logo{display:none!important;width:160px!important;max-width:160px!important;height:48px!important;max-height:48px!important;object-fit:contain!important;object-position:left center!important;border-radius:0!important;box-shadow:none!important}
html[data-theme="light"] body[data-view="commercial"] .sidebar .brand-logo-light{display:block!important}
html[data-theme="dark"] body[data-view="commercial"] .sidebar .brand-logo-dark{display:block!important}
body[data-view="commercial"] .nav-menu{align-items:stretch;gap:3px;overflow:auto;min-height:0;padding-top:4px}
body[data-view="commercial"] .nav-menu button{width:100%;height:44px;border-radius:10px;padding:0 11px;justify-content:flex-start;gap:11px;color:var(--wa-icon,var(--rail-ic));font-size:13px;font-weight:600}
body[data-view="commercial"] .nav-menu button:hover{background:var(--wa-ripple,rgba(255,255,255,.08))}
body[data-view="commercial"] .nav-menu button.active{background:color-mix(in srgb,var(--accent) 16%,transparent);color:var(--accent);box-shadow:none}
body[data-view="commercial"] .nav-menu .nav-icon{width:20px;height:20px}
body[data-view="commercial"] .nav-menu .nav-label{display:inline;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
body[data-view="commercial"] .nav-menu button::after{display:none}
body[data-view="commercial"] .sidebar-footer{align-items:stretch;justify-items:stretch;gap:5px;border-top:1px solid var(--wa-line,var(--line));padding:10px 4px 0}
body[data-view="commercial"] #me{width:100%;height:auto;min-height:48px;border-radius:10px;padding:7px 8px;display:block;background:transparent!important;color:var(--text);overflow:hidden}
body[data-view="commercial"] #me strong{display:block!important;font-size:13px!important;color:var(--text);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body[data-view="commercial"] #me strong::first-letter{font-size:inherit!important;color:inherit!important}
body[data-view="commercial"] #me .muted{display:block;font-size:10.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:2px}
body[data-view="commercial"] #logoutBtn{width:100%;height:40px;display:flex;justify-content:flex-start;padding:0 10px;gap:8px}
body[data-view="commercial"] #logoutBtn::after{display:none}
body[data-view="commercial"] #logoutBtn::before{width:19px;height:19px}

/* topo comercial mais limpo */
body[data-view="commercial"] main>header{height:64px;padding:0 14px;background:var(--wa-head,var(--panel));color:var(--text);border-bottom:1px solid var(--wa-line,var(--line));gap:12px}
body[data-view="commercial"] main>header h1{color:var(--text);font-size:17px}
body[data-view="commercial"] main>header p{color:var(--muted);font-size:11px}
body[data-view="commercial"] .head-title{min-width:190px}
body[data-view="commercial"] .head-actions{margin-left:auto}
body[data-view="commercial"] .status-pill{color:var(--text);background:var(--panel);border-color:var(--wa-line,var(--line))}
html[data-theme="dark"] body[data-view="commercial"] .status-pill{background:#202c33;color:#e9edef;border-color:#3a464d}

/* conversas comerciais no padrão WhatsApp */
body[data-view="commercial"] #content:has(.commercial-adm-split){padding:0!important;overflow:hidden!important}
body[data-view="commercial"] .commercial-adm-split{height:100%!important;min-height:0!important;grid-template-columns:340px minmax(0,1fr)!important;border:0!important;border-radius:0!important;background:var(--wa-chat,var(--chat-bg))!important}
body[data-view="commercial"] .commercial-adm-list{background:var(--wa-bg,var(--panel));border-right:1px solid var(--wa-line,var(--line));height:100%;min-height:0}
body[data-view="commercial"] .commercial-adm-list .wa-list-head{padding:8px 12px 7px!important;background:var(--wa-bg,var(--panel))!important;border-bottom:1px solid var(--wa-line,var(--line));gap:8px!important}
body[data-view="commercial"] .commercial-adm-list .wa-list-top{height:48px}
body[data-view="commercial"] .commercial-adm-list .wa-list-brand strong{font-size:21px;font-weight:700}
body[data-view="commercial"] .commercial-adm-list .wa-view-name{font-size:11px;color:var(--muted)}
body[data-view="commercial"] .commercial-adm-list .wa-icon-btn,body[data-view="commercial"] .commercial-adm-list .wa-new-btn{width:38px;height:38px;border-radius:50%;background:transparent;border:0;color:var(--wa-icon,var(--muted));font-size:20px}
body[data-view="commercial"] .commercial-adm-list .wa-icon-btn:hover,body[data-view="commercial"] .commercial-adm-list .wa-new-btn:hover{background:var(--wa-ripple,var(--soft))}
body[data-view="commercial"] .commercial-adm-list #commercialConvItems{height:auto!important;flex:1;min-height:0;overflow:auto}
body[data-view="commercial"] .commercial-adm-conv{padding:0 8px 0 10px;min-height:72px;border-bottom:1px solid color-mix(in srgb,var(--wa-line,var(--line)) 72%,transparent);display:grid;grid-template-columns:48px minmax(0,1fr) auto;align-items:center;gap:10px}
body[data-view="commercial"] .commercial-adm-conv:hover{background:var(--wa-ripple,var(--soft))}
body[data-view="commercial"] .commercial-adm-conv.active{background:color-mix(in srgb,var(--accent) 11%,var(--wa-bg,var(--panel)))}
body[data-view="commercial"] .commercial-adm-conv .avatar{width:46px;height:46px}
body[data-view="commercial"] .commercial-adm-conv-body{padding:9px 0;min-width:0}
body[data-view="commercial"] .commercial-adm-conv .conv-title strong{font-size:14px;font-weight:600}
body[data-view="commercial"] .commercial-adm-conv .conv-title small{font-size:10.5px;color:var(--muted)}
body[data-view="commercial"] .commercial-adm-conv .conv-preview{font-size:12px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:3px;padding-right:4px}
body[data-view="commercial"] .commercial-adm-conv .tags{display:flex;gap:4px;margin-top:5px;overflow:hidden}
body[data-view="commercial"] .commercial-adm-conv .badge{height:19px;padding:0 7px;font-size:9.5px;border-radius:999px;white-space:nowrap}
body[data-view="commercial"] .commercial-adm-conv .badge.unread{min-width:19px;height:19px;padding:0 5px;background:#25d366;color:#0b141a;border:0}

/* chat central */
body[data-view="commercial"] .commercial-adm-chat{height:100%;min-height:0;background:var(--wa-chat,var(--chat-bg));overflow:hidden}
body[data-view="commercial"] .commercial-crm-shell{height:100%;min-height:0;background:transparent}
body[data-view="commercial"] .commercial-chat-main{height:100%;min-height:0;background:transparent}
body[data-view="commercial"] .commercial-chat-head{min-height:60px!important;margin:0!important;padding:8px 12px!important;background:var(--wa-head,var(--panel))!important;border-bottom:1px solid var(--wa-line,var(--line))!important;flex-wrap:nowrap!important}
body[data-view="commercial"] .commercial-chat-person{min-width:0;flex:1}
body[data-view="commercial"] .commercial-chat-person .avatar{width:40px;height:40px}
body[data-view="commercial"] .commercial-chat-person h3{font-size:14px;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body[data-view="commercial"] .commercial-chat-person .muted{font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body[data-view="commercial"] .commercial-chat-actions{gap:3px;flex-wrap:nowrap}
body[data-view="commercial"] .commercial-chat-actions button{height:36px;border-radius:18px;padding:0 11px;font-size:11px;background:transparent;border:0;color:var(--wa-icon,var(--text));box-shadow:none}
body[data-view="commercial"] .commercial-chat-actions button:hover{background:var(--wa-ripple,var(--soft))}
body[data-view="commercial"] .commercial-chat-actions button.success{background:#00a884;color:#fff;font-weight:700;padding:0 14px}
body[data-view="commercial"] .commercial-crm-shell .cchat-messages{padding:18px 6% 14px!important;flex:1!important;height:auto!important;min-height:0!important;overflow:auto!important}
body[data-view="commercial"] .cmsg{max-width:min(72%,720px)!important;font-size:13.5px}
body[data-view="commercial"] .cmsg p{line-height:1.35}
body[data-view="commercial"] .commercial-quick-wrap{padding:4px 12px 0;background:var(--wa-head,var(--panel))}
body[data-view="commercial"] .commercial-media-preview{background:var(--wa-head,var(--panel));padding:0 12px}
body[data-view="commercial"] .commercial-reply-bar{background:var(--wa-head,var(--panel));border-top:1px solid var(--wa-line,var(--line));padding:7px 12px}
body[data-view="commercial"] .commercial-chat-compose{padding:9px 12px!important;background:var(--wa-head,var(--panel))!important;border-top:1px solid var(--wa-line,var(--line))!important;grid-template-columns:40px 40px minmax(0,1fr) 44px!important;gap:5px!important;align-items:end!important}
body[data-view="commercial"] .commercial-chat-compose .composer-icon-btn{width:40px;height:40px;border-radius:50%;border:0;background:transparent;color:var(--wa-icon,var(--muted));padding:0}
body[data-view="commercial"] .commercial-chat-compose .composer-icon-btn:hover{background:var(--wa-ripple,var(--soft))}
body[data-view="commercial"] .commercial-chat-compose textarea{min-height:42px;max-height:120px;border:0!important;border-radius:21px!important;padding:10px 15px!important;background:var(--wa-input,var(--soft))!important;color:var(--wa-text,var(--text))!important;box-shadow:none!important;resize:none!important}
body[data-view="commercial"] .commercial-chat-compose .c-send-btn{width:42px;height:42px;border-radius:50%;padding:0;border:0;background:#00a884;color:#fff;display:grid;place-items:center}
body[data-view="commercial"] .commercial-chat-compose .c-send-btn span{display:none}
body[data-view="commercial"] .commercial-chat-compose .c-send-btn svg{width:20px;height:20px}

/* CRM lateral com superfície coerente */
body[data-view="commercial"] .commercial-crm-panel{width:330px;background:var(--wa-bg,var(--panel));border-left:1px solid var(--wa-line,var(--line));padding:12px;scrollbar-width:thin}
body[data-view="commercial"] .commercial-crm-title{min-height:44px;padding:0 0 9px}
body[data-view="commercial"] .crm-close-btn{width:34px;height:34px;border-radius:50%;border:0;background:transparent;color:var(--wa-icon,var(--text));font-size:22px;padding:0}
body[data-view="commercial"] .crm-close-btn:hover{background:var(--wa-ripple,var(--soft))}
html[data-theme="light"] body[data-view="commercial"] .crm-close-btn{color:#34434b!important;background:transparent!important}

/* vazio: usa a marca oficial correspondente ao tema */
body[data-view="commercial"] .commercial-wa-empty{background:var(--wa-chat,var(--chat-bg));border:0!important}
body[data-view="commercial"] .commercial-empty-brand{width:min(360px,68%);margin:0 auto 14px;display:grid;place-items:center}
body[data-view="commercial"] .commercial-empty-logo{display:none;width:100%;height:auto;max-height:105px;object-fit:contain}
html[data-theme="dark"] body[data-view="commercial"] .commercial-empty-logo-dark{display:block}
html[data-theme="light"] body[data-view="commercial"] .commercial-empty-logo-light{display:block}
body[data-view="commercial"] .commercial-wa-empty h2{display:none}
body[data-view="commercial"] .commercial-wa-empty p{font-size:13px;color:var(--muted)}
body[data-view="commercial"] .wa-empty-shortcuts button{background:var(--wa-head,var(--panel));border:1px solid var(--wa-line,var(--line));color:var(--text)}

/* funil com colunas compactas como CRM visual */
body[data-view="commercial"] .commercial-funnel-top{padding:14px 16px;margin:0;background:var(--wa-head,var(--panel));border-bottom:1px solid var(--wa-line,var(--line))}
body[data-view="commercial"] .commercial-kanban{height:calc(100% - 72px);display:flex;gap:10px;padding:12px;overflow:auto;background:var(--bg)}
body[data-view="commercial"] .commercial-kanban-col{flex:0 0 270px;border:1px solid var(--wa-line,var(--line));border-radius:11px;background:var(--wa-bg,var(--panel));overflow:hidden;box-shadow:none}
body[data-view="commercial"] .commercial-kanban-col>header{height:42px;padding:0 11px;background:#00a884;color:#fff;border:0}
body[data-view="commercial"] .commercial-kanban-drop{padding:7px;min-height:180px}
body[data-view="commercial"] .commercial-kanban-card{border:1px solid var(--wa-line,var(--line));border-radius:9px;background:var(--panel);padding:9px;margin-bottom:7px;box-shadow:none}
body[data-view="commercial"] .commercial-kanban-card:hover{border-color:color-mix(in srgb,#00a884 50%,var(--wa-line,var(--line)));background:var(--soft)}

@media(max-width:1100px){
  body[data-view="commercial"] #app{grid-template-columns:76px minmax(0,1fr)}
  body[data-view="commercial"] .sidebar-shell{align-items:center;padding:10px 0 12px}
  body[data-view="commercial"] .sidebar .brand{justify-content:center;padding:2px 0 10px}
  body[data-view="commercial"] .sidebar .brand-logo{display:none!important}
  body[data-view="commercial"] .sidebar .brand-icon{display:block!important}
  body[data-view="commercial"] .nav-menu{align-items:center;width:100%}
  body[data-view="commercial"] .nav-menu button{width:50px;height:50px;padding:0;justify-content:center}
  body[data-view="commercial"] .nav-menu .nav-label{display:none}
  body[data-view="commercial"] #me{width:42px;height:42px;padding:0;display:grid;place-items:center;border-radius:50%}
  body[data-view="commercial"] #me strong{font-size:0!important}body[data-view="commercial"] #me strong::first-letter{font-size:16px!important}
  body[data-view="commercial"] #me .muted{display:none}
  body[data-view="commercial"] #logoutBtn{width:44px;justify-content:center;padding:0}
  body[data-view="commercial"] .commercial-adm-split{grid-template-columns:310px minmax(0,1fr)!important}
  body[data-view="commercial"] .commercial-crm-panel{width:285px}
}
@media(max-width:780px){
  body[data-view="commercial"] .commercial-adm-split{grid-template-columns:1fr!important}
  body[data-view="commercial"] .commercial-adm-split:not(.chat-open) .commercial-adm-chat{display:none}
  body[data-view="commercial"] .commercial-adm-split.chat-open .commercial-adm-list{display:none}
  body[data-view="commercial"] .commercial-adm-split.chat-open .commercial-adm-chat{display:flex}
}

/* === TeleHub 2.6.1 — correção definitiva do menu Comercial === */
body[data-view="commercial"] #app{grid-template-columns:210px minmax(0,1fr)!important}
body[data-view="commercial"] .sidebar{min-width:210px!important;width:210px!important;overflow:hidden}
body[data-view="commercial"] .sidebar-shell{width:100%!important;min-width:0!important;padding:10px 10px 12px!important;box-sizing:border-box}
body[data-view="commercial"] .sidebar .brand{width:100%!important;height:68px!important;min-height:68px!important;padding:4px 4px 12px!important;justify-content:flex-start!important;overflow:visible!important;box-sizing:border-box}
body[data-view="commercial"] .sidebar .brand-logo{width:180px!important;max-width:100%!important;height:50px!important;max-height:50px!important;object-fit:contain!important;object-position:left center!important}
body[data-view="commercial"] .nav-menu{width:100%!important;min-width:0!important}
body[data-view="commercial"] .nav-menu button{width:100%!important;min-width:0!important;padding:0 12px!important;justify-content:flex-start!important;gap:11px!important}
body[data-view="commercial"] .nav-menu .nav-label{display:block!important;min-width:0!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
body[data-view="commercial"] .sidebar-footer{width:100%!important;min-width:0!important;padding:10px 2px 0!important;box-sizing:border-box}
body[data-view="commercial"] #me{width:100%!important;min-width:0!important;height:auto!important;min-height:52px!important;padding:8px 9px!important;display:block!important;border-radius:10px!important;box-sizing:border-box!important;overflow:hidden!important}
body[data-view="commercial"] #me strong{display:block!important;font-size:13px!important;line-height:1.25!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
body[data-view="commercial"] #me strong::first-letter{font-size:inherit!important}
body[data-view="commercial"] #me .muted{display:block!important;font-size:10.5px!important;line-height:1.25!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;margin-top:3px!important}
body[data-view="commercial"] #logoutBtn{width:100%!important;height:42px!important;justify-content:flex-start!important;padding:0 11px!important}

/* Mantém o menu completo em notebooks e janelas menores. */
@media (max-width:1100px) and (min-width:781px){
  body[data-view="commercial"] #app{grid-template-columns:178px minmax(0,1fr)!important}
  body[data-view="commercial"] .sidebar{min-width:178px!important;width:178px!important}
  body[data-view="commercial"] .sidebar-shell{align-items:stretch!important;padding:10px 8px 12px!important}
  body[data-view="commercial"] .sidebar .brand{justify-content:flex-start!important;padding:4px 3px 10px!important;overflow:visible!important}
  body[data-view="commercial"] .sidebar .brand-icon{display:none!important}
  body[data-view="commercial"] .sidebar .brand-logo{width:154px!important;max-width:100%!important;height:46px!important;display:none!important}
  html[data-theme="light"] body[data-view="commercial"] .sidebar .brand-logo-light{display:block!important}
  html[data-theme="dark"] body[data-view="commercial"] .sidebar .brand-logo-dark{display:block!important}
  body[data-view="commercial"] .nav-menu{align-items:stretch!important;width:100%!important}
  body[data-view="commercial"] .nav-menu button{width:100%!important;height:44px!important;padding:0 9px!important;justify-content:flex-start!important}
  body[data-view="commercial"] .nav-menu .nav-label{display:block!important}
  body[data-view="commercial"] #me{width:100%!important;height:auto!important;padding:7px 8px!important;display:block!important;border-radius:10px!important}
  body[data-view="commercial"] #me strong{font-size:12px!important}
  body[data-view="commercial"] #me .muted{display:block!important;font-size:9.5px!important}
  body[data-view="commercial"] #logoutBtn{width:100%!important;justify-content:flex-start!important;padding:0 9px!important}
}

/* Só em telas realmente pequenas o menu vira barra de ícones. */
@media (max-width:780px){
  body[data-view="commercial"] #app{grid-template-columns:72px minmax(0,1fr)!important}
  body[data-view="commercial"] .sidebar{min-width:72px!important;width:72px!important}
  body[data-view="commercial"] .sidebar-shell{align-items:center!important;padding:8px 0 10px!important}
  body[data-view="commercial"] .sidebar .brand{height:56px!important;min-height:56px!important;justify-content:center!important;padding:2px 0 8px!important}
  body[data-view="commercial"] .sidebar .brand-logo{display:none!important}
  body[data-view="commercial"] .sidebar .brand-icon{display:block!important;width:44px!important;height:44px!important}
  body[data-view="commercial"] .nav-menu{align-items:center!important}
  body[data-view="commercial"] .nav-menu button{width:50px!important;height:50px!important;padding:0!important;justify-content:center!important}
  body[data-view="commercial"] .nav-menu .nav-label{display:none!important}
  body[data-view="commercial"] #me{width:46px!important;height:46px!important;min-height:46px!important;padding:0!important;display:grid!important;place-items:center!important;border-radius:50%!important}
  body[data-view="commercial"] #me strong{font-size:0!important}
  body[data-view="commercial"] #me strong::first-letter{font-size:16px!important}
  body[data-view="commercial"] #me .muted{display:none!important}
  body[data-view="commercial"] #logoutBtn{width:46px!important;justify-content:center!important;padding:0!important}
}

/* === TeleHub 2.6.2 — Comercial novamente com o mesmo menu visual do ADM === */
body[data-view="commercial"] #app{
  grid-template-columns:64px minmax(0,1fr)!important;
}
body[data-view="commercial"] .sidebar{
  width:auto!important;
  min-width:0!important;
  background:var(--wa-head,var(--rail))!important;
  border-right:1px solid var(--wa-line,var(--line))!important;
  overflow:hidden!important;
}
html[data-theme="dark"] body[data-view="commercial"] .sidebar{
  background:#202c33!important;
  border-right-color:#222d34!important;
}
html[data-theme="light"] body[data-view="commercial"] .sidebar{
  background:#f0f2f5!important;
  border-right-color:#d8dfe3!important;
}
body[data-view="commercial"] .sidebar-shell{
  width:100%!important;
  height:100dvh!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  padding:12px 0!important;
  box-sizing:border-box!important;
}
body[data-view="commercial"] .sidebar .brand{
  width:auto!important;
  height:auto!important;
  min-height:0!important;
  padding:2px 0 12px!important;
  justify-content:center!important;
  overflow:visible!important;
  background:transparent!important;
}
body[data-view="commercial"] .sidebar .brand-logo{
  display:none!important;
}
body[data-view="commercial"] .sidebar .brand-icon{
  display:block!important;
  width:38px!important;
  height:38px!important;
  max-width:38px!important;
  max-height:38px!important;
  object-fit:contain!important;
  border-radius:10px!important;
  padding:0!important;
  box-shadow:none!important;
}
body[data-view="commercial"] .nav-menu{
  width:100%!important;
  flex:1!important;
  min-height:0!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  gap:2px!important;
  padding:0!important;
  overflow-y:auto!important;
  overflow-x:visible!important;
  scrollbar-width:none!important;
}
body[data-view="commercial"] .nav-menu::-webkit-scrollbar{display:none!important}
body[data-view="commercial"] .nav-menu button{
  width:44px!important;
  min-width:44px!important;
  height:44px!important;
  min-height:44px!important;
  padding:0!important;
  gap:0!important;
  justify-content:center!important;
  border:0!important;
  border-radius:50%!important;
  background:transparent!important;
  color:var(--wa-icon,var(--rail-ic))!important;
  position:relative!important;
  box-shadow:none!important;
}
body[data-view="commercial"] .nav-menu button:hover{
  background:var(--wa-ripple,var(--soft))!important;
  color:var(--wa-text,var(--text))!important;
}
body[data-view="commercial"] .nav-menu button.active{
  background:rgba(134,150,160,.22)!important;
  color:var(--wa-text,var(--text))!important;
}
html[data-theme="dark"] body[data-view="commercial"] .nav-menu button.active{background:#374248!important}
html[data-theme="light"] body[data-view="commercial"] .nav-menu button.active{background:#fff!important;color:#00a884!important}
body[data-view="commercial"] .nav-menu button.active .nav-icon{color:var(--accent)!important}
body[data-view="commercial"] .nav-menu button.active::before{
  content:""!important;
  position:absolute!important;
  left:-10px!important;
  right:auto!important;
  top:9px!important;
  width:4px!important;
  height:26px!important;
  border-radius:0 4px 4px 0!important;
  background:#00a884!important;
}
body[data-view="commercial"] .nav-menu .nav-icon{
  width:21px!important;
  height:21px!important;
  flex:none!important;
}
body[data-view="commercial"] .nav-menu .nav-label{
  display:none!important;
}
body[data-view="commercial"] .nav-menu button::after{
  content:attr(data-tip)!important;
  display:block!important;
  position:absolute!important;
  left:calc(100% + 12px)!important;
  top:50%!important;
  transform:translateY(-50%)!important;
  width:auto!important;
  height:auto!important;
  background:#111b21!important;
  color:#fff!important;
  padding:7px 11px!important;
  border-radius:9px!important;
  font-size:12px!important;
  font-weight:600!important;
  white-space:nowrap!important;
  opacity:0!important;
  pointer-events:none!important;
  z-index:100!important;
  box-shadow:0 6px 18px rgba(0,0,0,.25)!important;
}
body[data-view="commercial"] .nav-menu button:hover::after{opacity:1!important}
body[data-view="commercial"] .sidebar-footer{
  width:100%!important;
  flex:none!important;
  margin-top:8px!important;
  padding:8px 0 0!important;
  display:grid!important;
  justify-items:center!important;
  align-items:center!important;
  gap:5px!important;
  border-top:0!important;
}
body[data-view="commercial"] #me{
  width:42px!important;
  height:42px!important;
  min-height:42px!important;
  padding:0!important;
  border-radius:50%!important;
  display:grid!important;
  place-items:center!important;
  overflow:hidden!important;
  background:color-mix(in srgb,var(--accent) 18%,var(--panel))!important;
  color:var(--accent)!important;
  text-align:center!important;
  cursor:default!important;
}
body[data-view="commercial"] #me strong{
  display:block!important;
  width:100%!important;
  font-size:0!important;
  line-height:1!important;
  overflow:visible!important;
  color:inherit!important;
}
body[data-view="commercial"] #me strong::first-letter{
  font-size:16px!important;
  font-weight:800!important;
}
body[data-view="commercial"] #me .muted{display:none!important}
body[data-view="commercial"] #logoutBtn{
  width:44px!important;
  height:44px!important;
  min-width:44px!important;
  padding:0!important;
  justify-content:center!important;
  border-radius:50%!important;
}
body[data-view="commercial"] #logoutBtn::after{display:block!important}

/* Mantém o cabeçalho e o conteúdo com o mesmo comportamento do ADM. */
body[data-view="commercial"] main>header{
  height:auto!important;
  min-height:72px!important;
  padding:10px 16px!important;
}
body[data-view="commercial"] .head-title h1{font-size:22px!important}

@media(max-width:700px){
  body[data-view="commercial"] #app{grid-template-columns:64px minmax(0,1fr)!important}
  body[data-view="commercial"] .sidebar{display:block!important}
}

/* TeleHub 2.6.4 — comercial com ícone apenas no topo do menu */
body[data-view="commercial"] .sidebar .brand{
  justify-content:center !important;
  padding:6px 0 10px !important;
  height:64px !important;
  min-height:64px !important;
  overflow:visible !important;
}
body[data-view="commercial"] .sidebar .brand-logo,
html[data-theme="light"] body[data-view="commercial"] .sidebar .brand-logo-light,
html[data-theme="dark"] body[data-view="commercial"] .sidebar .brand-logo-dark{
  display:none !important;
}
body[data-view="commercial"] .sidebar .brand-icon{
  display:block !important;
  width:44px !important;
  height:44px !important;
  max-width:44px !important;
  max-height:44px !important;
  object-fit:contain !important;
  object-position:center !important;
  border-radius:12px !important;
}

/* TeleHub 2.6.5 — centralizar estado vazio do comercial no painel direito */
body[data-view="commercial"] .chat > .commercial-wa-empty,
body[data-view="commercial"] .chat > .wa-empty-state.commercial-wa-empty{
  width:100% !important;
  height:100% !important;
  min-height:100% !important;
  flex:1 1 auto !important;
  display:flex !important;
  flex-direction:column !important;
  align-items:center !important;
  justify-content:center !important;
  text-align:center !important;
  padding:40px 24px !important;
  box-sizing:border-box !important;
}
body[data-view="commercial"] .commercial-empty-brand{
  width:min(430px,72%) !important;
  margin:0 auto 16px !important;
  display:grid !important;
  place-items:center !important;
}
body[data-view="commercial"] .commercial-wa-empty p{
  margin:0 0 28px !important;
  text-align:center !important;
}
body[data-view="commercial"] .commercial-wa-empty .wa-empty-shortcuts{
  width:100% !important;
  justify-content:center !important;
}

/* TeleHub 2.6.6 — estado vazio comercial centralizado pelo painel direito real */
body[data-view="commercial"] .commercial-adm-chat{
  position:relative !important;
  min-width:0 !important;
  overflow:hidden !important;
}
body[data-view="commercial"] .commercial-adm-chat > .commercial-wa-empty{
  position:absolute !important;
  inset:0 !important;
  width:auto !important;
  height:auto !important;
  min-height:0 !important;
  margin:0 !important;
  display:flex !important;
  flex-direction:column !important;
  align-items:center !important;
  justify-content:center !important;
  text-align:center !important;
  padding:40px clamp(24px,6vw,90px) !important;
  box-sizing:border-box !important;
}
body[data-view="commercial"] .commercial-adm-chat > .commercial-wa-empty .commercial-empty-brand{
  width:min(520px,72%) !important;
  max-width:520px !important;
  margin:0 auto 18px !important;
  display:grid !important;
  place-items:center !important;
}
body[data-view="commercial"] .commercial-adm-chat > .commercial-wa-empty .commercial-empty-logo{
  width:100% !important;
  max-width:520px !important;
  max-height:150px !important;
  object-fit:contain !important;
  object-position:center !important;
  margin:0 auto !important;
}
body[data-view="commercial"] .commercial-adm-chat > .commercial-wa-empty .wa-empty-shortcuts{
  justify-content:center !important;
  width:auto !important;
  margin-inline:auto !important;
}

/* TeleHub 2.6.7 — estado vazio seguro, visível e centralizado */
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty){
  display:grid !important;
  place-items:center !important;
  position:relative !important;
  min-height:0 !important;
  overflow:hidden !important;
}
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) > .commercial-wa-empty{
  position:static !important;
  inset:auto !important;
  width:min(760px, 100%) !important;
  height:auto !important;
  min-height:0 !important;
  margin:0 auto !important;
  padding:40px 32px !important;
  display:flex !important;
  flex-direction:column !important;
  align-items:center !important;
  justify-content:center !important;
  text-align:center !important;
  box-sizing:border-box !important;
  background:transparent !important;
  border:0 !important;
}
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) .commercial-empty-brand{
  width:min(500px, 78%) !important;
  max-width:500px !important;
  margin:0 auto 18px !important;
  display:grid !important;
  place-items:center !important;
}
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) .commercial-empty-logo{
  width:100% !important;
  height:auto !important;
  max-width:500px !important;
  max-height:145px !important;
  object-fit:contain !important;
  object-position:center !important;
}
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) .commercial-wa-empty p{
  margin:0 0 28px !important;
  text-align:center !important;
}
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) .wa-empty-shortcuts{
  display:flex !important;
  justify-content:center !important;
  align-items:flex-start !important;
  gap:36px !important;
  width:auto !important;
  margin:0 auto !important;
}

/* TeleHub 2.6.8 — estado vazio ocupa todo o painel direito */
body[data-view="commercial"] .commercial-adm-chat{
  display:flex !important;
  align-items:stretch !important;
  justify-content:stretch !important;
}
body[data-view="commercial"] .commercial-adm-chat > .commercial-wa-empty,
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) > .commercial-wa-empty{
  position:static !important;
  inset:auto !important;
  width:100% !important;
  max-width:none !important;
  height:100% !important;
  min-height:100% !important;
  flex:1 1 auto !important;
  margin:0 !important;
  padding:40px clamp(24px,5vw,72px) !important;
  display:flex !important;
  flex-direction:column !important;
  align-items:center !important;
  justify-content:center !important;
  text-align:center !important;
  box-sizing:border-box !important;
  background:var(--wa-chat,var(--chat-bg)) !important;
  border:0 !important;
}
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty){
  display:flex !important;
  place-items:initial !important;
}
body[data-view="commercial"] .commercial-adm-chat > .commercial-wa-empty .commercial-empty-brand,
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) .commercial-empty-brand{
  width:min(520px,70%) !important;
  max-width:520px !important;
}
body[data-view="commercial"] .commercial-adm-chat > .commercial-wa-empty .wa-empty-shortcuts,
body[data-view="commercial"] .commercial-adm-chat:has(> .commercial-wa-empty) .wa-empty-shortcuts{
  width:100% !important;
  justify-content:center !important;
}


/* TeleHub 2.6.9 — estado vazio exatamente centralizado como WhatsApp Web */
body[data-view="commercial"] .commercial-adm-chat.is-empty{
  display:grid !important;
  place-items:center !important;
  align-content:center !important;
  justify-items:center !important;
  width:100% !important;
  min-width:0 !important;
  min-height:100% !important;
  height:100% !important;
  padding:0 !important;
  overflow:hidden !important;
  background:var(--wa-chat,var(--chat-bg)) !important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty > .commercial-wa-empty{
  display:flex !important;
  flex-direction:column !important;
  align-items:center !important;
  justify-content:center !important;
  text-align:center !important;
  width:min(760px, 92%) !important;
  max-width:760px !important;
  margin:0 auto !important;
  padding:24px 24px 40px !important;
  min-height:auto !important;
  height:auto !important;
  flex:none !important;
  background:transparent !important;
  border:0 !important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty > .commercial-wa-empty .commercial-empty-brand{
  width:min(500px, 82%) !important;
  max-width:500px !important;
  margin:0 auto 18px !important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty > .commercial-wa-empty .commercial-empty-logo{
  width:100% !important;
  height:auto !important;
  max-width:500px !important;
  max-height:145px !important;
  object-fit:contain !important;
  object-position:center !important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty > .commercial-wa-empty p{
  margin:0 0 28px !important;
  text-align:center !important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty > .commercial-wa-empty .wa-empty-shortcuts{
  display:flex !important;
  justify-content:center !important;
  align-items:flex-start !important;
  gap:34px !important;
  width:auto !important;
  margin:0 auto !important;
}

/* TeleHub 2.7 — campanhas promocionais e nova conversa */
.campaign-info-box{display:grid;gap:4px;padding:12px 14px;margin:4px 0 16px;border:1px solid color-mix(in srgb,var(--green) 28%,var(--border));border-radius:12px;background:color-mix(in srgb,var(--green) 7%,var(--panel))}.campaign-info-box span{font-size:12px;color:var(--muted);line-height:1.45}
.campaign-title-line{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.campaign-title-line .badge{background:color-mix(in srgb,var(--green) 14%,var(--panel));color:var(--green);font-size:9px;padding:3px 7px}
.campaign-keywords{display:flex;align-items:center;gap:6px;flex-wrap:wrap;margin-top:8px;font-size:11px;color:var(--muted)}.campaign-keywords span{padding:3px 8px;border-radius:999px;background:var(--soft);border:1px solid var(--border);color:var(--text);font-weight:700}
.campaign-metrics-mini{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}.campaign-metrics-mini span{display:inline-flex;align-items:center;gap:4px;padding:6px 9px;border:1px solid var(--border);border-radius:9px;background:var(--soft);font-size:11px;color:var(--muted)}.campaign-metrics-mini b{color:var(--text);font-size:12px}
.campaign-promotion{border-left:3px solid var(--green);padding-left:12px}.promotion-base-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:12px 0 8px}.promotion-lead-list{max-height:280px;overflow:auto;border:1px solid var(--border);border-radius:12px;background:var(--panel);margin-top:8px}.promotion-lead-row{display:grid!important;grid-template-columns:22px minmax(0,1fr);gap:9px;align-items:center;padding:10px 12px!important;margin:0!important;border-bottom:1px solid var(--border);cursor:pointer}.promotion-lead-row:last-child{border-bottom:0}.promotion-lead-row:hover{background:var(--soft)}.promotion-lead-row input{width:16px;height:16px}.promotion-lead-row span{display:grid;gap:3px;min-width:0}.promotion-lead-row strong,.promotion-lead-row small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.promotion-lead-row small{color:var(--muted);font-size:10px}.promotion-selected{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:8px}.consent-line{display:flex!important;align-items:flex-start!important;gap:8px!important;padding:10px 12px!important;border:1px solid var(--border);border-radius:10px;background:var(--soft)}.consent-line input{width:16px;height:16px;flex:none;margin-top:2px}
@media(max-width:700px){.promotion-base-head,.promotion-selected{align-items:flex-start;flex-direction:column}.campaign-metrics-mini{display:grid;grid-template-columns:1fr 1fr 1fr;width:100%}}

/* TeleHub 2.8 — central de campanhas promocionais ao vivo */
.campaign-center{padding:18px 20px}.campaign-card{border:1px solid var(--border);border-radius:14px;background:var(--panel);overflow:hidden;margin-top:14px}.campaign-card-main{padding:15px 16px}.campaign-card-title{display:flex;align-items:flex-start;justify-content:space-between;gap:14px}.campaign-card-title small{display:block;color:var(--muted);margin-top:4px}.campaign-actions{display:flex;gap:7px;align-items:center;flex-wrap:wrap}.campaign-actions button{height:34px;padding:0 11px}.campaign-status{font-size:10px;padding:3px 7px;border-radius:999px;background:var(--soft);color:var(--muted);font-weight:700}.campaign-message-preview{margin-top:10px;padding:10px 12px;border-radius:10px;background:var(--soft);border:1px solid var(--border);font-size:12px;line-height:1.45;white-space:pre-wrap}.campaign-live-metrics{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:8px;margin:12px 0}.campaign-live-metrics>div{min-width:0;padding:9px 8px;border:1px solid var(--border);border-radius:10px;background:var(--soft);text-align:center}.campaign-live-metrics strong,.campaign-live-metrics span{display:block}.campaign-live-metrics strong{font-size:18px}.campaign-live-metrics span{font-size:10px;color:var(--muted);margin-top:2px}.campaign-live-metrics .ok strong{color:#16a34a}.campaign-live-metrics .error strong{color:#dc2626}.campaign-live-metrics .interest strong{color:#d97706}.campaign-live-metrics .answered strong{color:#2563eb}.campaign-live-metrics .sales strong{color:var(--green)}
.campaign-live-detail{border-top:1px solid var(--border);background:color-mix(in srgb,var(--soft) 55%,var(--panel));padding:14px 16px;display:grid;gap:12px}.campaign-detail-section{background:var(--panel);border:1px solid var(--border);border-radius:12px;overflow:hidden}.campaign-detail-head{display:flex;align-items:center;justify-content:space-between;padding:10px 12px;border-bottom:1px solid var(--border)}.campaign-detail-head span{min-width:25px;height:25px;border-radius:99px;background:var(--soft);display:grid;place-items:center;font-size:11px;font-weight:800}.campaign-response-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;padding:11px 12px;border-bottom:1px solid var(--border);align-items:center}.campaign-response-row:last-child{border-bottom:0}.campaign-response-row small{display:block;color:var(--muted);margin-top:2px}.campaign-response-row p{margin:6px 0 0;font-size:12px}.campaign-response-status{font-size:10px;font-weight:800;padding:6px 9px;border-radius:999px;white-space:nowrap}.campaign-response-status.answered{background:rgba(22,163,74,.12);color:#16a34a}.campaign-response-status.waiting{background:rgba(217,119,6,.12);color:#d97706}.campaign-detail-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.campaign-simple-row{display:flex;justify-content:space-between;gap:10px;padding:9px 12px;border-bottom:1px solid var(--border);font-size:11px}.campaign-simple-row:last-child{border-bottom:0}.campaign-simple-row small{color:var(--muted);text-align:right}.campaign-simple-row.error small{color:#dc2626}.campaign-detail-empty{padding:14px}.campaign-builder-grid{display:grid;grid-template-columns:2fr 1fr;gap:10px}.campaign-search{width:min(360px,100%);margin:0}.campaign-token-grid{margin:8px 0 12px}
@media(max-width:1100px){.campaign-live-metrics{grid-template-columns:repeat(4,1fr)}}
@media(max-width:760px){.campaign-card-title,.promotion-base-head{flex-direction:column}.campaign-live-metrics{grid-template-columns:repeat(2,1fr)}.campaign-detail-grid,.campaign-builder-grid{grid-template-columns:1fr}.campaign-response-row{grid-template-columns:1fr}.campaign-response-status{justify-self:start}}


/* TeleHub 2.9 — nova conversa e centralização exata do estado vazio */
body[data-view="commercial"] #content{min-width:0!important;width:100%!important}
body[data-view="commercial"] .commercial-adm-split{
  width:100%!important;
  max-width:none!important;
  grid-template-columns:340px minmax(0,1fr)!important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty{
  grid-column:2!important;
  position:relative!important;
  width:100%!important;
  max-width:none!important;
  height:100%!important;
  min-height:0!important;
  display:grid!important;
  place-items:center!important;
  padding:0!important;
  margin:0!important;
  overflow:hidden!important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty > .commercial-wa-empty{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  max-width:none!important;
  min-height:0!important;
  margin:0!important;
  padding:40px!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  justify-content:center!important;
  text-align:center!important;
  box-sizing:border-box!important;
  background:var(--wa-chat,var(--chat-bg))!important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty .commercial-empty-brand{
  width:min(500px,58vw)!important;
  max-width:500px!important;
  margin:0 auto 18px!important;
}
body[data-view="commercial"] .commercial-adm-chat.is-empty .wa-empty-shortcuts{
  width:auto!important;
  max-width:100%!important;
  margin:0 auto!important;
  display:flex!important;
  justify-content:center!important;
  align-items:flex-start!important;
  gap:34px!important;
}
.commercial-new-contact-modal{min-width:min(680px,86vw)}
.commercial-new-contact-head{margin-bottom:16px}
.commercial-new-contact-head h3{margin-bottom:4px}
.commercial-new-contact-note{margin:14px 0 2px;padding:11px 13px;border-radius:10px;background:var(--soft);color:var(--muted);font-size:12px}
@media(max-width:780px){
  body[data-view="commercial"] .commercial-adm-split{grid-template-columns:1fr!important}
  body[data-view="commercial"] .commercial-adm-chat.is-empty{grid-column:1!important}
  body[data-view="commercial"] .commercial-adm-chat.is-empty > .commercial-wa-empty{position:static!important;min-height:65vh!important}
  .commercial-new-contact-modal{min-width:0}
}


/* TeleHub 2.9.1 — modal Nova conversa sem cortes */
.modal:has(.commercial-new-contact-modal){
  padding:clamp(10px,2.2vh,22px) !important;
  overflow:hidden !important;
}
.modal-card.commercial-new-contact-card{
  width:min(760px, calc(100vw - 28px)) !important;
  max-width:760px !important;
  max-height:calc(100dvh - 28px) !important;
  min-height:0 !important;
  padding:0 !important;
  overflow:hidden !important;
  display:flex !important;
  flex-direction:column !important;
}
.commercial-new-contact-card .commercial-new-contact-modal{
  min-width:0 !important;
  width:100% !important;
  max-width:100% !important;
  max-height:calc(100dvh - 28px) !important;
  overflow-y:auto !important;
  overflow-x:hidden !important;
  padding:24px !important;
  box-sizing:border-box !important;
  overscroll-behavior:contain;
}
.commercial-new-contact-card .form-grid{
  grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  gap:12px 14px !important;
}
.commercial-new-contact-card .form-grid > label,
.commercial-new-contact-card input,
.commercial-new-contact-card select,
.commercial-new-contact-card textarea{
  min-width:0 !important;
  max-width:100% !important;
}
.commercial-new-contact-card .actions{
  position:sticky !important;
  bottom:-24px !important;
  z-index:3 !important;
  margin:16px -24px -24px !important;
  padding:14px 24px calc(14px + env(safe-area-inset-bottom)) !important;
  background:var(--panel) !important;
  border-top:1px solid var(--line) !important;
}
@media(max-width:680px){
  .modal:has(.commercial-new-contact-modal){padding:8px !important;align-items:center !important}
  .modal-card.commercial-new-contact-card{
    width:calc(100vw - 16px) !important;
    max-height:calc(100dvh - 16px) !important;
    border-radius:14px !important;
  }
  .commercial-new-contact-card .commercial-new-contact-modal{
    max-height:calc(100dvh - 16px) !important;
    padding:18px 16px !important;
  }
  .commercial-new-contact-card .form-grid{grid-template-columns:1fr !important}
  .commercial-new-contact-card .form-grid .full{grid-column:1 !important}
  .commercial-new-contact-card .actions{
    bottom:-18px !important;
    margin:14px -16px -18px !important;
    padding:12px 16px calc(12px + env(safe-area-inset-bottom)) !important;
    display:grid !important;
    grid-template-columns:1fr !important;
  }
  .commercial-new-contact-card .actions button{width:100% !important}
}

/* ===== v2.9 usabilidade ===== */
#navToggle{display:inline-flex;align-items:center;justify-content:center;gap:12px;width:44px;height:38px;padding:0;border:0;border-radius:12px;background:transparent;color:inherit;cursor:pointer;opacity:.8}
#navToggle:hover{opacity:1;background:rgba(127,127,127,.18)}
#navToggle svg{width:20px;height:20px;flex:none;transition:transform .2s}
html body.nav-expanded #navToggle svg{transform:rotate(180deg)}
.nav-brand-full,.nav-user{display:none}
/* menu recolhido: só o ícone da marca (a logo larga ficava cortada) */
html body:not(.nav-expanded) .brand .brand-logo{display:none!important}
html body:not(.nav-expanded) .brand .brand-icon{display:block!important;width:40px!important;height:40px!important;border-radius:12px!important;object-fit:cover}
html body:not(.nav-expanded) #navToggle .nav-label,html body:not(.nav-expanded) #logoutBtn .nav-label{display:none!important}
@media(max-width:680px){#navToggle,.nav-user,.nav-brand-full{display:none!important}}
@media(min-width:681px){
  html body.nav-expanded #app{grid-template-columns:252px minmax(0,1fr)!important}
  html body.nav-expanded .sidebar-shell{align-items:stretch!important;padding:12px 10px!important}
  html body.nav-expanded .brand{display:none!important}
  html body.nav-expanded .nav-brand-full{display:flex;align-items:center;padding:4px 8px 14px}
  .nav-brand-full img{height:40px;width:auto;max-width:190px;object-fit:contain}
  .nav-brand-full .nbf-light{display:none}
  html[data-theme="light"] .nav-brand-full .nbf-dark{display:none}
  html[data-theme="light"] .nav-brand-full .nbf-light{display:block}
  html body.nav-expanded .nav-menu{align-items:stretch!important;gap:3px!important;width:100%;flex:1 1 auto;min-height:0;overflow-y:auto;overflow-x:hidden}
  html body.nav-expanded .nav-menu button,html body.nav-expanded #logoutBtn,html body.nav-expanded #navToggle{width:100%!important;height:42px!important;padding:0 10px!important;justify-content:flex-start!important;gap:10px!important;border-radius:12px!important}
  html body.nav-expanded .nav-icon{flex:none}
  html body.nav-expanded #logoutBtn,html body.nav-expanded #navToggle{display:flex!important;align-items:center!important}
  html body.nav-expanded .nav-menu button{display:flex!important;align-items:center!important}
  html body.nav-expanded .nav-menu button .nav-label,html body.nav-expanded #logoutBtn .nav-label,html body.nav-expanded #navToggle .nav-label{display:block!important;line-height:1.25!important;font-size:13.5px;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  html body.nav-expanded .nav-menu button::after,html body.nav-expanded #logoutBtn::after{display:none!important}
  html body.nav-expanded .nav-menu button>span[id]{position:static!important;margin-left:auto}
  html body.nav-expanded .sidebar-footer{width:100%;align-items:stretch!important;justify-items:stretch!important}
  html body.nav-expanded #me{display:none!important}
  html body.nav-expanded .nav-user{display:flex;align-items:center;gap:10px;padding:8px 10px;border-radius:12px;min-width:0}
}
.nav-user .nu-av{flex:none;width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font-weight:800;font-size:14px;background:rgba(15,143,98,.16);color:#0f8f62}
html[data-theme="dark"] .nav-user .nu-av{background:rgba(37,211,102,.18);color:#25d366}
.nu-tx{display:flex;flex-direction:column;min-width:0;line-height:1.25}
.nu-tx strong{font-size:13.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#111b21}
html[data-theme="dark"] .nu-tx strong{color:#e9edef}
.nu-tx small{font-size:11.5px;color:#667781;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
html[data-theme="dark"] .nu-tx small{color:#8696a0}
/* aviso de WhatsApp desconectado */
.wa-banner{flex:none;display:flex;align-items:center;gap:12px;padding:10px 20px;font-size:13.5px;line-height:1.35;border-bottom:1px solid transparent}
.wa-banner[hidden]{display:none!important}
.wa-banner.off{background:#fdecea;color:#7a1f16;border-color:#f5c2bd}
.wa-banner.wait{background:#fff6dd;color:#6b4e00;border-color:#f1dc9a}
html[data-theme="dark"] .wa-banner.off{background:#3a1a1a;color:#ffb4ab;border-color:#5c2a2a}
html[data-theme="dark"] .wa-banner.wait{background:#3a3217;color:#ffd97a;border-color:#5a4d1f}
.wab-ic{flex:none;display:inline-flex}.wab-ic svg{width:20px;height:20px}
.wab-tx{display:flex;flex-direction:column;min-width:0;flex:1}
.wab-tx span{opacity:.9}
.wab-btn{flex:none;padding:8px 16px;border-radius:10px;white-space:nowrap}
.wab-x{flex:none;background:transparent;border:0;color:inherit;font-size:20px;line-height:1;cursor:pointer;opacity:.7;padding:4px 8px;border-radius:8px}
.wab-x:hover{opacity:1;background:rgba(127,127,127,.15)}
@media(max-width:680px){.wa-banner{padding:8px 12px;gap:8px;flex-wrap:wrap}.wab-tx{flex:1 1 60%}}
/* primeiros passos */
.onboard-card{margin-bottom:14px;padding:18px 20px}
.onboard-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.onboard-head h3{margin:0 0 2px}.onboard-head p{margin:0;font-size:13px}
.onboard-progress{height:6px;border-radius:99px;background:rgba(127,127,127,.22);overflow:hidden;margin:12px 0 14px}
.onboard-progress>i{display:block;height:100%;background:#0f8f62;border-radius:99px}
.onboard-steps{display:grid;gap:8px}
.onboard-step{display:flex;align-items:center;gap:12px;padding:10px 12px;border-radius:12px;border:1px solid rgba(127,127,127,.25)}
.onboard-step.done{opacity:.6}
.onboard-step.current{border-color:#0f8f62;background:rgba(15,143,98,.08)}
.onboard-num{flex:none;width:26px;height:26px;border-radius:50%;display:grid;place-items:center;font-size:13px;font-weight:700;background:rgba(127,127,127,.25)}
.onboard-step.done .onboard-num,.onboard-step.current .onboard-num{background:#0f8f62;color:#fff}
.onboard-tx{flex:1;min-width:0}.onboard-tx strong{display:block;font-size:14px}.onboard-tx span{font-size:12.5px;opacity:.75}
.onboard-hide{background:transparent;border:0;color:inherit;opacity:.65;cursor:pointer;font-size:12.5px;text-decoration:underline;white-space:nowrap}
.onboard-hide:hover{opacity:1}
@media(max-width:680px){.onboard-step{flex-wrap:wrap}.onboard-step button{width:100%}}
/* tela vazia do chat: respiro entre texto e atalhos */
.wa-empty-state p{margin-bottom:22px!important}
.wa-empty-illustration svg{width:44px!important;height:44px!important}
.wa-empty-state .wa-empty-shortcuts{margin-top:26px!important}
.wa-filter-row{overflow-x:auto!important;scrollbar-width:none}
.wa-filter-row::-webkit-scrollbar{display:none}
.wa-filter-row .wa-filter{flex:none}

/* tela vazia do chat — estilo WhatsApp Web */
.wa-empty-pro{width:100%;height:100%;box-sizing:border-box;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:34px;padding:24px;text-align:center;overflow-y:auto;color:#111b21}
html[data-theme="dark"] .wa-empty-pro{color:#e9edef}
.wep-card{width:min(440px,100%);box-sizing:border-box;padding:38px 32px 32px;border-radius:28px;display:flex;flex-direction:column;align-items:center;background:#fff;box-shadow:0 1px 3px rgba(11,20,26,.1)}
html[data-theme="dark"] .wep-card{background:#111b21;box-shadow:none;border:1px solid #1f2c33}
.wep-logo{height:62px;width:auto;max-width:100%;object-fit:contain;margin-bottom:24px}
.wep-logo-light{display:none}
html[data-theme="light"] .wep-logo-dark{display:none}
html[data-theme="light"] .wep-logo-light{display:block}
.wep-card h2{margin:0 0 10px;font-size:23px;font-weight:500;line-height:1.25}
.wep-card p{margin:0 0 24px!important;max-width:340px;font-size:14.5px;line-height:1.45;opacity:.7}
.wep-cta{border:0;border-radius:999px;padding:11px 24px;font-size:14px;font-weight:700;cursor:pointer;background:#d9fdd3;color:#0b5d43;transition:filter .15s}
html[data-theme="dark"] .wep-cta{background:#0f3d2c;color:#25d366}
.wep-cta:hover{filter:brightness(.95)}
html[data-theme="dark"] .wep-cta:hover{filter:brightness(1.25)}
.wep-shortcuts{display:flex;flex-wrap:wrap;justify-content:center;gap:18px 26px;max-width:640px}
.wep-shortcuts button{width:92px;display:flex;flex-direction:column;align-items:center;gap:10px;padding:0;border:0;background:none;color:inherit;font-size:12.5px;font-weight:600;line-height:1.25;cursor:pointer}
.wep-shortcuts button svg{box-sizing:border-box;width:52px;height:52px;padding:15px;border-radius:50%;background:rgba(127,127,127,.17);transition:background .15s,color .15s}
.wep-shortcuts button:hover svg{background:rgba(37,211,102,.22);color:#0f8f62}
html[data-theme="dark"] .wep-shortcuts button:hover svg{color:#25d366}
.wep-shortcuts{align-items:flex-start;gap:18px 14px}
.wep-shortcuts button{width:112px}
.wep-shortcuts button svg.i{box-sizing:border-box!important;width:52px!important;height:52px!important;min-width:52px!important;padding:15px!important;flex:none!important}
.wep-shortcuts button span{display:block;white-space:nowrap}
.wep-shortcuts{margin-top:16px}
#acsCode[readonly],#csCode[readonly]{opacity:.75;cursor:not-allowed}
.install-actions{flex-wrap:wrap;gap:8px}
@media(min-width:1200px){html body .top-install-btn{width:auto!important;padding:0 14px!important}html body .top-install-btn span{display:inline!important;font-size:13px}}
@media(min-width:1200px){html body .top-install-btn{flex-direction:row!important;gap:8px!important;height:40px!important;border:1px solid rgba(127,127,127,.35)!important;border-radius:999px!important;background:transparent!important}html body .top-install-btn span{white-space:nowrap}}
@media(min-width:1200px){html body .top-install-btn{display:inline-flex!important;flex-direction:row!important;align-items:center!important;justify-content:center!important;line-height:1.2!important}html body .top-install-btn .i{flex:none}}

/* v2.10 */
html body .nav-menu button.nav-off.nav-off{display:none!important}
.settings-extra{display:grid;gap:14px;margin-top:14px}
.settings-extra .card h3{margin-top:0}
.ab-head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.ab-pill{padding:4px 12px;border-radius:999px;font-size:12px;font-weight:700}
.ab-pill.on{background:rgba(15,143,98,.16);color:#0f8f62}
.ab-pill.off{background:rgba(214,69,65,.16);color:#d64541}
.switch-line{display:flex;align-items:center;gap:10px;font-weight:700}
.ab-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:10px;margin:8px 0}
.backup-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px 0;border-bottom:1px solid rgba(127,127,127,.22)}
.backup-row small{display:block;opacity:.7}
.backup-dl{padding:7px 14px;border-radius:10px;border:1px solid rgba(127,127,127,.35);color:inherit;text-decoration:none;font-weight:600;font-size:13px}
.backup-dl:hover{background:rgba(127,127,127,.15)}
.campaign-wait{display:block;color:#c58a00;font-weight:600;margin-top:2px}
html[data-theme="dark"] .settings-extra .switch-line{color:#e9edef}
html[data-theme="light"] .settings-extra .switch-line{color:#111b21}
.settings-extra .switch-line input{width:18px;height:18px}
.ab-grid{align-items:end}
html[data-theme="dark"] .settings-extra label:has(>input[type=checkbox]){color:#cfd8dc}
html[data-theme="light"] .settings-extra label:has(>input[type=checkbox]){color:#41525d}

/* Conversas: ações de gestão e exportação */
body[data-view="commercial"] .commercial-chat-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:5px} 
.commercial-chat-actions a.secondary,.chat-head a.secondary{display:inline-flex;align-items:center;padding:8px 10px;border-radius:8px;color:var(--text);background:var(--soft);text-decoration:none;font-size:12px;white-space:nowrap}
.commercial-chat-actions .badge{white-space:normal}
.modal-card [id$="Sellers"] label{display:flex;align-items:center;gap:8px}
.modal-card [id$="Sellers"] input[type="checkbox"]{width:auto;flex:none}

/* 2.11.1: cabeçalho não disputa largura com as ações quando o CRM abre. */
body[data-view="commercial"] .commercial-chat-head{
  display:flex!important;
  flex-direction:column!important;
  align-items:stretch!important;
  justify-content:flex-start!important;
  gap:10px!important;
  height:auto!important;
  flex-wrap:nowrap!important;
  min-width:0;
}
body[data-view="commercial"] .commercial-chat-person{
  width:100%;
  flex:0 0 auto;
  min-width:0;
}
body[data-view="commercial"] .commercial-chat-person > div:last-child{
  min-width:0;
  flex:1;
  overflow:hidden;
}
body[data-view="commercial"] .commercial-chat-actions{
  display:grid!important;
  grid-template-columns:repeat(auto-fit,minmax(min(100%,130px),1fr));
  width:100%;
  min-width:0;
  gap:6px!important;
  align-items:stretch;
}
body[data-view="commercial"] .commercial-chat-actions > button,
body[data-view="commercial"] .commercial-chat-actions > a.secondary{
  display:flex;
  justify-content:center;
  align-items:center;
  width:100%;
  min-width:0;
  height:auto!important;
  min-height:36px;
  padding:8px!important;
  margin:0;
  box-sizing:border-box;
  white-space:normal;
  overflow-wrap:anywhere;
  text-align:center;
  line-height:1.25;
  font-size:12px;
}
body[data-view="commercial"] .commercial-chat-actions > .badge{
  grid-column:1 / -1;
}

/* 2.11.2 — mesma estrutura de conversas em todos os perfis comerciais. */
body[data-view="commercial"] .commercial-chat-head{
  flex-direction:row!important;
  flex-wrap:wrap!important;
  align-items:center!important;
  gap:6px 10px!important;
}
body[data-view="commercial"] .commercial-chat-person{
  flex:1 1 160px;
  width:auto;
}
body[data-view="commercial"] .commercial-chat-actions{
  display:flex!important;
  flex:0 1 auto;
  flex-wrap:wrap!important;
  width:auto;
  max-width:100%;
  gap:4px!important;
  justify-content:flex-end;
}
body[data-view="commercial"] .commercial-chat-actions > button,
body[data-view="commercial"] .commercial-chat-actions > a.secondary{
  width:auto;
  padding:7px 9px!important;
  min-height:34px;
  font-size:11px;
  white-space:nowrap;
}
body[data-view="commercial"] .commercial-chat-actions > .conversation-icon-action,
.conversation-icon-action{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 34px;
  width:34px!important;
  height:34px!important;
  min-width:34px!important;
  padding:7px!important;
  border-radius:50%;
  cursor:pointer;
}
.conversation-icon-action svg{width:18px;height:18px;flex:none}
body[data-view="commercial"] .commercial-chat-actions > .danger.conversation-icon-action{color:#ef6670}
.commercial-list-row-actions{display:flex;flex-direction:column;align-items:center;gap:3px;flex:none}
.commercial-list-row-actions .conversation-icon-action{color:var(--muted)}
.commercial-list-row-actions .conversation-icon-action:hover{color:#ef6670;background:var(--soft)}
body[data-view="commercial"] .commercial-chat-actions > .badge{white-space:normal}

/* Painel inicial compartilhado com Meus atendimentos. */
body[data-view="commercial"] .commercial-adm-chat.is-empty > .wa-empty-pro{
  width:100%;height:100%;min-width:0;min-height:0;
  position:relative;inset:auto;box-sizing:border-box;
  padding:24px;overflow-y:auto;
}
body[data-view="commercial"] .commercial-adm-chat:not(.is-empty){
  display:block!important;min-width:0;min-height:0;padding:0!important;
}
@media(max-height:700px){
  body[data-view="commercial"] .commercial-empty-pro{gap:16px;padding:16px}
  body[data-view="commercial"] .commercial-empty-pro .wep-card{padding:24px}
}
@media(max-width:780px){
  body[data-view="commercial"] .commercial-adm-split.chat-open .commercial-adm-chat:not(.is-empty){display:block!important}
}

/* 2.11.4 — nenhum espaço é reservado ao CRM sem uma conversa aberta. */
body[data-view="commercial"] #commercialSplit > #commercialChat.commercial-welcome-only{
  display:block!important;position:relative!important;
  grid-column:2!important;grid-template-columns:none!important;
  width:100%!important;max-width:none!important;height:100%!important;
  min-width:0!important;min-height:0!important;
  padding:0!important;margin:0!important;overflow:hidden!important;
}
body[data-view="commercial"] #commercialChat.commercial-welcome-only > .commercial-empty-pro{
  position:absolute!important;inset:0!important;
  width:100%!important;height:100%!important;max-width:none!important;
  min-height:0!important;min-width:0!important;box-sizing:border-box!important;
  display:flex!important;flex-direction:column!important;
  align-items:center!important;justify-content:center!important;
  padding:24px!important;margin:0!important;overflow-y:auto!important;
}
body[data-view="commercial"] #commercialChat.commercial-welcome-only .commercial-crm-panel,
body[data-view="commercial"] #commercialChat.commercial-welcome-only .commercial-crm-shell{
  display:none!important;
}
body[data-view="commercial"] #commercialChat.commercial-welcome-only .wep-card,
body[data-view="commercial"] #commercialChat.commercial-welcome-only .wep-shortcuts{
  flex:none;max-width:100%;
}
@media(max-width:780px){
  body[data-view="commercial"] #commercialSplit > #commercialChat.commercial-welcome-only{grid-column:1!important;min-height:520px!important;height:65vh!important;}
}
@media(max-height:620px){
  body[data-view="commercial"] #commercialChat.commercial-welcome-only > .commercial-empty-pro{justify-content:flex-start!important;gap:16px!important;}
}

/* 2.11.5 — define a altura do contêiner Comercial antes de centralizar o painel. */
body[data-view="commercial"] #content:has(#commercialSplit){
  display:flex!important;
  flex-direction:column!important;
  min-height:0!important;
}
body[data-view="commercial"] #commercialBody:has(> #commercialSplit){
  display:flex!important;
  flex-direction:column!important;
  flex:1 1 0!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  overflow:hidden!important;
}
body[data-view="commercial"] #commercialBody > #commercialSplit{
  display:grid!important;
  flex:1 1 0!important;
  height:100%!important;
  width:100%!important;
  min-height:0!important;
  grid-template-rows:minmax(0,1fr)!important;
}
body[data-view="commercial"] #commercialSplit > #commercialChat.commercial-welcome-only{
  display:flex!important;
  flex-direction:column!important;
  align-items:stretch!important;
  justify-content:center!important;
}
body[data-view="commercial"] #commercialChat.commercial-welcome-only > .commercial-empty-pro{
  position:relative!important;
  inset:auto!important;
  flex:1 1 0!important;
  height:100%!important;
  justify-content:center!important;
}
@media(max-width:780px){
  body[data-view="commercial"] #commercialBody > #commercialSplit{grid-template-rows:auto minmax(520px,1fr)!important;overflow-y:auto!important;}
  body[data-view="commercial"] #commercialSplit.chat-open{grid-template-rows:minmax(0,1fr)!important;}
}

/* Campanhas comerciais: resumo, filtros e funil por campanha. */
.telehub-campaigns{padding:16px 0;min-width:0;color:var(--text)}
.telehub-campaigns .tc-header{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:16px}
.telehub-campaigns .tc-header h2{margin:0 0 3px;font-size:22px}.telehub-campaigns .tc-header p{margin:0;font-size:13px;color:var(--muted)}
.telehub-campaigns .tc-header button{background:#0f6e56;border-color:#0f6e56;color:#e1f5ee;white-space:nowrap;border-radius:8px}.telehub-campaigns .tc-header button:hover{background:#085041}
.telehub-campaigns .tc-kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin-bottom:16px}
.telehub-campaigns .tc-kpis>div{background:var(--panel2);border-radius:8px;padding:12px 14px}.telehub-campaigns .tc-kpis span{display:block;font-size:12px;color:var(--muted)}.telehub-campaigns .tc-kpis b{display:block;font-size:22px;font-weight:500;margin-top:2px}.telehub-campaigns .tc-kpis small{font-size:11px;color:var(--muted)}
.telehub-campaigns .tc-info{display:flex;gap:8px;font-size:13px;line-height:1.5;color:var(--muted);background:var(--panel2);border-radius:8px;padding:10px 12px;margin-bottom:14px}.telehub-campaigns .tc-info strong{font-weight:500;color:var(--text)}
.telehub-campaigns .tc-filters{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:12px}.telehub-campaigns .tc-filters button{font-size:13px;padding:5px 12px;border-radius:999px;border:1px solid var(--line);color:var(--muted);background:transparent;min-height:32px}.telehub-campaigns .tc-filters button.active{background:rgba(29,158,117,.12);border-color:#1d9e75;color:#1d9e75}
.telehub-campaigns .tc-card{background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:14px 16px;margin-bottom:10px;min-width:0}.telehub-campaigns .tc-top{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap}.telehub-campaigns .tc-heading{min-width:0;flex:1 1 260px}.telehub-campaigns .tc-name{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.telehub-campaigns .tc-name b{font-size:15px;font-weight:500;overflow-wrap:anywhere}.telehub-campaigns .tc-status{font-size:11px;padding:2px 8px;border-radius:999px;white-space:nowrap}.telehub-campaigns .tc-status.completed{background:rgba(29,158,117,.12);color:#1d9e75}.telehub-campaigns .tc-status.running{background:rgba(186,117,23,.12);color:#ba7517}.telehub-campaigns .tc-status.neutral{background:var(--panel2);color:var(--muted)}
.telehub-campaigns .tc-meta{font-size:12px;color:var(--muted);margin-top:3px;overflow-wrap:anywhere}.telehub-campaigns .tc-actions{display:flex;gap:6px;flex-wrap:wrap}.telehub-campaigns .tc-actions button{font-size:13px;padding:6px 12px;min-height:32px;border-radius:8px}
.telehub-campaigns .tc-progress{height:6px;background:var(--panel2);border-radius:3px;margin:12px 0 4px;overflow:hidden}.telehub-campaigns .tc-progress i{display:block;height:100%;background:#1d9e75;transition:width .2s}.telehub-campaigns .tc-progress-label{display:flex;justify-content:space-between;gap:10px;font-size:11px;color:var(--muted);margin-bottom:12px}
.telehub-campaigns .tc-funnel{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:6px}.telehub-campaigns .tc-funnel>div{text-align:center;padding:8px 2px;border-radius:8px;background:var(--panel2);min-width:0}.telehub-campaigns .tc-funnel b{display:block;font-size:18px;font-weight:500}.telehub-campaigns .tc-funnel span{font-size:11px;color:var(--muted);overflow-wrap:anywhere}.telehub-campaigns .tc-funnel .zero b{color:var(--muted)}.telehub-campaigns .tc-funnel .success b{color:#1d9e75}.telehub-campaigns .tc-funnel .error b{color:var(--danger,#dc3545)}
.telehub-campaigns .tc-alert{margin-top:10px;font-size:12px;color:#ba7517}.telehub-campaigns .tc-empty{padding:30px;text-align:center;color:var(--muted);background:var(--panel);border:1px solid var(--line);border-radius:12px}.telehub-campaigns .tc-message{margin-top:14px;padding:12px;background:var(--panel2);border-radius:8px;font-size:13px}.telehub-campaigns .tc-message p{white-space:pre-wrap;overflow-wrap:anywhere}.telehub-campaigns .campaign-live-detail{margin-top:14px}
@media(max-width:760px){.telehub-campaigns .tc-funnel{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:560px){.telehub-campaigns .tc-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.telehub-campaigns .tc-header{flex-wrap:wrap}.telehub-campaigns .tc-card{padding:12px}.telehub-campaigns .tc-actions{width:100%}}

/* Campanhas: foto com legenda e prévia do envio */
.campaign-photo-picker{padding:14px;border:1px solid var(--border,#d5dce2);border-radius:12px;margin:14px 0}
#promoPhotoInfo{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:10px 0;overflow-wrap:anywhere}
.campaign-photo-thumb{width:110px;max-height:140px;object-fit:contain;border-radius:8px}
.campaign-preview-controls{margin:12px 0}
#promoPreviewPanel{margin:14px 0;border-radius:12px;overflow:hidden}
.campaign-preview-bubble{display:flow-root;overflow-wrap:anywhere;max-width:min(90%,420px)}
.campaign-preview-image{display:block;width:100%;height:auto;max-height:500px;object-fit:contain;border-radius:6px;margin-bottom:8px}
.campaign-preview-caption{white-space:pre-wrap;color:#111b21}
.campaign-preview-caption code{white-space:pre-wrap;font-family:monospace}
#promoPreviewPanel>small{display:block;padding:10px}

.contact-photo-name{display:flex;align-items:center;gap:12px;margin:8px 0}.contact-photo-name .avatar{flex:none;width:40px!important;height:40px!important}

.commercial-floating-menu{position:absolute;right:18px;bottom:110px;z-index:20}.commercial-floating-ball{width:48px;height:48px;border-radius:50%;border:0;background:var(--accent,#128c7e);color:white;font-size:28px;box-shadow:0 4px 14px #0004;cursor:pointer}.commercial-floating-options{position:absolute;right:0;bottom:58px;width:245px;border-radius:14px;background:var(--panel,#fff);border:1px solid var(--border,#ddd);box-shadow:0 8px 24px #0003;padding:8px}.commercial-floating-options[hidden]{display:none}.commercial-floating-options button{display:block;width:100%;text-align:left;padding:12px;border:0;background:transparent;color:var(--text);border-radius:8px;cursor:pointer}.commercial-floating-options button:hover{background:var(--panel2,#eee)}.deleted-audit-card{border:1px solid var(--border,#ddd);padding:18px;border-radius:12px;margin:14px 0}.deleted-original{white-space:pre-wrap;padding:16px;background:var(--panel2,#eee);border-radius:8px;margin:12px 0}.deleted-audit-card img{max-width:300px;max-height:300px;object-fit:contain}.signature-example{background:var(--panel2,#eee);padding:18px;border-radius:12px;white-space:pre-wrap}.quick-template{display:flex;flex-direction:column;gap:6px;width:100%;text-align:left;background:var(--panel2,#eee);color:var(--text);padding:12px;margin:8px 0;border:1px solid var(--border,#ddd);border-radius:10px}.quick-template span{white-space:pre-wrap}.commercial-chat-actions #deleteCommercialConversation{display:none}

/* Menu flutuante TeleHub conforme referência enviada */
body[data-view="commercial"] .commercial-floating-menu{right:14px;bottom:96px;display:flex;flex-direction:column;align-items:flex-end;gap:10px;z-index:32}
body[data-view="commercial"] .commercial-floating-options{position:static;width:auto;max-width:calc(100vw - 48px);display:flex;flex-direction:column;align-items:flex-end;gap:8px;padding:0;background:none;border:0;box-shadow:none}
body[data-view="commercial"] .commercial-floating-options[hidden]{display:none}
body[data-view="commercial"] .commercial-floating-options .commercial-action-item{display:flex;align-items:center;justify-content:flex-end;gap:10px;width:auto;padding:0;background:none;border:0;color:var(--text);cursor:pointer;transform-origin:right bottom;animation:commercial-menu-in .28s cubic-bezier(.3,1.5,.5,1) both;animation-delay:calc((4 - var(--i))*45ms)}
body[data-view="commercial"] .commercial-action-label{background:var(--panel,#111b21);border:1px solid var(--border,#1f2c34);padding:7px 12px;border-radius:10px;font-size:14px;box-shadow:0 4px 14px #0004;white-space:nowrap}
body[data-view="commercial"] .commercial-action-icon{width:52px;height:52px;flex:none;border-radius:50%;background:var(--panel,#111b21);display:grid;place-items:center;border:1px solid var(--border,#1f2c34);box-shadow:0 2px 10px #0004;transition:transform .2s,border-color .2s}
body[data-view="commercial"] .commercial-action-item:hover .commercial-action-icon,body[data-view="commercial"] .commercial-action-item:focus-visible .commercial-action-icon{transform:scale(1.08);border-color:#39ff88}
body[data-view="commercial"] .commercial-action-item.delete-action:hover .commercial-action-icon,body[data-view="commercial"] .commercial-action-item.delete-action:focus-visible .commercial-action-icon{border-color:#ff4d6d}
body[data-view="commercial"] .commercial-action-item:focus-visible{outline:2px solid #39ff88;outline-offset:4px;border-radius:12px}
body[data-view="commercial"] .commercial-floating-ball{width:76px;height:76px;padding:0;border:0;border-radius:0;background:none;box-shadow:none;cursor:pointer;transition:transform .25s,filter .3s;line-height:0}
body[data-view="commercial"] .commercial-floating-ball svg{display:block;overflow:visible;width:100%;height:100%}
body[data-view="commercial"] .commercial-floating-ball:active{transform:scale(.9)}
body[data-view="commercial"] .commercial-floating-menu.is-open .commercial-floating-ball{transform:scale(.94);filter:drop-shadow(0 0 4px #39ff88) drop-shadow(0 0 12px #39ff88) drop-shadow(0 0 26px #39ff88);animation:commercial-menu-neon 1.8s ease-in-out infinite}
@keyframes commercial-menu-in{from{opacity:0;transform:translateY(24px) scale(.6)}to{opacity:1;transform:none}}
@keyframes commercial-menu-neon{50%{filter:drop-shadow(0 0 2px #39ff88) drop-shadow(0 0 8px #39ff88) drop-shadow(0 0 16px #39ff88)}}
@media(max-height:650px){body[data-view="commercial"] .commercial-action-icon{width:40px;height:40px}body[data-view="commercial"] .commercial-floating-options{gap:5px}body[data-view="commercial"] .commercial-floating-ball{width:60px;height:60px}body[data-view="commercial"] .commercial-floating-menu{bottom:82px}}
@media(prefers-reduced-motion:reduce){.commercial-floating-menu *{animation:none!important;transition:none!important}}

/* Ajuste compacto: abre somente o menu de ações */
body[data-view="commercial"] .commercial-floating-menu{bottom:88px;right:12px;gap:8px}
body[data-view="commercial"] .commercial-floating-ball{width:52px;height:52px}
body[data-view="commercial"] .commercial-action-icon{width:38px;height:38px}
body[data-view="commercial"] .commercial-action-icon svg{width:22px;height:22px}
body[data-view="commercial"] .commercial-action-label{padding:6px 10px;font-size:12px;border-radius:8px}
body[data-view="commercial"] .commercial-floating-options{gap:6px}
body[data-view="commercial"] .commercial-floating-options .commercial-action-item.delete-action{background:none!important;border:0!important;color:var(--text)!important;box-shadow:none!important}
body[data-view="commercial"] .commercial-action-item.delete-action .commercial-action-label{background:var(--panel,#111b21);color:var(--text);border-color:var(--border,#1f2c34)}
@media(max-height:650px){body[data-view="commercial"] .commercial-floating-ball{width:48px;height:48px}body[data-view="commercial"] .commercial-action-icon{width:34px;height:34px}}

/* Mensagens rápidas: cartões com altura natural e rolagem própria */
.modal-card.commercial-quick-modal-card{width:min(620px,100%);max-height:85vh;overflow:hidden;padding:20px}
.commercial-quick-modal{display:flex;flex-direction:column;max-height:calc(85vh - 40px);min-height:0;gap:16px}
.commercial-quick-modal-head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex:none}
.commercial-quick-modal-head h3{margin:0;font-size:18px}
.commercial-quick-modal-head .commercial-quick-close{width:34px;height:34px;padding:0;flex:none;font-size:24px;background:transparent;color:var(--text);border:1px solid var(--border,var(--line));border-radius:8px}
.commercial-quick-modal-list{display:flex;flex-direction:column;gap:12px;overflow-y:auto;min-height:0;padding:2px 6px 4px 2px;overscroll-behavior:contain}
.commercial-quick-modal-list button.commercial-quick-card{display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;height:auto;min-height:0;max-height:none;flex:0 0 auto;width:100%;gap:8px;padding:14px 16px;margin:0;text-align:left;white-space:normal;line-height:1.5;color:var(--text);background:var(--panel2,#f1f4f6);border:1px solid var(--border,var(--line));border-radius:10px;overflow:visible;cursor:pointer}
.commercial-quick-card strong{display:block;font-size:14px;line-height:1.4;overflow-wrap:anywhere}
.commercial-quick-card span{display:block;font-size:13px;font-weight:400;line-height:1.55;white-space:pre-wrap;overflow-wrap:anywhere;color:var(--muted,#667781)}
.commercial-quick-modal-list button.commercial-quick-card:hover{border-color:var(--accent,#00a884)}
@media(max-width:480px){.modal-card.commercial-quick-modal-card{padding:16px}.commercial-quick-modal{max-height:calc(85vh - 32px)}.commercial-quick-modal-list button.commercial-quick-card{padding:12px}}

/* Contatos salvos: modelo enviado, estilos limitados à agenda comercial. */
.saved-contact-wrap{max-width:900px;margin:0 auto;width:100%}
.saved-contact-card{--sc-bg:#111a21;--sc-field:#16212a;--sc-line:#243540;--sc-text:#f1f5f7;--sc-muted:#8a9ba6;--sc-btn:#18232b;background:var(--sc-bg);color:var(--sc-text);border:1px solid var(--sc-line);border-radius:14px;padding:20px}
.saved-contact-head,.saved-contact-title{display:flex;align-items:center;gap:10px}.saved-contact-head{justify-content:space-between;margin-bottom:14px;gap:12px}.saved-contact-title h3{font-size:16px;margin:0;font-weight:600}.saved-contact-count{font-size:12px;color:#7fd8c0;background:#0f2a26;border-radius:20px;padding:2px 10px}
.saved-contact-search{position:relative;margin-bottom:12px}.saved-contact-search>svg{position:absolute;left:14px;top:50%;transform:translateY(-50%);width:17px;height:17px;color:var(--sc-muted)}.saved-contact-search input{width:100%;height:42px;padding:0 14px 0 40px;background:var(--sc-field);border:1px solid var(--sc-line);border-radius:10px;color:var(--sc-text);font-size:14px;outline:none;margin:0}.saved-contact-search input:focus{border-color:#00a884;box-shadow:0 0 0 3px #00a8842e}
.saved-contact-card .saved-contact-row{display:flex;align-items:center;gap:14px;padding:12px;border:1px solid transparent;border-radius:10px;background:transparent;margin:0;transition:background .15s}.saved-contact-row+.saved-contact-row{border-top-color:var(--sc-line)}.saved-contact-card .saved-contact-row:hover{background:var(--sc-field);border-color:var(--sc-line)}.saved-contact-card .avatar{width:46px;height:46px;flex:none;font-size:15px;border-radius:50%;background:#0f2a26;color:#7fd8c0;overflow:hidden}.saved-contact-card .avatar.has-photo{border:2px solid #00a884}.saved-contact-card .avatar img{width:100%;height:100%;object-fit:cover}.saved-contact-row:nth-child(3n+2) .avatar:not(.has-photo){background:#1d2540;color:#a9b6ee}.saved-contact-row:nth-child(3n) .avatar:not(.has-photo){background:#3a2a1a;color:#f0c48a}
.saved-contact-info{flex:1;min-width:0}.saved-contact-info strong{display:block;font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.saved-contact-info small{display:flex;align-items:center;gap:6px;font-size:13px;color:var(--sc-muted);margin-top:2px}.saved-contact-info svg{width:15px;height:15px;color:#00a884}.saved-contact-actions{display:flex;gap:8px;flex:none}.saved-contact-card .saved-contact-btn{height:36px;border-radius:8px;border:1px solid var(--sc-line);background:var(--sc-btn);color:var(--sc-text);display:inline-flex;align-items:center;justify-content:center;gap:6px;font-size:13px;font-weight:600;padding:0 12px;cursor:pointer;margin:0}.saved-contact-btn svg{width:17px;height:17px}.saved-contact-card .saved-contact-btn:hover{background:var(--sc-field)}.saved-contact-card .saved-contact-btn.go{background:#00a884;border-color:#00a884;color:#06231c}.saved-contact-card .saved-contact-btn.go:hover{background:#00bf96}.saved-contact-card .saved-contact-btn.icon{width:36px;padding:0}.saved-contact-card .saved-contact-btn.del:hover{background:#3a1e22;border-color:#6b2f36;color:#ff8a8a}.saved-contact-empty{text-align:center;color:var(--sc-muted);padding:32px 12px}
html:not([data-theme="dark"]) .saved-contact-card{--sc-bg:#fff;--sc-field:#f1f6f5;--sc-line:#d9e4e1;--sc-text:#16212a;--sc-muted:#60756d;--sc-btn:#f5f8f7}
@media(max-width:560px){.saved-contact-card{padding:14px}.saved-contact-head{flex-wrap:wrap}.saved-contact-row{flex-wrap:wrap}.saved-contact-info{flex-basis:calc(100% - 70px)}.saved-contact-actions{width:100%;justify-content:flex-end}}

.status-post-card{max-width:900px;margin:auto}.status-preview{margin:16px 0;border-radius:14px;padding:24px;color:white;text-align:center;white-space:pre-wrap;overflow-wrap:anywhere}.status-audience{max-height:240px;overflow:auto;padding:12px;border:1px solid var(--line);border-radius:10px;margin-bottom:16px}.status-audience label{display:block;margin:8px 0}.status-post-card input[type=checkbox]{width:auto}

.deleted-chat-layout{display:grid;grid-template-columns:320px minmax(0,1fr);height:calc(100vh - 155px);min-height:400px;gap:12px}.deleted-chat-list{display:flex;flex-direction:column;min-height:0;margin:0!important;padding:14px!important}#deletedRows{overflow:auto;min-height:0;flex:1}.deleted-chat-item{display:flex;align-items:center;gap:10px;width:100%;text-align:left;padding:12px;background:transparent;color:var(--text);border:0;border-bottom:1px solid var(--line);border-radius:8px}.deleted-chat-item.active,.deleted-chat-item:hover{background:var(--soft)}.deleted-chat-item span{min-width:0}.deleted-chat-item strong,.deleted-chat-item small{display:block;overflow:hidden;text-overflow:ellipsis}.deleted-chat-panel{display:flex;flex-direction:column;min-width:0;min-height:0;border:1px solid var(--line);border-radius:12px;overflow:hidden}.deleted-chat-panel .chat-head{flex:none;gap:10px}.deleted-chat-panel .mine-who{flex:1;min-width:0}.deleted-chat-messages{flex:1;min-height:0;overflow-y:auto;display:flex;flex-direction:column;gap:10px;padding:20px}.audit-bubble{padding:10px 14px;border-radius:10px;max-width:85%;width:fit-content;margin:0!important;background:var(--card);align-self:flex-start;overflow-wrap:anywhere}.audit-bubble.out{align-self:flex-end;background:#164c40;color:#f1f5f7}.audit-author{font-weight:600;font-size:12px;margin-bottom:5px}.audit-text{white-space:pre-wrap}.audit-file{display:block;margin:8px 0}.audit-bubble>small{display:block;font-size:11px;opacity:.7;text-align:right}.audit-deleted-label{border-top:1px solid #8884;margin-top:7px;padding-top:5px;font-size:11px;color:#f1a69b}.audit-bubble.in .audit-deleted-label{color:#cb5646}#auditBack{display:none}@media(max-width:800px){.deleted-chat-layout{grid-template-columns:1fr}.deleted-chat-panel{display:none}.deleted-chat-layout.audit-open .deleted-chat-list{display:none}.deleted-chat-layout.audit-open .deleted-chat-panel{display:flex}#auditBack{display:inline-flex}}

/* Cada mensagem mantém sua altura, mesmo em históricos longos. */
.deleted-chat-panel .deleted-chat-messages{display:flex!important;flex-direction:column!important;align-items:stretch;justify-content:flex-start;overflow-y:auto!important;overflow-x:hidden;gap:14px!important;position:relative}
.deleted-chat-messages>.audit-bubble{display:block!important;flex:0 0 auto!important;position:relative!important;inset:auto!important;float:none!important;transform:none!important;min-height:min-content;height:auto!important;margin:0!important;box-sizing:border-box;clear:both;max-width:min(85%,620px)}
.deleted-chat-messages>.audit-bubble.in{align-self:flex-start}.deleted-chat-messages>.audit-bubble.out{align-self:flex-end}.audit-bubble .audit-text{display:block;white-space:pre-wrap;line-height:1.5}.audit-bubble img,.audit-bubble video{max-width:100%!important;height:auto}.audit-bubble audio{max-width:100%}.audit-bubble .audit-deleted-label{line-height:1.5}.deleted-chat-list .deleted-chat-item{flex-shrink:0}

/* Referência mensagens-apagadas.html, limitada ao histórico comercial. */
.deleted-chat-layout{--audit-bg:#111a21;--audit-field:#16212a;--audit-line:#243540;--audit-text:#f1f5f7;--audit-muted:#8a9ba6;grid-template-columns:380px minmax(0,1fr);gap:16px;color:var(--audit-text)}
.deleted-chat-layout .deleted-chat-list,.deleted-chat-layout .deleted-chat-panel{background:var(--audit-bg);border:1px solid var(--audit-line);border-radius:14px}.deleted-chat-layout .deleted-chat-list{padding:0!important;overflow:hidden}.deleted-chat-list .section-title{padding:18px 18px 12px;margin:0;flex:none;gap:10px}.deleted-chat-list h3{display:flex;align-items:center;gap:10px;font-size:16px;font-weight:600;margin:0}.audit-total{font-size:12px;font-weight:500;border-radius:20px;padding:2px 10px;background:#0f2a26;color:#7fd8c0}.audit-icon-btn{width:38px;height:38px;border-radius:10px;border:1px solid var(--audit-line);background:#18232b;color:#d5dfe5;font-size:23px;flex:none;padding:0}.audit-search{position:relative;padding:0 18px 10px;flex:none}.audit-search>svg{position:absolute;left:32px;top:21px;transform:translateY(-50%);width:17px;height:17px;color:var(--audit-muted)}.audit-search input{height:42px;padding:0 14px 0 40px;width:100%;margin:0;background:var(--audit-field);border:1px solid var(--audit-line);border-radius:10px;color:var(--audit-text)}.audit-search input:focus{outline:none;border-color:#00a884;box-shadow:0 0 0 3px #00a8842e}
.deleted-chat-list #deletedRows{padding:4px 10px 12px;scrollbar-width:thin;scrollbar-color:#223039 transparent}.deleted-chat-list .deleted-chat-item{padding:10px;gap:12px;border:1px solid transparent;border-radius:10px;color:var(--audit-text);margin:0 0 4px;white-space:normal}.deleted-chat-item:hover{background:var(--audit-field)}.deleted-chat-list .deleted-chat-item.active{background:#12302b;border-color:#00a88466}.deleted-chat-layout .avatar{width:46px;height:46px;border-radius:50%;flex:none;background:#0f2a26;color:#7fd8c0}.deleted-chat-item:nth-child(3n+2) .avatar:not(.has-photo){background:#1d2540;color:#a9b6ee}.deleted-chat-item:nth-child(3n) .avatar:not(.has-photo){background:#3a2a1a;color:#f0c48a}.deleted-chat-item .audit-item-info{flex:1;min-width:0}.deleted-chat-item .audit-item-top{display:flex;align-items:center;justify-content:space-between;gap:8px}.audit-item-top strong{font-size:14.5px;font-weight:600;min-width:0}.deleted-chat-item .audit-message-count{display:inline-flex;align-items:center;gap:4px;background:#1c2a33;border-radius:20px;padding:2px 8px;font-size:11.5px;flex:none}.audit-message-count svg{width:12px;height:12px}.deleted-chat-item small{color:var(--audit-muted);font-size:12.5px;margin-top:2px}.deleted-chat-item .audit-item-tag{display:inline-flex;align-items:center;gap:4px;margin-top:5px;font-size:11px;color:#ff9a9a;background:#2d1a1d;border-radius:6px;padding:2px 7px}.audit-item-tag svg{width:12px;height:12px}
.deleted-chat-panel .chat-head{padding:16px 20px;background:var(--audit-bg);border-bottom:1px solid var(--audit-line);color:var(--audit-text)}.deleted-chat-panel .chat-head small{display:block;color:var(--audit-muted);font-size:12.5px;margin-top:3px}.audit-placeholder{margin:auto;text-align:center;color:var(--audit-muted);max-width:300px;padding:20px}.audit-placeholder p{font-size:14px;line-height:1.5}.audit-placeholder-ring{width:64px;height:64px;border-radius:50%;background:var(--audit-field);border:1px solid var(--audit-line);display:flex;align-items:center;justify-content:center;margin:0 auto 14px}.audit-placeholder-ring svg{width:28px;height:28px}.deleted-chat-panel .deleted-chat-messages{background:var(--audit-bg);padding:20px;gap:12px!important}.deleted-chat-messages>.audit-bubble{background:#1a2730;border:1px solid var(--audit-line);border-radius:12px 12px 12px 4px;color:var(--audit-text);max-width:70%}.deleted-chat-messages>.audit-bubble.out{background:#0d3a32;border-color:#00a88459;border-radius:12px 12px 4px 12px}.audit-text{font-size:14px;line-height:1.45}.audit-author{color:#7fd8c0}.audit-file{color:#7fd8c0}.audit-deleted-label{color:#ff9a9a!important}
html:not([data-theme="dark"]) .deleted-chat-layout{--audit-bg:#fff;--audit-field:#f1f6f5;--audit-line:#d9e4e1;--audit-text:#16212a;--audit-muted:#60756d}html:not([data-theme="dark"]) .deleted-chat-item.active{background:#e0f3ec}html:not([data-theme="dark"]) .deleted-chat-messages>.audit-bubble{background:#f1f5f6}html:not([data-theme="dark"]) .deleted-chat-messages>.audit-bubble.out{background:#d8f3e6}html:not([data-theme="dark"]) .audit-author,html:not([data-theme="dark"]) .audit-file{color:#087b60}html:not([data-theme="dark"]) .audit-deleted-label{color:#bb4545!important}
@media(max-width:1000px){.deleted-chat-layout{grid-template-columns:300px minmax(0,1fr)}}@media(max-width:800px){.deleted-chat-layout{grid-template-columns:1fr}.deleted-chat-messages>.audit-bubble{max-width:90%}}
/* Lista de conversas apagadas: cada contato ocupa uma linha independente. */
.deleted-chat-layout #deletedRows{display:block!important;position:relative;overflow-y:auto!important;overflow-x:hidden;flex:1 1 auto;min-height:0}
.deleted-chat-layout #deletedRows>.deleted-chat-item{display:flex!important;position:relative!important;inset:auto!important;transform:none!important;float:none!important;clear:both!important;flex:none!important;width:100%!important;height:auto!important;min-height:94px!important;margin:0 0 6px!important;padding:12px!important;box-sizing:border-box;align-items:center;overflow:hidden;line-height:1.4}
.deleted-chat-layout .deleted-chat-item>.avatar{flex:0 0 46px!important;position:relative!important;inset:auto!important}
.deleted-chat-layout .deleted-chat-item>.audit-item-info{display:block!important;position:static!important;flex:1 1 auto!important;min-width:0!important;height:auto!important;overflow:hidden}
.deleted-chat-layout .deleted-chat-item .audit-item-top{display:flex!important;position:static!important;align-items:center;justify-content:space-between;gap:8px;min-height:22px}
.deleted-chat-layout .deleted-chat-item .audit-item-top>strong{display:block!important;position:static!important;flex:1 1 auto;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;line-height:1.4}
.deleted-chat-layout .deleted-chat-item .audit-message-count{display:inline-flex!important;position:static!important;flex:0 0 auto;align-items:center;gap:4px}
.deleted-chat-layout .deleted-chat-item .audit-item-info>small{display:block!important;position:static!important;white-space:nowrap;line-height:1.5;margin:2px 0 0}
.deleted-chat-layout .deleted-chat-item .audit-item-tag{display:inline-flex!important;position:static!important;max-width:100%;align-items:center;gap:4px;white-space:normal;line-height:1.4;margin-top:5px}
.deleted-chat-layout .deleted-chat-item svg{display:inline-block!important;position:static!important;flex-shrink:0;width:12px;height:12px}

.status-action-icon{width:24px;height:24px}.nav-menu img.nav-icon{width:24px;height:24px}html[data-theme="dark"] .nav-menu img.nav-icon,html[data-theme="dark"] .status-action-icon{filter:invert(1)}#statusCompose[hidden]{display:none!important}

.wa-format-toolbar{display:flex;flex:none;gap:5px;padding:5px 10px;overflow-x:auto;background:var(--card)}.wa-format-toolbar button{flex:none;min-width:30px;height:28px;padding:2px 7px;font-size:12px}.wa-emoji-picker{position:fixed;z-index:10000;bottom:85px;right:25px;width:min(380px,90vw);max-height:60vh;background:var(--card,#fff);color:var(--text,#222);border:1px solid #8886;border-radius:12px;padding:12px;box-shadow:0 8px 30px #0005;display:flex;flex-direction:column;gap:8px}.wa-emoji-head{display:flex;justify-content:space-between;align-items:center}.wa-emoji-grid{overflow:auto;min-height:0;display:grid;grid-template-columns:repeat(8,1fr);gap:3px}.wa-emoji-grid button{padding:3px;height:38px;font-size:25px;background:transparent;border:none}.wa-mono,code{font-family:monospace}.wa-quote{display:block;border-left:3px solid #888;padding-left:10px;color:inherit}.wa-list{display:block;padding-left:10px}.msg-text .wa-list,.cmsg .wa-list{white-space:pre-wrap}

.message-actions-popover{position:fixed!important;z-index:10000!important;max-height:calc(100vh - 16px);overflow-y:auto;min-width:180px}.message-actions-popover button{display:flex;width:100%;align-items:center;text-align:left}

/* Emojis integrados à barra de mensagem. */
.wa-format-toolbar{display:none!important}.wa-emoji-button{flex:0 0 36px!important;width:36px!important;height:36px!important;padding:4px!important;background:transparent!important;border:0!important;font-size:23px!important;line-height:1!important}
html[data-theme="dark"] .wa-emoji-picker{background:#182229!important;color:#e9edef!important;border-color:#33434c!important}html[data-theme="dark"] .wa-emoji-picker input,html[data-theme="dark"] .wa-emoji-picker select{background:#202c33!important;color:#e9edef!important;border:1px solid #33434c!important}html[data-theme="dark"] .wa-emoji-picker button{color:#e9edef!important}html[data-theme="dark"] .composer,html[data-theme="dark"] .composer-wrap,html[data-theme="dark"] .commercial-chat-compose{background:#202c33!important;color:#e9edef!important}html[data-theme="dark"] #msgText,html[data-theme="dark"] #cChatInput{background:#2a3942!important;color:#e9edef!important;border-color:#33434c!important}html[data-theme="dark"] #msgText::placeholder,html[data-theme="dark"] #cChatInput::placeholder{color:#aebac1!important}.msg-text strong,.cmsg p strong,.audit-text strong{font-weight:700}.msg-text em,.cmsg p em,.audit-text em{font-style:italic}

.wa-unified-composer{display:flex!important;align-items:center!important;gap:10px!important;grid-template-columns:none!important;border-radius:28px!important;padding:10px 14px!important;min-height:58px!important;margin:8px!important;flex:none!important;box-sizing:border-box}.wa-unified-composer textarea{flex:1 1 auto!important;min-width:0!important;border:0!important;box-shadow:none!important;resize:none!important;padding:8px 4px!important;background:transparent!important;max-height:120px;min-height:36px!important;line-height:20px!important}.wa-unified-composer button{flex-shrink:0}.wa-plus-button{width:30px!important;height:36px!important;font-size:30px!important;padding:0!important;background:transparent!important;border:0!important;color:inherit!important}.wa-unified-composer .wa-emoji-button{font-size:24px!important;color:inherit!important}.wa-unified-composer[data-has-text="false"] #sendBtn,.wa-unified-composer[data-has-text="false"] #cChatSend{display:none!important}.wa-unified-composer[data-has-text="true"] #audioBtn,.wa-unified-composer[data-has-text="true"] #cAudio{display:none!important}html[data-theme="dark"] .wa-unified-composer{background:#242626!important;color:#e9edef!important}html[data-theme="dark"] .wa-unified-composer #msgText,html[data-theme="dark"] .wa-unified-composer #cChatInput{background:transparent!important;color:#e9edef!important}.wa-emoji-grid{height:300px;flex:1 1 auto;overflow-y:auto;align-content:start}.wa-emoji-grid button{flex:none;min-height:38px}.wa-emoji-picker{max-height:min(470px,70vh)}

.composer-wrap:has(#filePreview:not(:empty)) #sendBtn,.composer-wrap:has(#audioPreview:not(:empty)) #sendBtn{display:flex!important}

/* Barra integrada ao modelo enviado */
html body .wa-unified-composer{display:block!important;position:relative;width:100%;margin:0!important;padding:12px 16px 14px!important;border-radius:0!important;background:#f0f2f5!important;border-top:1px solid #d8dfe3!important;color:#526570!important}
.wa-message-box{display:flex;align-items:flex-end;gap:6px;background:#fff;border:1px solid #d8dfe3;border-radius:24px;padding:6px 6px 6px 8px;transition:border-color .15s,box-shadow .15s}
.wa-message-box:focus-within{border-color:#00a884;box-shadow:0 0 0 3px #00a88426}
html body .wa-message-box button{width:38px!important;height:38px!important;min-width:38px!important;padding:0!important;border:0!important;border-radius:50%!important;display:inline-flex;align-items:center;justify-content:center;background:transparent!important;color:inherit!important}
html body .wa-message-box button:hover{background:#879aa522!important}.wa-message-box button svg{width:21px;height:21px}.wa-message-box #cChatSend span{display:none}
html body .wa-message-box #sendBtn,html body .wa-message-box #cChatSend{background:#00a884!important;color:#06231c!important}.wa-message-box textarea{font-size:15px!important;line-height:22px!important;max-height:140px!important}
.wa-composer-hint{display:flex;gap:6px;flex-wrap:wrap;margin:8px 10px 0;font-size:11.5px;color:#6b7d88}.wa-composer-hint kbd{border:1px solid #879aa544;border-radius:5px;padding:0 6px;font:inherit}
.wa-attach-popup{position:absolute;bottom:calc(100% - 4px);left:16px;width:230px;padding:8px;border:1px solid #879aa544;border-radius:14px;background:#fff;box-shadow:0 12px 28px #0005;z-index:30}.wa-attach-popup[hidden]{display:none}.wa-attach-popup button{display:block;width:100%;padding:12px;text-align:left;background:transparent;border:0;color:inherit;border-radius:9px}.wa-attach-popup button:hover{background:#879aa522}
html[data-theme="dark"] body .wa-unified-composer{background:#0f171d!important;border-color:#1f2b33!important;color:#8a9ba6!important}html[data-theme="dark"] .wa-message-box{background:#1a252d;border-color:#2a3a45}html[data-theme="dark"] .wa-message-box:focus-within{background:#1e2c35;border-color:#00a884}html[data-theme="dark"] .wa-attach-popup{background:#16212a;color:#f1f5f7}
html body .wa-message-box .recording{background:#ff6b6b26!important;color:#ff6b6b!important}.cmsg small{display:flex;align-items:center;justify-content:flex-end;gap:4px}.cmsg .tick{color:#8a9ba6}.cmsg .tick.read{color:#53bdeb}

/* Conversas: visual do modelo telehub-conversas-whatsapp.html */
.wa-conversation-view{--cv-app:#efeae2;--cv-panel:#fff;--cv-head:#f0f2f5;--cv-field:#f0f2f5;--cv-line:#e9edef;--cv-text:#111b21;--cv-muted:#667781;--cv-in:#fff;--cv-out:#d9fdd3;--cv-select:#f0f2f5;--cv-quote:#00000009;--cv-blue:#007eaa}
html[data-theme="dark"] .wa-conversation-view{--cv-app:#0b141a;--cv-panel:#111b21;--cv-head:#202c33;--cv-field:#202c33;--cv-line:#222d34;--cv-text:#e9edef;--cv-muted:#8696a0;--cv-in:#202c33;--cv-out:#005c4b;--cv-select:#2a3942;--cv-quote:#00000026;--cv-blue:#53bdeb}
html body .wa-conversation-view{grid-template-columns:clamp(300px,34%,400px) minmax(0,1fr)!important;color:var(--cv-text);background:var(--cv-app)}
html body .wa-conversation-view .conv-list{background:var(--cv-panel)!important;border-right:1px solid var(--cv-line)!important;min-height:0}
html body .wa-conversation-view .list-head{background:var(--cv-panel)!important;padding:10px 12px!important;border-color:var(--cv-line)!important}
html body .wa-conversation-view .wa-list-top{height:49px}.wa-conversation-view .wa-list-brand strong{font-size:20px!important;color:var(--cv-text)!important}
html body .wa-conversation-view .whatsapp-search{background:var(--cv-field)!important;border:0!important;border-radius:8px!important;min-height:35px;color:var(--cv-muted)!important}
html body .wa-conversation-view .whatsapp-search input{background:transparent!important;color:var(--cv-text)!important;border:0!important}
html body .wa-conversation-view .wa-filter{background:var(--cv-field)!important;color:var(--cv-muted)!important;border:0!important;border-radius:18px!important;padding:5px 13px!important;font-weight:400!important}
html body .wa-conversation-view .wa-filter.active{background:#00a88420!important;color:#00a884!important}
html body .wa-conversation-view .conv-item{display:grid!important;grid-template-columns:49px minmax(0,1fr) auto!important;align-items:center!important;gap:13px!important;min-height:76px!important;padding:10px 15px!important;border-bottom:1px solid var(--cv-line)!important;border-radius:0!important;background:transparent!important;box-shadow:none!important}
html body .wa-conversation-view .conv-item:hover,html body .wa-conversation-view .conv-item.active{background:var(--cv-select)!important}
html body .wa-conversation-view .conv-item .avatar{width:49px!important;height:49px!important;border-radius:50%!important;flex:none}
html body .wa-conversation-view .conv-item>div{min-width:0}.wa-conversation-view .conv-title strong{font-size:16px!important;font-weight:400!important;color:var(--cv-text)!important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html body .wa-conversation-view .conv-preview{font-size:14px!important;color:var(--cv-muted)!important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block!important}
html body .wa-conversation-view .conv-title small{font-size:12px!important;color:var(--cv-muted)!important;flex:none}.wa-conversation-view .tags{gap:4px!important;margin-top:3px!important}.wa-conversation-view .commercial-stage-pill{padding:0 6px!important;border-radius:4px!important;font-size:11px!important;font-weight:400!important;line-height:16px!important;margin:0!important}
html body .wa-conversation-view .chat,html body .wa-conversation-view .commercial-chat-main{background:var(--cv-app)!important;min-width:0}
html body .wa-conversation-view .chat-head,html body .wa-conversation-view .commercial-chat-head{background:var(--cv-head)!important;border-bottom:1px solid var(--cv-line)!important;padding:10px 16px!important;min-height:59px!important;color:var(--cv-text)!important;gap:13px!important}
.wa-conversation-view .chat-head strong,.wa-conversation-view .commercial-chat-head h3{font-size:16px!important;font-weight:500!important;margin:0!important}.wa-conversation-view .chat-head .muted,.wa-conversation-view .commercial-chat-head .muted{font-size:13px;color:var(--cv-muted)!important}
html body .wa-conversation-view .chat-body,html body .wa-conversation-view .cchat-messages{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:2px!important;padding:18px 7% 12px!important;overflow-y:auto!important;min-height:0!important;background-color:var(--cv-app)!important;background-image:radial-gradient(#80808014 1.2px,transparent 1.3px),radial-gradient(#8080800c 1px,transparent 1.2px)!important;background-size:34px 34px!important;background-position:0 0,17px 17px!important}
html body .wa-conversation-view .bubble,html body .wa-conversation-view .cmsg{flex:none!important;max-width:65%!important;min-width:0!important;width:fit-content!important;padding:6px 8px 7px 9px!important;border-radius:8px!important;font-size:14.2px!important;line-height:19px!important;box-shadow:0 1px .5px #0003!important;margin-top:2px!important;color:var(--cv-text)!important}
html body .wa-conversation-view .bubble.in,html body .wa-conversation-view .cmsg.in{align-self:flex-start!important;margin-right:auto!important;background:var(--cv-in)!important;border-top-left-radius:0!important}
html body .wa-conversation-view .bubble.out,html body .wa-conversation-view .cmsg.out{align-self:flex-end!important;margin-left:auto!important;background:var(--cv-out)!important;border-top-right-radius:0!important}
html body .wa-conversation-view .bubble.internal,html body .wa-conversation-view .cmsg.internal{align-self:center!important;background:#fff3c4!important;color:#3b3423!important}
html body .wa-conversation-view .bubble small,html body .wa-conversation-view .cmsg small{display:flex!important;align-items:center;justify-content:flex-end;gap:3px;font-size:11px!important;color:var(--cv-muted)!important;opacity:1!important;margin:6px 0 0!important;padding:0!important}
html body .wa-conversation-view .cmsg.out small,html body .wa-conversation-view .bubble.out small{color:var(--cv-muted)!important}
html body .wa-conversation-view .cmsg p{line-height:19px!important}.wa-chat-day{align-self:center;background:var(--cv-head,#182229);color:var(--cv-muted,#8696a0);font-size:12.5px;padding:5px 12px;border-radius:8px;margin:8px 0 10px;box-shadow:0 1px .5px #0003;flex:none}
html body .wa-conversation-view .commercial-crm-panel{background:var(--cv-panel)!important;border-color:var(--cv-line)!important;color:var(--cv-text)!important}
html body .wa-conversation-view .commercial-client-card{flex-direction:column;text-align:center;padding:24px 16px 16px!important;gap:6px;border-bottom:8px solid var(--cv-app)}
html body .wa-conversation-view .commercial-client-avatar{width:120px!important;height:120px!important;font-size:42px!important;flex:none}.wa-conversation-view .commercial-client-card strong{font-size:20px!important;font-weight:400!important}.wa-conversation-view .commercial-client-card span{font-size:15px!important;color:var(--cv-muted)!important}
.wa-status-reply{display:flex;gap:10px;align-items:stretch;border-left:4px solid #53bdeb;border-radius:6px;background:var(--cv-quote,#0002);padding:7px 8px;margin:0 16px 6px 0;min-width:180px;max-width:100%;overflow:hidden}
.wa-status-reference{flex:1;min-width:0;display:flex;flex-direction:column;gap:5px}.wa-status-reference strong{font-size:13px;color:var(--cv-blue,#53bdeb);font-weight:600}.wa-status-reference span{font-size:13.5px;line-height:19px;white-space:pre-wrap;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere}
.wa-status-reply img,.wa-status-reply video{width:64px!important;height:72px!important;min-width:64px;object-fit:cover;border-radius:3px;margin:0!important;align-self:center}
@media(max-width:1180px){html body .wa-conversation-view .commercial-crm-shell{position:relative;grid-template-columns:minmax(0,1fr)!important}html body .wa-conversation-view .commercial-crm-panel{position:absolute;right:0;top:0;bottom:0;width:min(330px,100%);z-index:20;box-shadow:-8px 0 24px #0008}}
@media(max-width:760px){html body .wa-conversation-view{grid-template-columns:minmax(0,1fr)!important}.wa-conversation-view:not(.chat-open)>.chat{display:none!important}.wa-conversation-view.chat-open>.conv-list{display:none!important}.wa-conversation-view.chat-open>.chat{display:flex!important}html body .wa-conversation-view .bubble,html body .wa-conversation-view .cmsg{max-width:86%!important}html body .wa-conversation-view .cchat-messages,html body .wa-conversation-view .chat-body{padding:12px 4%!important}.wa-status-reply{min-width:0}.wa-conversation-view .commercial-chat-actions{flex-wrap:wrap!important;gap:4px!important}}
/* Compositor compacto da referência de conversas, com envio à direita. */
html body .wa-conversation-view .wa-unified-composer{display:flex!important;align-items:flex-end!important;gap:8px!important;padding:10px 16px!important;background:var(--cv-head)!important;border:0!important}
.wa-conversation-view .wa-message-box{flex:1;min-width:0;border-radius:22px;padding:0 6px;background:var(--cv-field);border-color:transparent}
html[data-theme="dark"] .wa-conversation-view .wa-message-box{background:#2a3942;border-color:transparent}
html body .wa-conversation-view .wa-message-box textarea{padding:11px 8px!important;line-height:20px!important;max-height:130px!important}
.wa-conversation-view .wa-composer-hint{display:none}
html body .wa-conversation-view .wa-unified-composer>#audioBtn,html body .wa-conversation-view .wa-unified-composer>#cAudio,html body .wa-conversation-view .wa-unified-composer>#sendBtn,html body .wa-conversation-view .wa-unified-composer>#cChatSend{width:44px!important;height:44px!important;min-width:44px!important;display:flex;align-items:center;justify-content:center;border-radius:50%!important;border:0!important;padding:0!important}
html body .wa-conversation-view .wa-unified-composer>#sendBtn,html body .wa-conversation-view .wa-unified-composer>#cChatSend{background:#00a884!important;color:#0b141a!important}
html body .wa-conversation-view .wa-unified-composer>#audioBtn,html body .wa-conversation-view .wa-unified-composer>#cAudio{background:transparent!important;color:var(--cv-muted)!important}
html body .wa-conversation-view .wa-unified-composer[data-has-text="false"]>#sendBtn,html body .wa-conversation-view .wa-unified-composer[data-has-text="false"]>#cChatSend{display:none!important}
html body .wa-conversation-view .wa-unified-composer[data-has-text="true"]>#audioBtn,html body .wa-conversation-view .wa-unified-composer[data-has-text="true"]>#cAudio{display:none!important}
html body .wa-conversation-view .wa-unified-composer>#audioBtn.recording,html body .wa-conversation-view .wa-unified-composer>#cAudio.recording{color:#f15c6d!important;background:#f15c6d26!important}
html body .wa-conversation-view .composer-wrap:has(#filePreview:not(:empty)) .wa-unified-composer>#sendBtn,html body .wa-conversation-view .composer-wrap:has(#audioPreview:not(:empty)) .wa-unified-composer>#sendBtn{display:flex!important}
html body .wa-conversation-view .composer-wrap:has(#filePreview:not(:empty)) .wa-unified-composer>#audioBtn,html body .wa-conversation-view .composer-wrap:has(#audioPreview:not(:empty)) .wa-unified-composer>#audioBtn{display:none!important}
/* Lista de conversas conforme a referência de 10/10. */
html[data-theme="dark"] .wa-conversation-view{--cv-panel:#161717;--cv-select:#2c2d2d;--cv-field:#2c2d2d;--cv-line:transparent;--cv-muted:#aebac1}
html body .wa-conversation-view .list-head{padding:12px 12px 16px!important;gap:12px!important}
html body .wa-conversation-view .wa-list-top{height:48px!important;padding:0 6px}
html body .wa-conversation-view .wa-list-brand strong{font-size:25px!important;font-weight:700!important}
html body .wa-conversation-view .wa-new-btn{width:44px!important;height:44px!important;background:#1ac563!important;color:#09271c!important;border:0!important;border-radius:50%!important;font-size:30px!important}
html body .wa-conversation-view .whatsapp-search{border-radius:26px!important;min-height:46px!important;padding:0 16px!important;margin:0 6px!important}
html body .wa-conversation-view .whatsapp-search input{font-size:15px!important}
html body .wa-conversation-view .wa-filter-row{padding:0 6px!important;gap:8px!important;overflow-x:auto;flex-wrap:nowrap!important}
html body .wa-conversation-view .wa-filter{padding:8px 13px!important;border:1px solid #879aa52b!important;background:transparent!important;color:var(--cv-muted)!important;white-space:nowrap;font-size:14px!important}
html body .wa-conversation-view .wa-filter.active{background:#00a88426!important;border-color:#00a88430!important;color:var(--cv-text)!important;font-weight:600!important}
html body .wa-conversation-view .conv-item{margin:3px 6px!important;width:calc(100% - 12px)!important;padding:13px 14px!important;min-height:86px!important;grid-template-columns:54px minmax(0,1fr) auto!important;border:0!important;border-radius:14px!important;gap:14px!important}
html body .wa-conversation-view .conv-item .avatar{width:54px!important;height:54px!important}
html body .wa-conversation-view .conv-title strong{font-size:17px!important;font-weight:500!important}
html body .wa-conversation-view .conv-preview{margin-top:5px!important;font-size:14px!important}
html body .wa-conversation-view .conv-item .badge.unread{display:inline-flex!important;align-items:center;justify-content:center;background:#1ac563!important;color:#06251a!important;border-radius:50%!important;min-width:23px!important;height:23px!important;padding:0 6px!important;font-size:12px!important;font-weight:700!important}
html body .wa-conversation-view .conv-item:has(.badge.unread) .conv-title small{color:#1ac563!important;font-weight:500!important}
/* Cores vinculadas ao tema padrão TeleHub, mantendo o layout da referência. */
html body .wa-conversation-view,html[data-theme="dark"] body .wa-conversation-view{--cv-app:var(--wa-wall-bg);--cv-panel:var(--wa-bg);--cv-head:var(--wa-head);--cv-field:var(--wa-search);--cv-line:var(--wa-line);--cv-text:var(--wa-text);--cv-muted:var(--wa-sub);--cv-in:var(--wa-in);--cv-out:var(--wa-out);--cv-select:var(--wa-sel)}
html body .wa-conversation-view .wa-new-btn,html body .wa-conversation-view .conv-item .badge.unread,html body .wa-conversation-view .wa-unified-composer>#sendBtn,html body .wa-conversation-view .wa-unified-composer>#cChatSend{background:var(--accent)!important;color:#fff!important}
html body .wa-conversation-view .conv-item:has(.badge.unread) .conv-title small{color:var(--accent)!important}
html body .wa-conversation-view .wa-filter{border-color:var(--wa-line)!important;color:var(--wa-sub)!important}
html body .wa-conversation-view .wa-filter.active{background:var(--wa-chip-on)!important;color:var(--wa-chip-on-t)!important;border-color:transparent!important}
html body .wa-conversation-view .wa-message-box{background:var(--wa-input)!important;border-color:var(--wa-line)!important;color:var(--wa-text)!important}
html body .wa-conversation-view .wa-message-box:focus-within{border-color:var(--accent)!important;box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 15%,transparent)!important}
html body .wa-conversation-view .wa-message-box textarea{color:var(--wa-text)!important}
html body .wa-conversation-view .wa-attach-popup{background:var(--wa-bg)!important;color:var(--wa-text)!important;border-color:var(--wa-line)!important}
html body .wa-conversation-view .commercial-crm-panel select,html body .wa-conversation-view .commercial-crm-panel input,html body .wa-conversation-view .commercial-crm-panel textarea{background:var(--wa-search)!important;color:var(--wa-text)!important;border-color:var(--wa-line)!important}


.commercial-store-filter{display:flex;align-items:center;gap:8px;font-size:13px;padding:4px 6px;color:var(--wa-sub)}.commercial-store-filter select{flex:1;min-width:0;background:var(--wa-search);color:var(--wa-text);border:1px solid var(--wa-line);border-radius:8px;padding:8px}
/* Collaboration and manager overview */
html body .conv-item,html body .conv-item::after,html body .commercial-adm-conv-body{border-bottom:0!important;box-shadow:none!important}
html body .conv-item::after{display:none!important}
.color-hot{--conversation-color:#f07832}.color-negotiation{--conversation-color:#d3ab22}.color-return{--conversation-color:#438bc7}.color-proposal{--conversation-color:#a076d8}.color-sale{--conversation-color:#00a884}.color-lost{--conversation-color:#e86c71}
html body .commercial-adm-conv[class*="color-"]{background:color-mix(in srgb,var(--conversation-color) 12%,var(--panel))!important}
html body .commercial-adm-conv[class*="color-"].active,html body .commercial-adm-conv[class*="color-"]:hover{background:color-mix(in srgb,var(--conversation-color) 23%,var(--panel))!important}
html body .commercial-adm-conv .badge[class*="color-"]{background:color-mix(in srgb,var(--conversation-color) 20%,var(--panel));color:var(--text)}
.collaborator-presence,.collaborator-current{display:inline-flex;color:var(--green);align-items:center;justify-content:center;flex:none;padding:3px;opacity:.85}.collaborator-presence[hidden],.collaborator-current[hidden]{display:none}.commercial-list-row-actions{gap:6px}
.manager-overview{margin-bottom:22px}.overview-head{display:flex;justify-content:space-between;gap:16px;align-items:center;margin-bottom:18px}.overview-head h2{margin:0 0 6px}.overview-filters{display:flex;gap:10px;flex-wrap:wrap}.overview-filters label{font-size:12px;min-width:130px}.overview-filters input,.overview-filters select{width:100%;margin-top:5px}.overview-caption{font-size:11px;letter-spacing:1px;color:var(--muted)}.overview-metrics{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin-bottom:16px}.overview-metrics .card{display:flex;flex-direction:column;gap:7px}.overview-metrics strong{font-size:24px}.overview-metrics span{font-size:12px;color:var(--muted)}.overview-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.overview-grid h3{font-size:15px;margin:0 0 14px}.overview-grid p{font-size:12px}.overview-wide{grid-column:1/-1}.overview-bars{display:grid;gap:12px;margin:18px 0}.overview-bar-row{display:grid;grid-template-columns:115px minmax(30px,1fr) 28px;gap:8px;align-items:center;font-size:12px}.overview-bar-row>div{background:var(--soft);border-radius:6px;height:12px;overflow:hidden}.overview-bar-row i{display:block;height:100%;border-radius:6px}.overview-donut{height:172px;width:172px;border-radius:50%;display:grid;place-items:center;margin:20px auto}.overview-donut>span{display:flex;flex-direction:column;justify-content:center;align-items:center;width:125px;height:125px;background:var(--panel);border-radius:50%;font-size:27px;font-weight:700}.overview-donut small{font-size:12px;color:var(--muted);font-weight:400}.overview-legend{display:flex;flex-wrap:wrap;justify-content:center;gap:9px;font-size:11px}.overview-task-numbers{display:flex;gap:20px;padding:16px 0}.overview-task-numbers>div{display:flex;flex-direction:column;gap:6px}.overview-task-numbers b{font-size:28px}.overview-task-numbers>div:last-child b{color:#e86c71}.overview-task-numbers span{font-size:12px;color:var(--muted)}.overview-trend{width:100%;max-height:270px}
@media(max-width:1100px){.overview-grid{grid-template-columns:1fr 1fr}.overview-grid>article:nth-child(3){grid-column:1/-1}.overview-head{align-items:flex-start;flex-direction:column}}@media(max-width:650px){.overview-metrics{grid-template-columns:1fr 1fr}.overview-grid{grid-template-columns:1fr}.overview-grid>article{grid-column:auto}.overview-filters{width:100%}.overview-filters label{flex:1}}

/* Calendário de agendamentos */
.calendar-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:18px 0}.calendar-toolbar h3{text-transform:capitalize;margin:0}.calendar-scroll{overflow-x:auto}.calendar-week,.calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(120px,1fr));min-width:840px}.calendar-week strong{padding:12px;text-align:center}.calendar-day{min-height:130px;padding:8px;border:1px solid var(--line,#8883);min-width:0}.calendar-day.outside{background:#8881}.calendar-day.outside .calendar-date{opacity:.45}.calendar-date{font-weight:700;margin:0 0 8px}.calendar-day.today .calendar-date{color:#168ed0}.calendar-event{display:block;width:100%;text-align:left;padding:8px;margin:5px 0;border-radius:7px;border:1px solid #8884;background:#168ed018;color:inherit;cursor:pointer}.calendar-event strong,.calendar-event span{display:block;overflow-wrap:anywhere}.calendar-event span{font-size:11px;margin-top:4px}.calendar-event.assigned{background:#16a34a20;border-color:#16a34a66}.calendar-event.danger{background:#ef444420}.calendar-event.closed{opacity:.65}.calendar-event:hover{outline:2px solid #168ed0}.calendar-toolbar .actions{margin:0}

/* TeleHub 3.0.24: contraste do calendário e paleta clara */
html:not([data-theme="dark"]){--accent:#25d366;--accent2:#075e54;--th-accent:#128c7e;--bar:#075e54;--bar-dark:#075e54;--grad:linear-gradient(135deg,#25d366,#25d366);--bubble-out:#dcf8c6;--chat-bg:#ece5dd;--wa-out:#dcf8c6;--wa-wall-bg:#ece5dd;--wa-chip-on:#dcf8c6;--wa-chip-on-t:#075e54;--cv-blue:#34b7f1;--wa-wall:url('/assets/chat-bg-light.svg')!important}
html[data-theme="dark"]{--wa-wall:url('/assets/chat-bg-dark.svg')!important}
html:not([data-theme="dark"]) body .wa-conversation-view{--cv-out:#dcf8c6;--cv-blue:#34b7f1}
html:not([data-theme="dark"]) body main>header{background:#075e54!important;color:#fff!important}
html:not([data-theme="dark"]) body button.primary,html:not([data-theme="dark"]) body .wa-conversation-view .wa-new-btn,html:not([data-theme="dark"]) body .wa-conversation-view .wa-unified-composer>#sendBtn,html:not([data-theme="dark"]) body .wa-conversation-view .wa-unified-composer>#cChatSend{background:#25d366!important;color:#073b25!important}
html:not([data-theme="dark"]) body .bubble.out,html:not([data-theme="dark"]) body .cmsg.out{background:#dcf8c6!important;color:#111b21!important}
html:not([data-theme="dark"]) body .msg-text a,html:not([data-theme="dark"]) body .cmsg a,html:not([data-theme="dark"]) body .bubble a{color:#075e54;text-decoration:underline;text-decoration-color:#34b7f1}
html:not([data-theme="dark"]) body .badge.unread{background:#34b7f1!important;color:#073349!important}
html body .wa-conversation-view .chat-body,html body .wa-conversation-view .cchat-messages,html body .chat-body,html body .cchat-messages{background-color:var(--wa-wall-bg)!important;background-image:var(--wa-wall)!important;background-size:480px 480px!important;background-position:0 0!important;background-repeat:repeat!important}
html body .schedule-calendar .calendar-toolbar button{background:var(--panel2)!important;color:var(--text)!important;border:1px solid var(--line2)!important}
html body .schedule-calendar .calendar-toolbar button:hover{background:var(--panel3)!important}
html body .schedule-calendar .calendar-event{height:auto!important;min-height:58px;white-space:normal;color:var(--text)!important;background:var(--panel2)!important;border:1px solid var(--line2)!important}
html body .schedule-calendar .calendar-event.waiting{background:color-mix(in srgb,#34b7f1 14%,var(--panel))!important;border-color:#34b7f1!important}
html body .schedule-calendar .calendar-event.assigned{background:color-mix(in srgb,#25d366 14%,var(--panel))!important;border-color:#128c7e!important}
html body .schedule-calendar .calendar-event.danger{background:color-mix(in srgb,#ef4444 14%,var(--panel))!important;border-color:#ef4444!important}
html body .schedule-calendar .calendar-event.closed{opacity:1;background:var(--panel3)!important}
html[data-theme="dark"] body .schedule-calendar .calendar-toolbar button{background:#202c33!important;color:#e9edef!important;border-color:#52616b!important}
html[data-theme="dark"] body .schedule-calendar .calendar-event{color:#e9edef!important}
html body .schedule-calendar button:focus-visible{outline:2px solid #34b7f1;outline-offset:2px}

/* Logo animada: uma reprodução por entrada na tela vazia */
.telehub-logo-animation .sq{transform-origin:250px 250px;animation:thlogo-pop .8s cubic-bezier(.34,1.5,.64,1) 0s both}
.telehub-logo-animation .ring{stroke-dasharray:100;stroke-dashoffset:0;animation:thlogo-draw 1.1s ease-in-out .5s both}
.telehub-logo-animation .bub{transform-origin:250px 260px;animation:thlogo-pop .7s cubic-bezier(.34,1.5,.64,1) 1s both}
.telehub-logo-animation .tee{transform-origin:250px 235px;animation:thlogo-pop .6s cubic-bezier(.34,1.7,.64,1) 1.5s both}
.telehub-logo-animation .orbit{transform-origin:250px 250px;animation:thlogo-orbit 2.2s cubic-bezier(.45,0,.2,1) 1.7s both}
.telehub-logo-animation .shine{animation:thlogo-shine .9s ease-in-out 3.9s both}
.telehub-logo-animation .tl{animation:thlogo-rise .8s cubic-bezier(.2,.8,.2,1) var(--d) both}
.telehub-logo-animation .tg{animation:thlogo-rise2 .7s cubic-bezier(.2,.8,.2,1) var(--d) both}
@keyframes thlogo-pop{from{transform:scale(0);opacity:0}to{transform:scale(1);opacity:1}}
@keyframes thlogo-draw{from{stroke-dashoffset:100}to{stroke-dashoffset:0}}
@keyframes thlogo-orbit{0%{transform:rotate(-360deg);opacity:0}8%{opacity:1}100%{transform:rotate(0);opacity:1}}
@keyframes thlogo-shine{from{transform:translateX(0) skewX(-20deg)}to{transform:translateX(640px) skewX(-20deg)}}
@keyframes thlogo-rise{from{opacity:0;transform:translateY(60px)}to{opacity:1;transform:none}}
@keyframes thlogo-rise2{from{opacity:0;transform:translateY(24px)}to{opacity:1;transform:none}}
@media (prefers-reduced-motion:reduce){.telehub-logo-animation .sq,.telehub-logo-animation .ring,.telehub-logo-animation .bub,.telehub-logo-animation .tee,.telehub-logo-animation .orbit,.telehub-logo-animation .shine,.telehub-logo-animation .tl,.telehub-logo-animation .tg{animation:none!important}}

.telehub-logo-animation{width:min(100%,440px);margin:0 auto 12px}.telehub-logo-animation svg{display:block;width:100%;height:auto;overflow:visible}html:not([data-theme="dark"]) .telehub-logo-animation .tl{fill:#075e54}html:not([data-theme="dark"]) .telehub-logo-animation .tg{fill:#52666c}

.conversation-list-empty{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;padding:32px 16px;min-height:260px;width:100%;box-sizing:border-box;text-align:center}
.conversation-list-empty img{width:100%;max-width:360px;height:auto;display:block}
.conversation-list-empty .empty-art-dark{display:none}
html[data-theme="dark"] .conversation-list-empty .empty-art-light{display:none}
html[data-theme="dark"] .conversation-list-empty .empty-art-dark{display:block}
.conversation-list-empty .empty-back-conversations{background:transparent;border:0;color:#128c4a;padding:10px 14px;min-height:44px;font:inherit;font-weight:600;cursor:pointer;box-shadow:none}
html[data-theme="dark"] .conversation-list-empty .empty-back-conversations{color:#25d366;background:transparent}
.conversation-list-empty .empty-back-conversations:hover{text-decoration:underline}
.conversation-list-empty .empty-back-conversations:focus-visible{outline:2px solid currentColor;outline-offset:2px;border-radius:6px}

/* Search focus belongs to the complete field, including both icons. */
html body .wa-conversation-view .wa-list-head .search-box.whatsapp-search{
 box-sizing:border-box!important;width:calc(100% - 12px)!important;
 padding:0!important;min-height:46px!important;border-radius:26px!important;
}
html body .wa-conversation-view .wa-list-head .search-box.whatsapp-search:focus-within{
 outline:2px solid #128c7e!important;outline-offset:0!important;
}
html[data-theme="dark"] body .wa-conversation-view .wa-list-head .search-box.whatsapp-search:focus-within{outline-color:#25d366!important}
html body .wa-conversation-view .wa-list-head .search-box.whatsapp-search input,
html body .wa-conversation-view .wa-list-head .search-box.whatsapp-search:focus-within input{
 width:100%!important;height:46px!important;box-sizing:border-box!important;
 padding:0 46px 0 46px!important;border:0!important;border-radius:26px!important;
 outline:none!important;box-shadow:none!important;background:transparent!important;
}
/* Keep only the existing TeleHub clear button, not the browser's second X. */
#convSearch::-webkit-search-cancel-button,
#commercialConvSearch::-webkit-search-cancel-button,
#convSearch::-webkit-search-decoration,
#commercialConvSearch::-webkit-search-decoration{-webkit-appearance:none;appearance:none;display:none}
#convSearch::-ms-clear,#commercialConvSearch::-ms-clear{display:none;width:0;height:0}
html body .wa-conversation-view .whatsapp-search .search-clear{right:8px!important;width:32px;height:32px}
html body .wa-conversation-view .whatsapp-search .search-clear:focus-visible{outline:2px solid #128c7e;outline-offset:0}

/* Highlight the complete message field, never just the inner textarea. */
html body .wa-conversation-view .wa-message-box:focus-within{outline:2px solid #128c7e!important;outline-offset:0!important;box-shadow:none!important}
html[data-theme="dark"] body .wa-conversation-view .wa-message-box:focus-within{outline-color:#25d366!important}
html body .wa-conversation-view .wa-message-box #msgText,
html body .wa-conversation-view .wa-message-box #cChatInput,
html body .wa-conversation-view .wa-message-box textarea:focus{outline:none!important;box-shadow:none!important;border:0!important;background:transparent!important;min-width:0}
.local-sending{opacity:.75;white-space:pre-wrap;overflow-wrap:anywhere}
.local-sending small{display:block;font-size:11px;text-align:right}

/* Supplied media icons and compact voice preview, keeping duration visible. */
html body .conv-preview:has(.media-list-preview){display:flex;align-items:center;gap:4px;min-width:0}
html body .media-list-preview{display:inline-flex;align-items:center;gap:5px;max-width:100%;min-width:0;vertical-align:middle}
html body .media-list-preview>img{width:17px;height:17px;flex:0 0 17px;object-fit:contain}
html body .conv-preview .voice-list-preview,html body .commercial-kanban-card .voice-list-preview{font-size:12px!important;line-height:18px;letter-spacing:0;white-space:nowrap}
html body .voice-list-preview>span:not(.voice-list-duration){overflow:hidden;text-overflow:ellipsis;min-width:0}
html body .voice-list-preview .voice-list-duration{flex-shrink:0;font-variant-numeric:tabular-nums}


/* Foto acima da legenda, no padrão do WhatsApp Web */
.bubble.has-media-first .msg-text,
.cmsg.has-media-first p{display:block!important;padding-right:0!important;margin-top:0!important}
.bubble.has-media-first .chat-image-link,
.cmsg.has-media-first .chat-image-link,
.bubble.has-media-first .media-block,
.cmsg.has-media-first .media-block{display:block;width:100%}
.bubble.has-media-first .chat-image-link img,
.cmsg.has-media-first .chat-image-link img{margin-top:0!important}
.bubble.has-media-first .file-link,
.cmsg.has-media-first .file-link{margin-top:0!important}
.bubble.local-sending .chat-image-link,
.cmsg.local-sending .chat-image-link{display:block}



/* WhatsApp Web refinement */
.wa-conversation-view .chat-body,.wa-conversation-view .cchat-messages{display:flex;flex-direction:column;gap:2px}
html body .wa-conversation-view .bubble,html body .wa-conversation-view .cmsg{max-width:min(66%,640px)!important;border-radius:7.5px!important;padding:6px 7px 5px 8px!important;line-height:19px!important;box-shadow:0 1px .45px rgba(11,20,26,.18)!important;margin:1px 0!important}
html body .wa-conversation-view .bubble.in,html body .wa-conversation-view .cmsg.in{border-top-left-radius:0!important}
html body .wa-conversation-view .bubble.out,html body .wa-conversation-view .cmsg.out{border-top-right-radius:0!important}
html body .wa-conversation-view .bubble small,html body .wa-conversation-view .cmsg small{font-size:11px!important;line-height:14px!important;opacity:.92!important;margin:4px 0 0!important}
html body .wa-conversation-view .bubble .msg-text,html body .wa-conversation-view .cmsg p{margin:0;padding-right:0!important}
html body .wa-conversation-view .reply-preview{border-left:3px solid #53bdeb;background:rgba(0,0,0,.06);border-radius:7px;padding:6px 8px;margin-bottom:6px}
html[data-theme="dark"] body .wa-conversation-view .reply-preview{background:rgba(255,255,255,.08)}
.chat-image-link img{box-shadow:0 1px .5px rgba(0,0,0,.18)}
.video-card,.audio-card,.file-card{border-radius:12px;overflow:hidden}
.video-card video{display:block;max-width:min(320px,100%);border-radius:12px;background:#000}
.media-card-meta{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 2px 0;font-size:12px;color:var(--muted)}
.media-card-meta strong{font-size:12.5px;color:inherit}
.audio-card{display:flex;flex-direction:column;gap:8px;min-width:250px;padding:8px 10px;border-radius:12px;background:rgba(0,0,0,.05)}
html[data-theme="dark"] .audio-card{background:rgba(255,255,255,.06)}
.audio-card-head{display:flex;align-items:center;justify-content:space-between;gap:10px}
.audio-pill{display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:600}
.audio-pill .i{width:14px;height:14px}
.audio-duration{font-size:12px;color:var(--muted)}
.chat-audio audio{width:min(320px,100%);height:36px}
.file-card{display:flex!important;align-items:center;gap:10px;text-decoration:none;color:inherit;padding:10px 12px;background:rgba(0,0,0,.05);border:1px solid var(--border)}
html[data-theme="dark"] .file-card{background:rgba(255,255,255,.06)}
.file-card-icon{display:grid;place-items:center;width:42px;height:42px;border-radius:10px;background:#25d3661c;color:#128c7e;font-weight:700;font-size:12px;flex:none}
.file-card-meta{display:flex;flex-direction:column;min-width:0;flex:1}
.file-card-meta strong,.file-card-meta small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.file-card-meta small{color:var(--muted)}
.file-card-open{font-size:12px;font-weight:600;color:#34b7f1;flex:none}
.commercial-conversation-filters{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}
.commercial-conversation-filters .commercial-store-filter{margin:0}
.seller-badge{background:rgba(52,183,241,.12)!important;color:#34b7f1!important}
@media(max-width:760px){html body .wa-conversation-view .bubble,html body .wa-conversation-view .cmsg{max-width:88%!important}.commercial-conversation-filters{flex-direction:column}}

.campaign-distribution{padding:14px;border:1px solid var(--border);border-radius:12px;display:grid;gap:10px;margin:12px 0}.campaign-sellers{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:8px;max-height:200px;overflow:auto}.campaign-sellers label{display:flex;align-items:center;gap:8px;padding:8px;border:1px solid var(--border);border-radius:8px}.campaign-sellers input{width:auto;flex:none}

/* Search saved contacts after conversation results */
#commercialContactSearchResults{border-top:1px solid var(--border);padding:4px 8px 12px;max-height:42vh;overflow-y:auto}
#commercialContactSearchResults[hidden]{display:none!important}
.commercial-search-header{font-size:12px;font-weight:700;color:var(--muted);padding:10px 10px 6px}
.commercial-search-contact{display:flex;align-items:center;gap:10px;width:100%;border:0;border-radius:9px;padding:10px 8px;background:transparent;color:var(--text);text-align:left;cursor:pointer}
.commercial-search-contact:hover{background:var(--soft)}
.commercial-search-contact>span:nth-child(2){display:flex;flex-direction:column;gap:3px;min-width:0;flex:1}
.commercial-search-contact small{color:var(--muted);font-size:12px}
.commercial-search-open{color:var(--accent);font-size:12px;white-space:nowrap}

/* Navegação segmentada para administradores */
.admin-mode-holder{padding:8px 12px 10px}.admin-mode-control{display:flex;gap:4px;padding:4px;background:var(--soft,#263238);border:1px solid var(--border,#354249);border-radius:999px}.admin-mode-control button{flex:1;border:0;border-radius:999px;background:transparent;color:var(--muted);padding:10px 8px;font-size:12px;font-weight:700;cursor:pointer}.admin-mode-control button.active{background:#128c7e;color:white;box-shadow:0 2px 8px #0002}.mode-hidden{display:none!important}
