/* IYES CHAT R20-UX-R2 — estrutura unificada, chat-first.
   Atendente, ISP e Master: mesmos tokens, cards, conversas e responsividade.
   Complementa R1C e não substitui controles do sistema. */
body.iyes-r2-active{
 --r2-surface:var(--ux-card,#fff);
 --r2-canvas:var(--ux-bg,#f2f6fc);
 --r2-tint:var(--ux-soft,#f5f8fe);
 --r2-border:var(--ux-line,#dfE8f4);
 --r2-fg:var(--ux-text,#14213b);
 --r2-muted:var(--ux-muted,#66758b);
 --r2-blue:var(--ux-primary,#176af2);
 --r2-shadow:0 4px 22px rgba(26,70,133,.048);
}
body.iyes-r2-active.iyes-ux-active{background:var(--r2-canvas)!important}
body.iyes-r2-active .iyes-r2-workspace{
 gap:10px!important;align-items:stretch!important;max-width:100%;min-height:0!important;
}
/* Em todas as centrais, o chat é a coluna prioritária. */
@media(min-width:1280px){
 body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace{
  display:grid!important;grid-template-columns:minmax(290px,315px) minmax(0,1fr) minmax(266px,300px)!important;
 }
 body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace{
  display:grid!important;grid-template-columns:minmax(290px,315px) minmax(0,1fr) minmax(266px,300px)!important;
 }
}
@media(min-width:1650px){
 body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace{
  grid-template-columns:minmax(330px,370px) minmax(0,1fr) minmax(300px,340px)!important;
 }
}
/* Sidebar real: estrutura com indicador, filtros, busca, canais, lista. */
body.iyes-r2-active .iyes-r2-sidebar{
 border:1px solid var(--r2-border)!important;border-radius:15px!important;
 padding:10px!important;gap:7px!important;min-width:0!important;min-height:0!important;
 background:var(--r2-surface)!important;box-shadow:var(--r2-shadow)!important;
}
body.iyes-r2-active .iyes-ux-sidebar-head{min-height:28px!important;padding:0 3px!important;gap:6px!important}
body.iyes-r2-active .iyes-ux-sidebar-head>strong{font-weight:780!important;font-size:14px!important;letter-spacing:-.01em}
body.iyes-r2-active .iyes-ux-sidebar-actions button{min-height:29px!important;padding:5px 8px!important;font-size:11px!important}
body.iyes-r2-active .operator-kpis.iyes-r2-queue-overview{
 display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;
 gap:7px!important;padding:0!important;margin:0!important;
}
body.iyes-r2-active .operator-kpi{
 min-width:0!important;min-height:64px!important;display:flex!important;
 padding:9px 10px!important;gap:3px!important;border-radius:11px!important;
 background:var(--r2-tint)!important;border:1px solid var(--r2-border)!important;
 box-shadow:none!important;align-items:flex-start!important;justify-content:center!important;
}
body.iyes-r2-active .operator-kpi span{font-size:10px!important;font-weight:550!important;color:var(--r2-muted)!important}
body.iyes-r2-active .operator-kpi strong{font-size:19px!important;font-weight:800!important;color:var(--r2-fg)!important}
body.iyes-r2-active .operator-kpi.active{border-color:rgba(23,106,242,.48)!important;background:rgba(23,106,242,.075)!important}
body.iyes-r2-active .operator-queue-tabs{display:flex!important;flex-wrap:nowrap!important;
 gap:4px!important;margin:0!important;padding:0 0 5px!important;overflow-x:auto!important}
body.iyes-r2-active .operator-queue-tabs button{
 border-radius:9px!important;font-size:11px!important;min-height:30px!important;
 padding:5px 8px!important;box-shadow:none!important;
}
body.iyes-r2-active .operator-queue-tabs .active{background:var(--r2-blue)!important;color:#fff!important}
body.iyes-r2-active .inbox-search.iyes-r2-search-area{
 display:flex!important;flex-direction:column!important;gap:5px!important;margin:0!important;
 padding:7px 0!important;border-top:1px solid var(--r2-border)!important;
}
body.iyes-r2-active .inbox-search input,
body.iyes-r2-active .saas-search-v343 input{
 font-size:12.5px!important;min-height:40px!important;border-radius:10px!important;
 padding:8px 12px!important;border:1px solid var(--r2-border)!important;
 background:var(--r2-tint)!important;color:var(--r2-fg)!important;
}
body.iyes-r2-active .inbox-search:has(.v353-channelbar)>.v353-channelbar{
 display:flex!important;align-items:center!important;flex-wrap:wrap!important;gap:6px!important;
 width:100%!important;min-height:40px!important;margin:3px 0 0!important;padding-top:18px!important;
 position:relative!important;border-top:1px solid var(--r2-border)!important;
}
body.iyes-r2-active .v353-channelbar::before{
 content:'Canais';position:absolute;top:1px;left:2px;color:var(--r2-fg);
 font-size:11px;font-weight:800;line-height:16px;
}
body.iyes-r2-active .v353-channel-chip{font-size:10px!important;line-height:1.2!important;
 padding:6px 9px!important;border-radius:999px!important;min-height:28px!important;
 max-width:100%;white-space:normal!important;text-align:left!important}
body.iyes-r2-active .iyes-r2-list-title{
 display:flex;align-items:center;justify-content:space-between;gap:8px;
 padding:6px 3px 4px;border-top:1px solid var(--r2-border);flex:0 0 auto;
}
body.iyes-r2-active .iyes-r2-list-title strong{font-size:12px!important;color:var(--r2-fg)!important;font-weight:800!important}
body.iyes-r2-active .iyes-r2-list-title .iyes-r2-list-label,
body.iyes-r2-active .iyes-r2-list-title #saas-conv-count{font-size:10px!important;color:var(--r2-muted)!important;font-weight:500!important}
body.iyes-r2-active #conv-count{font-size:10px!important;margin:0 3px!important;color:var(--r2-muted)!important}
body.iyes-r2-active #conv-list,body.iyes-r2-active .saas-conv-list{
 flex:1 1 auto!important;min-height:0!important;overflow-y:auto!important;overflow-x:hidden!important;
 padding:1px!important;display:block!important;scrollbar-width:thin;
}
/* Cartões de conversa verdadeiros: avatar, nome, estado, identificação e horário. */
body.iyes-r2-active #conv-list .conv.iyes-r2-row{
 display:grid!important;grid-template-columns:38px minmax(0,1fr)!important;
 grid-template-areas:'avatar head' 'avatar sub' 'avatar foot'!important;
 column-gap:10px!important;row-gap:3px!important;
 width:100%!important;min-width:0!important;margin:0 0 5px!important;
 padding:10px!important;min-height:79px!important;box-sizing:border-box!important;
 border:1px solid var(--r2-border)!important;border-radius:12px!important;
 background:var(--r2-surface)!important;box-shadow:0 1px 2px rgba(16,42,81,.025)!important;
 color:var(--r2-fg)!important;overflow:hidden!important;position:relative!important;
 transition:background-color .14s ease,border-color .14s ease!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row::before{content:none!important;display:none!important}
body.iyes-r2-active #conv-list .conv.iyes-r2-row:hover{
 border-color:rgba(23,106,242,.34)!important;background:var(--r2-tint)!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row.active{
 border-color:rgba(23,106,242,.4)!important;border-left:4px solid var(--r2-blue)!important;
 background:linear-gradient(90deg,rgba(23,106,242,.1),rgba(23,106,242,.035))!important;
 box-shadow:0 5px 16px rgba(23,106,242,.075)!important;padding-left:7px!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .iyes-r2-contact-avatar{
 grid-area:avatar!important;align-self:start!important;
}
body.iyes-r2-active .iyes-r2-contact-avatar,
body.iyes-r2-active .iyes-r2-tenant-avatar,
body.iyes-r2-active .iyes-r2-head-avatar{
 display:inline-flex!important;justify-content:center!important;align-items:center!important;
 width:38px!important;height:38px!important;flex:0 0 38px!important;
 border-radius:50%!important;font-size:12.5px!important;font-weight:800!important;
 background:#dbeafe;color:#1e40af;
 border:1px solid rgba(255,255,255,.7)!important;box-sizing:border-box!important;
}
body.iyes-r2-active [data-tone='2'].iyes-r2-contact-avatar,
body.iyes-r2-active [data-tone='2'].iyes-r2-tenant-avatar,
body.iyes-r2-active [data-tone='2'].iyes-r2-head-avatar{background:#dcfce7!important;color:#166534!important}
body.iyes-r2-active [data-tone='3'].iyes-r2-contact-avatar,
body.iyes-r2-active [data-tone='3'].iyes-r2-tenant-avatar,
body.iyes-r2-active [data-tone='3'].iyes-r2-head-avatar{background:#fef3c7!important;color:#92400e!important}
body.iyes-r2-active [data-tone='4'].iyes-r2-contact-avatar,
body.iyes-r2-active [data-tone='4'].iyes-r2-tenant-avatar,
body.iyes-r2-active [data-tone='4'].iyes-r2-head-avatar{background:#ede9fe!important;color:#6d28d9!important}
body.iyes-r2-active [data-tone='5'].iyes-r2-contact-avatar,
body.iyes-r2-active [data-tone='5'].iyes-r2-tenant-avatar,
body.iyes-r2-active [data-tone='5'].iyes-r2-head-avatar{background:#cffafe!important;color:#0f766e!important}
body.iyes-r2-active [data-tone='6'].iyes-r2-contact-avatar,
body.iyes-r2-active [data-tone='6'].iyes-r2-tenant-avatar,
body.iyes-r2-active [data-tone='6'].iyes-r2-head-avatar{background:#fce7f3!important;color:#9d174d!important}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-head{
 grid-area:head!important;display:flex!important;gap:5px!important;align-items:flex-start!important;
 justify-content:space-between!important;min-width:0!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-head-main{min-width:0!important;gap:3px!important}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-head-main b{
 font-size:13px!important;line-height:1.2!important;font-weight:790!important;color:var(--r2-fg)!important;
 overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-head-main small{
 color:var(--r2-muted)!important;font-size:10px!important;line-height:1.15!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-subline{
 grid-area:sub!important;margin:0!important;color:var(--r2-muted)!important;
 font-size:11px!important;line-height:1.2!important;overflow:hidden!important;text-overflow:ellipsis!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-foot{
 grid-area:foot!important;margin:0!important;color:var(--r2-muted)!important;
 font-size:10px!important;line-height:1.2!important;overflow:hidden!important;text-overflow:ellipsis!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-row-chips{
 display:flex!important;justify-content:flex-end!important;flex-wrap:wrap!important;
 align-items:center!important;gap:3px!important;max-width:55%!important;min-width:0!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .queue-chip{
 white-space:normal!important;max-width:100%!important;text-align:center!important;
 font-size:9px!important;line-height:1.1!important;padding:4px 6px!important;border-radius:999px!important;
}
/* Centro: cabeçalho estruturado com avatar, dados e botões não gigantes. */
body.iyes-r2-active .iyes-r2-chat-workspace,
body.iyes-r2-active.iyes-ux-master .saas-chat-pane-v343{
 border:1px solid var(--r2-border)!important;background:var(--r2-surface)!important;
 border-radius:15px!important;box-shadow:var(--r2-shadow)!important;min-height:0!important;
}
body.iyes-r2-active .chat-head.iyes-r2-header-structured{
 display:flex!important;flex-direction:column!important;align-items:stretch!important;
 gap:6px!important;min-height:0!important;max-height:164px!important;
 padding:10px 13px!important;overflow-y:auto!important;
 border-bottom:1px solid var(--r2-border)!important;
}
body.iyes-r2-active .iyes-r2-head-identity{
 display:flex!important;align-items:center!important;gap:9px!important;
 min-width:0!important;flex:0 0 auto!important;
}
body.iyes-r2-active .iyes-r2-head-identity .chat-person{flex:1 1 auto!important;min-width:0!important;margin:0!important}
body.iyes-r2-active .iyes-r2-head-identity .chat-person-top{gap:6px!important;align-items:center!important}
body.iyes-r2-active .iyes-r2-head-identity .chat-person-top b{font-size:15px!important;font-weight:800!important}
body.iyes-r2-active .iyes-r2-head-identity .chat-person small{
 color:var(--r2-muted)!important;font-size:10.5px!important;line-height:1.2!important;margin-top:3px!important;
}
body.iyes-r2-active .iyes-r2-head-controls{display:block!important;min-width:0!important}
body.iyes-r2-active .iyes-r2-head-controls .chat-head-actions{
 display:flex!important;justify-content:flex-start!important;align-items:center!important;
 gap:5px!important;flex-wrap:wrap!important;width:100%!important;max-width:none!important;
 padding:0!important;margin:0!important;
}
body.iyes-r2-active .chat-head-actions button,
body.iyes-r2-active .chat-head-actions .small,
body.iyes-r2-active .chat-head-actions .sync-chip,
body.iyes-r2-active .chat-head-actions .bot-live,
body.iyes-r2-active .chat-head-actions .agent-lock{
 display:inline-flex!important;align-items:center!important;justify-content:center!important;
 border-radius:999px!important;min-height:29px!important;max-height:none!important;
 padding:5px 10px!important;margin:0!important;line-height:1.15!important;
 font-size:10.5px!important;font-weight:650!important;white-space:normal!important;box-shadow:none!important;
}
body.iyes-r2-active .chat-head-actions button{border:1px solid var(--r2-border)!important;background:var(--r2-tint)!important;color:var(--r2-fg)!important}
body.iyes-r2-active .chat-head-actions #conv-assume{background:var(--r2-blue)!important;color:#fff!important;border-color:transparent!important}
body.iyes-r2-active .chat-head-actions .sync-chip{background:rgba(22,163,74,.10)!important;color:#15803d!important;border:1px solid rgba(22,163,74,.25)!important}
body.iyes-r2-active .chat-head-actions .bot-live{background:rgba(23,106,242,.07)!important;color:#1d4ed8!important;border:1px solid rgba(23,106,242,.18)!important}
body.iyes-r2-active .chat-head-actions .agent-lock{color:var(--r2-muted)!important;border:1px solid var(--r2-border)!important}
body.iyes-r2-active .chat-head-actions #conv-close.danger{background:rgba(239,68,68,.07)!important;color:#b91c1c!important;border:1px solid rgba(239,68,68,.22)!important}
body.iyes-r2-active .chat-head-actions #conv-close.ok{background:rgba(22,163,74,.08)!important;color:#166534!important;border:1px solid rgba(22,163,74,.2)!important}
body.iyes-r2-active .chat-head .iyes-ux-details-button{margin-left:auto!important;min-height:29px!important;font-size:10px!important}
/* Mensagens e composer: preserva o componente vivo e mantém a timeline máxima. */
body.iyes-r2-active .chat .messages{
 min-height:0!important;overflow-y:auto!important;
 padding:13px clamp(10px,2vw,25px)!important;
 background:var(--r2-surface)!important;
}
body.iyes-r2-active .chat .bubble{border-radius:13px!important;box-shadow:0 1px 2px rgba(11,37,81,.03)!important}
body.iyes-r2-active .composer-pro.iyes-r2-composer{
 padding:7px 10px 9px!important;background:var(--r2-surface)!important;
 border-top:1px solid var(--r2-border)!important;
 max-height:130px!important;overflow:hidden!important;
}
body.iyes-r2-active .composer-tools{gap:4px!important;padding-bottom:3px!important}
body.iyes-r2-active .composer-tools button,body.iyes-r2-active .composer-tools select{
 min-height:30px!important;height:30px!important;padding:5px 8px!important;
 font-size:10.7px!important;font-weight:620!important;
 border-radius:9px!important;background:var(--r2-tint)!important;
 border:1px solid var(--r2-border)!important;color:var(--r2-fg)!important;
}
body.iyes-r2-active .chat .composer{gap:8px!important}
body.iyes-r2-active #msg-text{border-radius:11px!important;
 background:var(--r2-surface)!important;border:1px solid var(--r2-border)!important;
 font-size:12.5px!important;min-height:46px!important;max-height:70px!important;
}
body.iyes-r2-active #msg-send{border-radius:10px!important;background:var(--r2-blue)!important;
 color:#fff!important;font-weight:800!important;min-width:80px!important;
}
/* Lateral de contexto: cartões leves, painéis roláveis e Copilot preservado. */
body.iyes-r2-active .iyes-r2-context-panel{
 border-radius:15px!important;background:var(--r2-surface)!important;
 border:1px solid var(--r2-border)!important;box-shadow:var(--r2-shadow)!important;
 padding:12px!important;min-height:0!important;min-width:0!important;overflow-y:auto!important;
}
body.iyes-r2-active .iyes-r2-context-panel .customer-side-card,
body.iyes-r2-active .iyes-r2-context-panel .retention-card,
body.iyes-r2-active .iyes-r2-context-panel .iyes-ux-master-detail,
body.iyes-r2-active .iyes-r2-context-panel .iyes-ux-master-tip{
 border:1px solid var(--r2-border)!important;background:var(--r2-tint)!important;
 border-radius:12px!important;padding:10px!important;margin-bottom:9px!important;
 box-shadow:none!important;
}
body.iyes-r2-active .iyes-r2-context-panel .customer-side-actions button{
 padding:7px 8px!important;border-radius:9px!important;min-height:32px!important;
 border:1px solid var(--r2-border)!important;background:var(--r2-tint)!important;font-size:10.5px!important;
}
body.iyes-r2-active .copilot-side-head h3{font-size:16px!important}
/* Master: mesmo formato para lista de tenants e topo da conversa. */
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row{
 display:grid!important;grid-template-columns:38px minmax(0,1fr)!important;
 grid-template-rows:auto auto auto!important;gap:3px 10px!important;
 padding:10px!important;margin-bottom:5px!important;
 border:1px solid var(--r2-border)!important;border-radius:12px!important;
 background:var(--r2-surface)!important;position:relative!important;text-align:left!important;
}
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row::before{content:none!important;display:none!important}
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row .iyes-r2-tenant-avatar{
 grid-column:1;grid-row:1/4;align-self:start;
}
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row b,
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row small{
 grid-column:2;margin:0!important;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row b{font-size:13px!important;font-weight:800!important}
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row small{font-size:10.5px!important;color:var(--r2-muted)!important}
body.iyes-r2-active.iyes-ux-master .saas-conv-list .saas-conv.iyes-r2-row.active{
 border-color:rgba(23,106,242,.43)!important;border-left:4px solid var(--r2-blue)!important;
 background:rgba(23,106,242,.07)!important;padding-left:7px!important;
}
body.iyes-r2-active.iyes-ux-master .saas-chat-head.iyes-r2-master-header{
 display:flex!important;gap:10px!important;align-items:center!important;
 padding:10px 13px!important;margin:0!important;border-bottom:1px solid var(--r2-border)!important;
}
body.iyes-r2-active.iyes-ux-master .saas-chat-head h2{font-size:15px!important}
body.iyes-r2-active.iyes-ux-master .saas-composer-tools,
body.iyes-r2-active.iyes-ux-master .saas-composer{
 background:var(--r2-surface)!important;
}
body.iyes-r2-active.iyes-ux-master .saas-chat-pane-v343 .btn{
 border-radius:9px!important;min-height:31px!important;padding:6px 10px!important;
}
/* Não inventa elementos de interface em painéis que não possuem dados nativos. */
@media(min-width:981px) and (max-width:1279px){
 body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace{
  grid-template-columns:minmax(280px,310px) minmax(0,1fr)!important;
 }
}
@media(max-width:980px){
 body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace{display:block!important}
 body.iyes-r2-active .iyes-r2-sidebar{height:100%!important}
 body.iyes-r2-active .iyes-r2-chat-workspace{height:100%!important}
 body.iyes-r2-active .chat-head.iyes-r2-header-structured{
  max-height:150px!important;padding:9px 11px!important;overflow-y:auto!important;
 }
 body.iyes-r2-active .iyes-r2-head-controls .chat-head-actions{
  flex-wrap:nowrap!important;overflow-x:auto!important;max-width:100%!important;
  scrollbar-width:thin;justify-content:flex-start!important;
 }
 body.iyes-r2-active .chat-head-actions .bot-live,
 body.iyes-r2-active .chat-head-actions .agent-lock{display:none!important}
 body.iyes-r2-active .iyes-r2-head-identity .mobile-conv-back{display:inline-flex!important}
}
@media(max-width:600px){
 body.iyes-r2-active .iyes-r2-sidebar{padding:8px!important}
 body.iyes-r2-active .operator-kpi{min-height:56px!important;padding:7px 8px!important}
 body.iyes-r2-active #conv-list .conv.iyes-r2-row{min-height:74px!important;padding:9px!important}
 body.iyes-r2-active .chat .messages{padding:10px!important}
 body.iyes-r2-active .iyes-r2-head-avatar{width:34px!important;height:34px!important;flex-basis:34px!important}
 body.iyes-r2-active .iyes-r2-head-identity .chat-person-top b{font-size:14px!important}
 body.iyes-r2-active .composer-pro.iyes-r2-composer{padding-bottom:calc(7px + env(safe-area-inset-bottom,0px))!important}
}
@media(max-height:700px) and (min-width:981px){
 body.iyes-r2-active .operator-kpi{min-height:52px!important}
 body.iyes-r2-active .chat-head.iyes-r2-header-structured{max-height:133px!important}
}
@media(prefers-reduced-motion:reduce){
 body.iyes-r2-active #conv-list .conv{transition:none!important}
}



/* R20-UX-R2A — densidade adaptativa; contatos sempre prioritários */
body.iyes-r2-active .iyes-r2-sidebar{gap:4px!important;padding:8px!important;overflow:hidden!important}
body.iyes-r2-active .iyes-r2-sidebar .iyes-ux-sidebar-head{min-height:27px!important;margin:0!important;padding:1px 3px!important}
body.iyes-r2-active .iyes-r2-sidebar .operator-kpis.iyes-r2-queue-overview{
 display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;
 gap:4px!important;margin:0!important;flex:0 0 auto!important;
}
body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi{
 min-width:0!important;min-height:56px!important;max-height:60px!important;
 border-radius:9px!important;padding:5px 2px!important;gap:3px!important;
 display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;text-align:center!important;
}
body.iyes-r2-active .iyes-r2-sidebar .operator-kpi span{
 display:-webkit-box!important;-webkit-box-orient:vertical;-webkit-line-clamp:2;
 font-size:9px!important;line-height:1.08!important;max-width:100%;overflow:hidden;
 text-overflow:ellipsis;white-space:normal!important;text-align:center!important;
}
body.iyes-r2-active .iyes-r2-sidebar .operator-kpi strong{font-size:17px!important;line-height:1!important}
body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs{
 min-height:28px!important;max-height:32px!important;padding:1px 0!important;
 gap:3px!important;flex:0 0 auto!important;overflow-x:auto!important;
}
body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs button{min-height:26px!important;padding:4px 7px!important;font-size:10px!important}
body.iyes-r2-active .iyes-r2-sidebar .inbox-search.iyes-r2-search-area{
 min-height:0!important;padding:4px 0!important;gap:3px!important;border-top:0!important;
 display:flex!important;flex-direction:column!important;flex:0 0 auto!important;
}
body.iyes-r2-active .iyes-r2-sidebar .inbox-search input{
 min-height:34px!important;height:34px!important;font-size:12px!important;padding:6px 10px!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-count{font-size:9px!important;line-height:11px!important;margin:0 4px!important}
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar,
body.iyes-r2-active .iyes-r2-sidebar .inbox-search:has(.v353-channelbar)>.v353-channelbar{
 display:flex!important;flex-wrap:nowrap!important;gap:4px!important;align-items:center!important;
 margin:0!important;padding:2px 0!important;min-height:30px!important;max-height:34px!important;
 border-top:1px solid var(--r2-border)!important;overflow-x:auto!important;overflow-y:hidden!important;
 white-space:nowrap!important;scrollbar-width:thin!important;
}
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar::before{
 content:'Canais';position:static!important;font-size:10px!important;line-height:16px!important;
 flex:0 0 auto!important;margin-right:1px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .v353-channel-chip{
 flex:0 0 auto!important;padding:4px 7px!important;font-size:10px!important;
 min-height:24px!important;white-space:nowrap!important;border-radius:999px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-list-title{
 border-top:1px solid var(--r2-border)!important;padding:4px 3px 3px!important;min-height:24px!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-list{
 flex:1 1 0!important;min-height:0!important;overflow-y:auto!important;scrollbar-width:thin!important;
 padding:0 1px!important;overscroll-behavior:contain!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv.iyes-r2-row{
 min-height:67px!important;margin:0 0 4px!important;padding:8px 7px!important;
 grid-template-columns:34px minmax(0,1fr)!important;gap:2px 8px!important;
 grid-template-areas:'avatar head' 'avatar sub' 'avatar foot'!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv.iyes-r2-row.active{padding-left:5px!important}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-contact-avatar{
 width:34px!important;height:34px!important;flex-basis:34px!important;font-size:12px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .conv-head-main b{font-size:12.5px!important;line-height:1.12!important}
body.iyes-r2-active .iyes-r2-sidebar .conv-head-main small{font-size:10px!important;line-height:1.1!important}
body.iyes-r2-active .iyes-r2-sidebar .conv-subline,
body.iyes-r2-active .iyes-r2-sidebar .conv-foot{font-size:10px!important;line-height:1.12!important;margin-top:1px!important}
body.iyes-r2-active .iyes-r2-sidebar .conv-row-chips{gap:2px!important;max-width:47%!important}
body.iyes-r2-active .iyes-r2-sidebar .conv-row-chips .queue-chip{font-size:9px!important;padding:3px 5px!important;line-height:1.05!important}
/* ISP/Master: menu como gaveta completa, inclusive quando a preferência original é "recolhida" */
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar{
 position:fixed!important;inset:0 auto 0 0!important;z-index:9001!important;
 width:min(328px,90vw)!important;min-width:0!important;max-width:90vw!important;height:100dvh!important;
 display:flex!important;flex-direction:column!important;
 overflow:hidden!important;padding:12px!important;box-sizing:border-box!important;
 border-radius:0 14px 14px 0!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .brand{
 display:flex!important;align-items:center!important;min-height:58px!important;padding-right:42px!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .brand-copy,
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .profile-copy{
 display:block!important;visibility:visible!important;opacity:1!important;width:auto!important;height:auto!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .brand-copy b,
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .brand-copy small{
 display:block!important;white-space:normal!important;font-size:12px!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav{
 display:flex!important;flex:1 1 auto!important;flex-direction:column!important;
 overflow-y:auto!important;overflow-x:hidden!important;width:100%!important;min-height:0!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav button[data-page]{
 width:100%!important;min-height:37px!important;display:flex!important;align-items:center!important;
 justify-content:flex-start!important;text-align:left!important;gap:10px!important;padding:8px 10px!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav button[data-page] span{
 display:inline!important;visibility:visible!important;opacity:1!important;
 width:auto!important;height:auto!important;max-width:none!important;font-size:12px!important;
 overflow:visible!important;white-space:normal!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav.isp-nav-grouped .nav-group-head{
 display:flex!important;align-items:center!important;justify-content:space-between!important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav.isp-nav-grouped .nav-group-body{display:none!important}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav.isp-nav-grouped .nav-group.open .nav-group-body{display:flex!important}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .sidebar-toggle{display:none!important}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .profile{
 flex:0 0 auto!important;min-width:0!important;
}
body.iyes-r2-active .iyes-r2a-close-menu{display:none}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar .iyes-r2a-close-menu{
 display:flex!important;position:absolute!important;right:12px!important;top:12px!important;z-index:9003!important;
 width:34px!important;height:34px!important;min-height:34px!important;align-items:center!important;justify-content:center!important;
 font-size:18px!important;line-height:1!important;border-radius:10px!important;
 border:1px solid var(--r2-border)!important;background:var(--r2-tint)!important;color:var(--r2-fg)!important;
}
/* Quando a tela é baixa, priorize contatos e mantenha os controles utilizáveis. */
@media(max-height:780px){
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpi{min-height:48px!important;max-height:53px!important;padding:4px 2px!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpi strong{font-size:16px!important}
 body.iyes-r2-active .iyes-r2-sidebar .iyes-ux-sidebar-head{min-height:25px!important}
 body.iyes-r2-active .iyes-r2-sidebar .inbox-search input{height:31px!important;min-height:31px!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs{min-height:27px!important}
 body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-list-title{min-height:22px!important}
 body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-contact-avatar{width:32px!important;height:32px!important;flex-basis:32px!important}
 body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv.iyes-r2-row{min-height:57px!important;padding-top:6px!important;padding-bottom:6px!important}
 body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv-subline{display:none!important}
}
@media(max-width:980px){
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpis{grid-template-columns:repeat(4,minmax(0,1fr))!important}
}

/* Native sidebar toggle must not protrude into workspace; the R2A drawer has its own close control. */
body.iyes-r2-active.iyes-ux-isp .shell > .sidebar #sidebar-toggle,body.iyes-r2-active.iyes-ux-master .shell > .sidebar #sidebar-toggle{display:none!important}


/* R20-UX-R2B: recuperar altura integral no primeiro render, inclusive sem conversa aberta. */
@media (min-width:981px){
 body.iyes-r2-active.iyes-ux-operator .operator-shell,
 body.iyes-r2-active.operator-body .operator-shell{
   display:flex!important;flex-direction:column!important;
   height:100dvh!important;min-height:100dvh!important;max-height:100dvh!important;
   overflow:hidden!important;box-sizing:border-box!important;
 }
 body.iyes-r2-active.operator-body .operator-shell>.operator-topbar{
   flex:0 0 auto!important;min-height:58px!important;max-height:70px!important;
 }
 body.iyes-r2-active.operator-body .operator-shell>.operator-content{
   display:flex!important;flex-direction:column!important;flex:1 1 auto!important;
   height:auto!important;min-height:0!important;max-height:none!important;
   overflow:hidden!important;box-sizing:border-box!important;
 }
 body.iyes-r2-active.operator-body .operator-shell>.operator-content>.operator-inbox.inbox.inbox-pro.iyes-r2-workspace{
   flex:1 1 auto!important;display:grid!important;
   height:calc(100dvh - 78px)!important;
   min-height:calc(100dvh - 78px)!important;
   max-height:calc(100dvh - 78px)!important;
   overflow:hidden!important;box-sizing:border-box!important;
 }
 body.iyes-r2-active.iyes-ux-isp .shell,
 body.iyes-r2-active.iyes-ux-master .shell{
   height:100dvh!important;max-height:100dvh!important;min-height:100dvh!important;
   overflow:hidden!important;box-sizing:border-box!important;
 }
 body.iyes-r2-active.iyes-ux-isp .shell>.content,
 body.iyes-r2-active.iyes-ux-master .shell>.content{
   height:100dvh!important;max-height:100dvh!important;min-height:0!important;
   display:flex!important;flex-direction:column!important;overflow:hidden!important;
 }
 body.iyes-r2-active.iyes-ux-isp .shell>.content>.iyes-ux-shell-topbar,
 body.iyes-r2-active.iyes-ux-master .shell>.content>.iyes-ux-shell-topbar{flex:0 0 auto!important}
 body.iyes-r2-active.iyes-ux-isp .shell>.content>.inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active.iyes-ux-master .shell>.content>.saas-inbox-layout.iyes-r2-workspace{
   flex:1 1 auto!important;height:auto!important;min-height:0!important;
   max-height:none!important;box-sizing:border-box!important;overflow:hidden!important;
 }
 /* Pai e filhos precisam permitir scroll INTERNO, não encolher a grid. */
 body.iyes-r2-active .iyes-r2-workspace>.iyes-r2-sidebar,
 body.iyes-r2-active .iyes-r2-workspace>.iyes-r2-chat-workspace,
 body.iyes-r2-active .iyes-r2-workspace>.iyes-r2-context-panel{
   min-height:0!important;height:100%!important;max-height:100%!important;
   box-sizing:border-box!important;
 }
}
/* Canais: ícones nos botões existentes, com handlers e seleção intactos. */
body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="meta"],
body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="evolution"]{
  display:inline-flex!important;align-items:center!important;gap:5px!important;
  padding:5px 9px!important;white-space:nowrap!important;flex:0 0 auto!important;
}
body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="meta"]::before,
body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="evolution"]::before{
  content:""!important;display:inline-block!important;flex:0 0 17px!important;
  width:17px!important;height:17px!important;background-size:contain!important;
  background-position:center!important;background-repeat:no-repeat!important;
}
body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="meta"]::before{
  background-image:url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%3E%3Cpath%20fill%3D%22%2316a34a%22%20d%3D%22M12.04%202C6.56%202%202.1%206.44%202.1%2011.9c0%201.77.47%203.5%201.36%205.02L2%2022l5.25-1.38a9.9%209.9%200%200%200%204.79%201.22h.01c5.48%200%209.94-4.45%209.95-9.91A9.87%209.87%200%200%200%2019.1%204.9%209.89%209.89%200%200%200%2012.04%202Zm0%2018.17h-.01a8.25%208.25%200%200%201-4.2-1.15l-.3-.17-3.11.82.83-3.03-.2-.31a8.2%208.2%200%200%201-1.26-4.39%208.26%208.26%200%200%201%208.25-8.23%208.26%208.26%200%200%201%208.24%208.24%208.26%208.26%200%200%201-8.24%208.22Zm4.52-6.17c-.25-.12-1.46-.72-1.69-.8-.22-.09-.39-.13-.55.12s-.64.8-.79.97c-.14.16-.29.19-.54.06-.25-.12-1.05-.39-2-1.24-.74-.67-1.24-1.49-1.38-1.74-.14-.24-.01-.38.11-.5.11-.11.25-.29.37-.43.13-.15.17-.25.25-.42.08-.16.04-.31-.02-.43-.06-.13-.55-1.33-.75-1.82-.2-.47-.4-.41-.55-.41h-.47c-.16%200-.43.06-.66.31s-.87.85-.87%202.08.89%202.42%201.02%202.58c.12.17%201.76%202.68%204.27%203.76.6.26%201.06.41%201.43.53.6.2%201.15.17%201.58.1.48-.07%201.47-.6%201.68-1.19.21-.58.21-1.08.15-1.18-.07-.11-.23-.17-.48-.29Z%22%2F%3E%3C%2Fsvg%3E")!important;
}
body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="evolution"]::before{
  background-image:url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%3E%3Crect%20width%3D%2222%22%20height%3D%2222%22%20x%3D%221%22%20y%3D%221%22%20rx%3D%2211%22%20fill%3D%22%2310a99c%22%2F%3E%3Cpath%20fill%3D%22%23fff%22%20d%3D%22M15.8%206.3H10.7a5.8%205.8%200%201%200%200%2011.4h5.1v-2.6h-4.8a3.1%203.1%200%200%201-2.87-1.95h6.63v-2.4H8.13A3.1%203.1%200%200%201%2011%208.8h4.8z%22%2F%3E%3C%2Fsvg%3E")!important;
}
body.iyes-r2-active .v353-channelbar{scrollbar-width:thin!important}
body.iyes-r2-active .v353-channelbar .v353-channel-chip{overflow:visible!important}
/* Sidebar fica com scroll individual e o restante do layout não desaparece na abertura. */
body.iyes-r2-active .iyes-r2-sidebar{display:flex!important;flex-direction:column!important;
  min-height:0!important;max-height:100%!important;overflow:hidden!important}
body.iyes-r2-active .iyes-r2-sidebar #conv-list,
body.iyes-r2-active .iyes-r2-sidebar .saas-conv-list{
  flex:1 1 auto!important;min-height:0!important;overflow-y:auto!important;overscroll-behavior:contain!important}
/* Evitar cartões invisíveis por overflow do início da lista. */
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-list-title{flex:0 0 auto!important}
/* Telas compactas mantêm navegação nativa de conversa / lista. */
@media(max-width:980px){
 body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="meta"],
 body.iyes-r2-active .v353-channelbar .v353-channel-chip[data-r5ch="evolution"]{gap:5px!important}
 body.iyes-r2-active .iyes-r2-sidebar{height:100%!important;min-height:0!important}
}


/* R20-UX-R2C: RESTAURA FILTROS DE CANAL/SEARCH.
   O modulo v353r7 controla row.style.display = "none".
   A R2B aplicava display:grid!important nas linhas e ignorava o estilo inline.
   Quando o usuario filtrar Meta/Evolution/busca, display:none DEVE prevalecer.
   Nao cria API, listeners ou observers. */
body.iyes-r2-active #conv-list > .conv[style*="display: none" i],
body.iyes-r2-active #conv-list > .conv[style*="display:none" i],
body.iyes-r2-active #conv-list > .conv.iyes-r2-row[style*="display: none" i],
body.iyes-r2-active #conv-list > .conv.iyes-r2-row[style*="display:none" i]{
 display:none!important;
}

/* R2C — consistencia visual do mockup: tres zonas e cards mais legiveis. */
@media(min-width:1280px){
 body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace{
   grid-template-columns:minmax(315px,338px) minmax(0,1fr) minmax(266px,300px)!important;
 }
}
@media(min-width:1650px){
 body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace,
 body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace{
   grid-template-columns:minmax(338px,372px) minmax(0,1fr) minmax(300px,340px)!important;
 }
}
/* Os 4 indicadores tornam-se 2 x 2 como no mockup, sem perder os filtros existentes. */
@media(min-width:1280px) and (min-height:720px){
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpis.iyes-r2-queue-overview{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:6px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi{
  min-height:46px!important;max-height:52px!important;align-items:flex-start!important;
  text-align:left!important;padding:7px 10px!important;gap:3px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpi span{text-align:left!important;font-size:10px!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpi strong{font-size:18px!important}
}
body.iyes-r2-active .iyes-r2-sidebar .inbox-search.iyes-r2-search-area{
 background:transparent!important;border:0!important;padding-top:5px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .inbox-search input{
 background:var(--r2-surface)!important;border-color:var(--r2-border)!important;
}
/* Canais exibidos sem barra de rolagem horizontal permanente;
   identificadores completos mantidos no proprio botao (Meta pode ter varios numeros). */
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar,
body.iyes-r2-active .iyes-r2-sidebar .inbox-search:has(.v353-channelbar)>.v353-channelbar{
 display:flex!important;flex-wrap:wrap!important;gap:5px!important;
 overflow-x:visible!important;overflow-y:visible!important;
 max-height:none!important;min-height:29px!important;height:auto!important;
 padding:6px 0 4px!important;white-space:normal!important;
}
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar::before{
 content:'Canais'!important;flex-basis:100%!important;
 font-size:11px!important;font-weight:750!important;margin:0!important;
}
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar .v353-channel-chip{
 display:inline-flex!important;align-items:center!important;justify-content:center!important;
 max-width:100%!important;min-height:29px!important;
 border-radius:9px!important;padding:5px 8px!important;font-size:10.5px!important;
 color:var(--r2-fg)!important;background:var(--r2-surface)!important;
 border:1px solid var(--r2-border)!important;white-space:normal!important;
 word-break:break-word!important;line-height:1.2!important;text-align:center!important;
}
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar .v353-channel-chip.active{
 background:var(--r2-blue)!important;color:white!important;border-color:var(--r2-blue)!important;
 box-shadow:0 2px 8px rgba(23,106,242,.13)!important;
}
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar .v353-channel-chip:focus-visible{
 outline:2px solid var(--r2-blue)!important;outline-offset:2px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-list-title{
 padding-top:7px!important;border-top:1px solid var(--r2-border)!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv.iyes-r2-row{
 border-radius:11px!important;padding-top:9px!important;padding-bottom:9px!important;
 transition:background-color .12s ease,border-color .12s ease!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv.iyes-r2-row.active{
 background:linear-gradient(90deg,rgba(23,106,242,.13),rgba(23,106,242,.035))!important;
 border-left:4px solid var(--r2-blue)!important;
}
body.iyes-r2-active .iyes-r2-sidebar .conv-head-main b{
 font-size:13px!important;line-height:1.18!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv-foot{
 font-size:10px!important;color:var(--r2-muted)!important;
}
/* Topo e campo de envio: botões preservados e alinhados no mesmo design system. */
body.iyes-r2-active .chat-head.iyes-r2-header-structured{
 padding:10px 14px!important;border-radius:14px 14px 0 0!important;
}
body.iyes-r2-active .iyes-r2-head-identity .chat-person-top b{
 font-size:16px!important;letter-spacing:-.015em!important;
}
body.iyes-r2-active .iyes-r2-head-controls .chat-head-actions{gap:6px!important}
body.iyes-r2-active .chat-head-actions button,
body.iyes-r2-active .chat-head-actions .small{
 border-radius:9px!important;white-space:nowrap!important;
}
body.iyes-r2-active .chat .messages{
 background:var(--r2-surface)!important;
}
body.iyes-r2-active .chat .bubble{
 border-radius:12px!important;
}
/* Composer sem barra horizontal cortando as ferramentas. Em telas compactas,
   preserva a rolagem nativa para nao ocultar os comandos ERP/Audio/Copilot. */
@media(min-width:1280px) and (min-height:720px){
 body.iyes-r2-active .composer-pro.iyes-r2-composer{
  max-height:165px!important;min-height:97px!important;
 }
 body.iyes-r2-active .composer-pro.iyes-r2-composer .composer-tools{
  display:flex!important;flex-wrap:wrap!important;height:auto!important;
  min-height:32px!important;max-height:72px!important;overflow-y:auto!important;
  overflow-x:hidden!important;gap:5px!important;padding:1px 0 5px!important;
 }
 body.iyes-r2-active .composer-pro.iyes-r2-composer .composer-tools button,
 body.iyes-r2-active .composer-pro.iyes-r2-composer .composer-tools select{
  flex:0 0 auto!important;border-radius:9px!important;
 }
}
@media(max-width:980px){
 body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar .v353-channel-chip{min-height:34px!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpis{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}


/* R20-UX-R2D — aproximação visual do menu/filtros ao mockup aprovado */
body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs{
 display:flex!important;flex-wrap:wrap!important;gap:8px!important;
 min-height:auto!important;max-height:none!important;overflow:visible!important;
 padding:8px 0 2px!important;margin:0!important;align-items:center!important;
}
body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs button{
 display:inline-flex!important;align-items:center!important;justify-content:center!important;
 min-height:34px!important;padding:0 14px!important;border-radius:999px!important;
 border:1px solid var(--r2-border)!important;background:#fff!important;color:var(--r2-fg)!important;
 font-size:12px!important;font-weight:700!important;line-height:1!important;
 box-shadow:0 1px 3px rgba(15,23,42,.04)!important;transition:all .16s ease!important;
}
body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs button:hover{
 border-color:rgba(23,106,242,.22)!important;background:rgba(23,106,242,.03)!important;
}
body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs button.active{
 background:var(--r2-blue)!important;color:#fff!important;border-color:var(--r2-blue)!important;
 box-shadow:0 8px 18px rgba(23,106,242,.18)!important;
}
body.iyes-r2-active .iyes-r2-sidebar .inbox-search.iyes-r2-search-area{
 padding-top:8px!important;gap:8px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .inbox-search input{
 min-height:40px!important;height:40px!important;border-radius:12px!important;
 padding:8px 12px!important;font-size:13px!important;
 box-shadow:0 1px 2px rgba(15,23,42,.03)!important;
}
body.iyes-r2-active .iyes-r2-sidebar #conv-count{
 font-size:10px!important;line-height:1.2!important;color:var(--r2-muted)!important;
 margin:0 2px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar::before{
 font-size:12px!important;font-weight:800!important;margin-bottom:2px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-list-title{
 padding-top:8px!important;padding-bottom:6px!important;
}
@media(max-width:980px){
 body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs{gap:6px!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs button{
  min-height:32px!important;padding:0 12px!important;font-size:11.5px!important;
 }
}


/* IYESCHAT R20-UX-R2E - lista expansível sem alterar os componentes vivos. */
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-list-title{
  display:flex!important;align-items:center!important;justify-content:space-between!important;
  min-width:0!important;gap:8px!important;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2e-list-controls{
  display:inline-flex;align-items:center;justify-content:flex-end;gap:8px;flex:0 0 auto;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2e-expand-button{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;
  flex:0 0 32px!important;width:32px!important;height:30px!important;min-height:30px!important;
  margin:0!important;padding:0!important;border-radius:9px!important;
  border:1px solid var(--r2-border)!important;background:var(--r2-surface)!important;
  color:var(--r2-blue)!important;font-size:20px!important;font-weight:600!important;line-height:1!important;
  cursor:pointer;box-shadow:0 1px 2px rgba(15,23,42,.04)!important;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2e-expand-button:hover{
  background:var(--r2-tint)!important;border-color:rgba(23,106,242,.4)!important;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2e-expand-button[aria-pressed='true']{
  color:#fff!important;background:var(--r2-blue)!important;border-color:var(--r2-blue)!important;
}
body.iyes-r2-active .iyes-r2-sidebar .iyes-r2e-expand-button:focus-visible{
  outline:2px solid var(--r2-blue)!important;outline-offset:2px!important;
}
@media(min-width:1280px) and (max-width:1649px){
  body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace.iyes-r2e-list-expanded,
  body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace.iyes-r2e-list-expanded,
  body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace.iyes-r2e-list-expanded{
    grid-template-columns:clamp(410px,38vw,520px) minmax(0,1fr) minmax(266px,300px)!important;
  }
}
@media(min-width:1650px){
  body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace.iyes-r2e-list-expanded,
  body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace.iyes-r2e-list-expanded,
  body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace.iyes-r2e-list-expanded{
    grid-template-columns:minmax(520px,560px) minmax(0,1fr) minmax(300px,340px)!important;
  }
}
@media(min-width:981px) and (max-width:1279px){
  body.iyes-r2-active .inbox.inbox-pro.iyes-r2-workspace.iyes-r2e-list-expanded,
  body.iyes-r2-active .operator-inbox.inbox-pro.iyes-r2-workspace.iyes-r2e-list-expanded,
  body.iyes-r2-active.iyes-ux-master .saas-inbox-layout.iyes-r2-workspace.iyes-r2e-list-expanded{
    grid-template-columns:clamp(350px,42vw,510px) minmax(0,1fr)!important;
  }
}
/* Em telas de celular/tablet a lista já ocupa a largura inteira. O botão foca
   a listagem reduzindo indicadores, com retorno por outro clique. */
@media(max-width:980px){
  body.iyes-r2-active .iyes-r2-workspace.iyes-r2e-list-expanded .operator-kpis{
    display:none!important;
  }
  body.iyes-r2-active .iyes-r2-workspace.iyes-r2e-list-expanded .iyes-ux-sync{
    display:none!important;
  }
  body.iyes-r2-active .iyes-r2-workspace.iyes-r2e-list-expanded .iyes-r2-list-title{
    padding-block:8px!important;
  }
}
@media(prefers-reduced-motion:no-preference) and (min-width:981px){
  body.iyes-r2-active .iyes-r2-workspace{
    transition:grid-template-columns .2s ease-out;
  }
}

/* R20-S5: prévia da última mensagem recebida, uma linha legível e segura. */
body.iyes-r2-active #conv-list .conv.iyes-r2-row .conv-subline.iyes-s5-preview{
 display:block!important;grid-area:sub!important;overflow:hidden!important;
 text-overflow:ellipsis!important;white-space:nowrap!important;max-width:100%!important;
 font-size:11px!important;line-height:1.3!important;color:var(--r2-muted)!important;
}
body.iyes-r2-active #conv-list .conv.iyes-r2-row .iyes-s5-search-terms{
 position:absolute!important;width:1px!important;height:1px!important;padding:0!important;
 margin:-1px!important;overflow:hidden!important;clip-path:inset(50%)!important;
 white-space:nowrap!important;pointer-events:none!important;
}
body.iyes-r2-active .saas-conv-list .iyes-s5-master-preview{
 overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%;font-size:11px;
}
@media(max-height:700px){
 body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv-subline.iyes-s5-preview{
  display:block!important;font-size:10px!important;
 }
}


/* R20-S5R1: telas baixas -> indicadores úteis, lista de contatos com prioridade.
   Exclusivamente CSS; tabs, contadores, busca e canais continuam interativos. */
@media (max-height: 820px) and (min-width: 801px) {
 body.iyes-r2-active .iyes-r2-sidebar{gap:3px!important;padding:7px!important}
 body.iyes-r2-active .iyes-r2-sidebar .iyes-ux-sidebar-head{min-height:26px!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpis.iyes-r2-queue-overview{
   display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;
   gap:4px!important;margin:0!important;padding:0!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi{
   min-height:52px!important;max-height:52px!important;padding:5px 2px!important;
   flex-direction:column!important;align-items:center!important;justify-content:center!important;
   text-align:center!important;gap:3px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpi span{
   text-align:center!important;font-size:9px!important;line-height:1.04!important;
   max-width:100%!important;display:-webkit-box!important;-webkit-line-clamp:2!important;
   -webkit-box-orient:vertical!important;overflow:hidden!important;white-space:normal!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpi strong{font-size:17px!important;line-height:1!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs{
   display:flex!important;flex-wrap:nowrap!important;gap:4px!important;
   min-height:27px!important;max-height:29px!important;
   overflow-x:auto!important;padding:2px 0!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs button{
   min-height:25px!important;padding:3px 9px!important;font-size:10.5px!important;
   white-space:nowrap!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .inbox-search.iyes-r2-search-area{
   gap:2px!important;padding:2px 0!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .inbox-search input{
   min-height:32px!important;height:32px!important;padding:5px 10px!important;font-size:11px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar #conv-count{
   font-size:9px!important;line-height:10px!important;margin:0 2px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar,
 body.iyes-r2-active .iyes-r2-sidebar .inbox-search:has(.v353-channelbar)>.v353-channelbar{
   gap:4px!important;padding:3px 0!important;min-height:27px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar::before{
   font-size:10px!important;line-height:12px!important;margin:0!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .v353-channelbar .v353-channel-chip{
   min-height:24px!important;padding:3px 6px!important;font-size:9.5px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-list-title{
   min-height:22px!important;padding:4px 3px 2px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv.iyes-r2-row{
   min-height:63px!important;padding:6px!important;margin-bottom:4px!important;row-gap:1px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .iyes-r2-contact-avatar{
   width:32px!important;height:32px!important;flex-basis:32px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar #conv-list .conv.iyes-r2-row{
   grid-template-columns:32px minmax(0,1fr)!important;
 }
}
@media (max-height: 650px) and (min-width:801px) {
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi{
   min-height:45px!important;max-height:45px!important;
 }
 body.iyes-r2-active .iyes-r2-sidebar .operator-kpi strong{font-size:16px!important}
 body.iyes-r2-active .iyes-r2-sidebar .operator-queue-tabs{min-height:25px!important}
}


/* R20-S5R2: indicadores legíveis na lateral estreita de notebook.
   Nome completo permanece no DOM/acessibilidade. Sem alterar eventos de filtro. */
body.iyes-r2-active .iyes-r2-sidebar .operator-kpis.iyes-r2-queue-overview {
 container-type:inline-size;
}
@container (max-width: 382px) {
  body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi span {
  overflow:visible!important;text-overflow:clip!important;
  -webkit-line-clamp:unset!important;white-space:normal!important;
 }
 /* Abreviação SOMENTE visual; os rótulos completos originais continuam
    acessíveis na estrutura do botão, com contagem e sem truncamento. */
  body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi:nth-child(2) span,
  body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi:nth-child(3) span,
  body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi:nth-child(4) span {
  font-size:0!important;line-height:1!important;white-space:nowrap!important;
 }
  body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi:nth-child(2) span::after {
  content:'Meus';font-size:10px;line-height:13px;
 }
  body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi:nth-child(3) span::after {
  content:'Equipe';font-size:10px;line-height:13px;
 }
  body.iyes-r2-active .iyes-r2-sidebar .operator-kpis .operator-kpi:nth-child(4) span::after {
  content:'Encerrados';font-size:9px;line-height:13px;
 }
}

/* R20-MENU-R1: expanded drawer must not inherit the 54px collapsed rail.
   Scoped to the open administrative drawer; no inbox or runtime changes. */
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav > *,
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav .nav-group-body {
  min-width: 0 !important;
  max-width: 100% !important;
  width: 100% !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav [data-page],
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav #iyes-v347-receipts-nav,
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav #iyes-iptv-nav {
  display: flex !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  flex-shrink: 0 !important;
  justify-content: flex-start !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 8px 10px !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  box-sizing: border-box !important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav [data-page] > i,
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav #iyes-v347-receipts-nav > i,
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav #iyes-iptv-nav > .iptv-nav-icon {
  display: inline-flex !important;
  flex: 0 0 24px !important;
  width: 24px !important;
  justify-content: center !important;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav [data-page] > span:not([class*='badge']),
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav #iyes-v347-receipts-nav > span:not([class*='badge']) {
  display: inline !important;
  min-width: 0 !important;
  white-space: normal !important;
  overflow-wrap: anywhere;
}
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav .nav-group-title,
body.iyes-ux-nav-open .shell.iyes-r2a-drawer-expanded > .sidebar nav .nav-group-chevron {
  display: inline-flex !important;
  visibility: visible !important;
}
