/* Scoped fixes for the actual legacy components, including gradient surfaces. */
:root.sgw-stable-light body main :is(.card130,.stat130,.statusgrid130>div,.info130>div,.v186-ipmac-stats>div,.v186-ip-card,.v186-ip-grid>div,.v186-card-top,.v186-card-foot,.v186-ipmac-toolbar,.v186-ipmac-empty),
:root.sgw-stable-light body :is(.modalbox130,.modalhead130,.modalbody130,.msg130) {
  background:#fff!important; color:#22334a!important; -webkit-text-fill-color:currentColor!important;
  border-color:#d7e0e9!important; border-radius:6px!important; box-shadow:none!important;
  min-width:0!important; box-sizing:border-box!important;
}
:root.sgw-stable-light body main :is(.v130,.v186-ipmac-page) :is(h1,h2,h3,h4,label,b,strong),
:root.sgw-stable-light body :is(.modalbox130,.msg130) { color:#22334a!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body main :is(.mut130,.field130 label,.stat130 small,.statusgrid130 small,.v186-ipmac-head p,.v186-ipmac-stats span,.v186-ipmac-stats small,.v186-card-top small,.v186-ip-grid span,.v186-card-foot>span) {
  color:#465970!important; -webkit-text-fill-color:currentColor!important; font-size:12px!important; line-height:1.45!important; opacity:1!important;
}
:root.sgw-stable-light body main :is(.v130,.v186-ipmac-page) { padding:16px 0!important; }
:root.sgw-stable-light body main .layout130 { grid-template-columns:minmax(0,1.12fr) minmax(0,1fr)!important; }
:root.sgw-stable-light body main :is(.trafficHead130,.top130,.actions130) { flex-wrap:wrap!important; gap:10px!important; }
:root.sgw-stable-light body main .stats130 { grid-template-columns:repeat(auto-fit,minmax(min(100%,150px),1fr))!important; }
:root.sgw-stable-light body main .stat130 b { white-space:normal!important; overflow-wrap:anywhere!important; font-size:18px!important; }
:root.sgw-stable-light body main :is(.formgrid130,.statusgrid130) { grid-template-columns:repeat(2,minmax(0,1fr))!important; }
:root.sgw-stable-light body main .checkrow130 label { font-size:13px!important; line-height:1.4!important; color:#22334a!important; }
:root.sgw-stable-light body .msg130 { white-space:pre-wrap!important; overflow-wrap:anywhere!important; }
:root.sgw-stable-light body main .v186-ipmac-cards { grid-template-columns:repeat(auto-fit,minmax(min(100%,330px),1fr))!important; }
:root.sgw-stable-light body main .v186-card-foot { display:flex!important; flex-direction:column!important; align-items:stretch!important; gap:10px!important; }
:root.sgw-stable-light body main .v263-card-actions { display:flex!important; flex-wrap:wrap!important; justify-content:flex-end!important; gap:6px!important; }
:root.sgw-stable-light body main .v186-card-foot>span { flex:0 0 auto!important; white-space:normal!important; overflow-wrap:anywhere!important; }
:root.sgw-stable-light body main .v186-card-top { align-items:flex-start!important; gap:12px!important; }
:root.sgw-stable-light body main .v186-card-top>div { min-width:0!important; }
:root.sgw-stable-light body main .v186-card-top h3 { font-size:15px!important; line-height:1.4!important; overflow-wrap:anywhere!important; }
:root.sgw-stable-light body main .v186-ip-grid b { font-size:13px!important; line-height:1.4!important; }
:root.sgw-stable-light body main :is(.v186-live,.v344-badge,.v433-badge,.off-days,.days-off) { font-size:12px!important; white-space:nowrap!important; }
:root.sgw-stable-light body main :is(.v186-live.online,.v344-badge.on,.v433-badge.on,span.online) { background:#ecfdf5!important; color:#116339!important; -webkit-text-fill-color:currentColor!important; border-color:#b9e6ce!important; }
:root.sgw-stable-light body main :is(.v186-live.offline,.v344-badge.off,.v433-badge.off,span.offline) { background:#fef2f2!important; color:#991b1b!important; -webkit-text-fill-color:currentColor!important; border-color:#f0c5c5!important; }
:root.sgw-stable-light body main :is(.btn130,.v186-dark-btn,.v263-card-actions button,.v433-server-btn,.v433-filter-btn) {
  background:#fff!important; color:#1456af!important; -webkit-text-fill-color:currentColor!important;
  border:1px solid #bdcfe2!important; border-radius:6px!important; min-height:34px!important; font-size:12px!important; line-height:1.35!important;
}
:root.sgw-stable-light body main :is(.btn130.primary130,.btn130.green130) { background:#1768d5!important; color:#fff!important; border-color:#1768d5!important; }
:root.sgw-stable-light body main :is(.btn130.danger130,.v263-delete-btn) { background:#fff5f5!important; color:#991b1b!important; border-color:#f0c5c5!important; }
/* Professional client list: compact light controls and room for every action. */
:root.sgw-stable-light body.sgw-clientes-premium main :is(.table-card.clientes-page,.sgw217-pagination) { flex:0 0 auto!important; }
:root.sgw-stable-light body main :is(.v101-tabs,.v101-filters,.sgw-mon-tabs,.sgw-mon-filterbox) button {
  background:#fff!important; color:#1456af!important; -webkit-text-fill-color:currentColor!important; border:1px solid #bdcfe2!important;
  border-radius:6px!important; min-height:34px!important; font-size:12px!important; line-height:1.4!important; padding:7px 10px!important;
}
:root.sgw-stable-light body main :is(.v101-tabs,.v101-filters,.sgw-mon-tabs,.sgw-mon-filterbox) button.active { background:#edf4fc!important; color:#1456af!important; border-color:#1768d5!important; }
:root.sgw-stable-light body main :is(.v101-tabs,.v101-filters,.sgw-mon-tabs,.sgw-mon-filterbox) button small { color:#465970!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body main :is(.v101-table,.sgw-mon-table) td { background:#fff!important; color:#22334a!important; -webkit-text-fill-color:currentColor!important; border-color:#e5ebf1!important; }
:root.sgw-stable-light body main :is(.v101-table,.sgw-mon-table) th { background:#f3f6fa!important; color:#22334a!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body main .v101-days.online { background:#ecfdf5!important; color:#116339!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body main .v101-days.amarelo { background:#fffbea!important; color:#75510a!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body main .v101-days.vermelho { background:#fef2f2!important; color:#991b1b!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body main .v101-onoff-top h1 { font-size:24px!important; line-height:1.35!important; }
:root.sgw-stable-light body main .v101-tablebox { max-width:100%!important; overflow:auto!important; }
:root.sgw-stable-light body main :is(.v101-tabs,.v101-filters) { flex-wrap:wrap!important; }
:root.sgw-stable-light body.sgw-clientes-premium main { padding:18px 24px!important; border:0!important; }
:root.sgw-stable-light body.sgw-clientes-premium main .clientes-kpis { gap:12px!important; margin-bottom:14px!important; }
:root.sgw-stable-light body.sgw-clientes-premium main .kpi { border-radius:6px!important; box-shadow:none!important; min-height:86px!important; }
:root.sgw-stable-light body.sgw-clientes-premium main :is(.toolbar,.toolbar-left,.toolbar-right,.client-actions,.sgw563-pagination-top,.sgw217-pagination) {
  background:#fff!important; border-color:#d7e0e9!important; color:#22334a!important; height:auto!important; max-height:none!important; min-height:0!important; overflow:visible!important; flex-wrap:wrap!important; gap:8px!important;
}
:root.sgw-stable-light body.sgw-clientes-premium main :is(.sgw563-pagination-top,.sgw217-pagination) { padding:10px!important; margin:10px 0!important; }
:root.sgw-stable-light body.sgw-clientes-premium main :is(.sgw563-top-pages,.sgw217-pages,.mini-actions) { display:flex!important; flex-wrap:wrap!important; gap:6px!important; align-items:center!important; }
:root.sgw-stable-light body.sgw-clientes-premium main .table-card.clientes-page { height:auto!important; max-height:none!important; min-height:0!important; overflow:auto!important; border:1px solid #d7e0e9!important; border-radius:6px!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable {
  width:100%!important; min-width:960px!important; height:auto!important; table-layout:fixed!important;
}
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable :is(tr,th,td) { height:auto!important; min-height:0!important; max-height:none!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable :is(th,td) {
  padding:10px 12px!important; font-family:Arial,Helvetica,sans-serif!important; font-size:13px!important; line-height:1.4!important; vertical-align:middle!important;
  background:#fff!important; color:#22334a!important; -webkit-text-fill-color:currentColor!important; border-color:#e5ebf1!important;
}
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable th { background:#f3f6fa!important; font-size:12px!important; font-weight:700!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable tbody tr:hover td { background:#f5f9fe!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable :is(th,td):first-child { width:40px!important; min-width:40px!important; max-width:40px!important; padding:8px!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable :is(th,td):nth-child(2) { width:190px!important; min-width:190px!important; max-width:190px!important; overflow:visible!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable .mini-actions>form { display:inline-flex!important; width:30px!important; min-width:30px!important; max-width:30px!important; padding:0!important; margin:0 3px!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable :is(th,td):nth-child(3) { width:64px!important; min-width:64px!important; max-width:64px!important; }
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable td .row-link { color:#1456af!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body.sgw-clientes-premium main :is(.icon-button,.sgw217-pagebtn,.link-btn,.btn:not(.primary)) {
  background:#fff!important; color:#1456af!important; -webkit-text-fill-color:currentColor!important; border:1px solid #bdcfe2!important; border-radius:5px!important; box-shadow:none!important;
}
:root.sgw-stable-light body.sgw-clientes-premium main #sgw567ClientesTable#sgw567ClientesTable .icon-button { width:30px!important; min-width:30px!important; height:30px!important; min-height:30px!important; padding:0!important; font-size:14px!important; }
:root.sgw-stable-light body.sgw-clientes-premium main :is(.icon-button.danger,.link-btn.danger) { background:#fff5f5!important; color:#991b1b!important; border-color:#f0c5c5!important; }
:root.sgw-stable-light body.sgw-clientes-premium main :is(.sgw217-current,.sgw563-top-pages .current) { background:#1768d5!important; color:#fff!important; -webkit-text-fill-color:currentColor!important; }
/* Financial results occupy their own full-width band, with bounded scrolling. */
:root.sgw-stable-light body main :is(#sgw689-filter,#sgw689-summary,#sgw689-results) { width:100%!important; max-width:100%!important; min-width:0!important; background:#fff!important; color:#22334a!important; border:1px solid #d7e0e9!important; border-radius:6px!important; box-sizing:border-box!important; }
:root.sgw-stable-light body main #sgw689-filter .sgw689-grid { grid-template-columns:repeat(auto-fit,minmax(min(100%,160px),1fr))!important; }
:root.sgw-stable-light body main #sgw689-results .sgw689-table-wrap { width:100%!important; max-width:100%!important; max-height:440px!important; overflow:auto!important; position:relative!important; }
:root.sgw-stable-light body main #sgw689-results table { width:100%!important; min-width:1040px!important; table-layout:auto!important; border-collapse:separate!important; border-spacing:0!important; }
:root.sgw-stable-light body main #sgw689-results :is(th,td) { padding:10px!important; font-size:13px!important; line-height:1.4!important; vertical-align:middle!important; background:#fff!important; color:#22334a!important; -webkit-text-fill-color:currentColor!important; border-color:#e5ebf1!important; }
:root.sgw-stable-light body main #sgw689-results th { background:#f3f6fa!important; position:sticky!important; top:0!important; z-index:2!important; }
:root.sgw-stable-light body main #sgw689-results :is(th,td):last-child { position:sticky!important; right:0!important; width:210px!important; min-width:210px!important; box-shadow:-3px 0 5px #22334a0d!important; }
:root.sgw-stable-light body main #sgw689-results th:last-child { z-index:3!important; }
:root.sgw-stable-light body main #sgw689-results td:first-child { white-space:normal!important; min-width:180px!important; max-width:280px!important; overflow-wrap:anywhere!important; }
:root.sgw-stable-light body main :is(.sgw689-row-actions,.sgw689-pager,.sgw689-pager-right,.sgw689-results-head) { flex-wrap:wrap!important; height:auto!important; gap:8px!important; min-width:0!important; }
:root.sgw-stable-light body main :is(.sgw689-row-actions a,.sgw689-btn,#sgw689-prev,#sgw689-next) { background:#fff!important; color:#1456af!important; -webkit-text-fill-color:currentColor!important; border:1px solid #bdcfe2!important; min-height:34px!important; font-size:12px!important; }
:root.sgw-stable-light body main :is(.sgw689-note,.sgw689-grid label,.sgw689-card span) { color:#465970!important; opacity:1!important; font-size:12px!important; letter-spacing:0!important; }
:root.sgw-stable-light body main .sgw689-card.warn strong { color:#75510a!important; -webkit-text-fill-color:currentColor!important; }
:root.sgw-stable-light body main .f151-btn.light { background:#fff!important; color:#1456af!important; -webkit-text-fill-color:currentColor!important; border:1px solid #bdcfe2!important; }
:root.sgw-stable-light.sgw455-financeiro-resumo body main :is(.card,.panel,.box,.kpi,[class*="-card"],[class*="-box"],[class*="-kpi"],[class*="saldo"],[class*="receb"],[class*="venc"],[class*="pend"]) { background:#fff!important; color:#22334a!important; border-color:#d7e0e9!important; }
/* A light phone shell and a conversation area independent of legacy card rules. */
:root.sgw-stable-light body #v1360-modelo { font-family:Arial,Helvetica,sans-serif!important; letter-spacing:0!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-grid { grid-template-columns:minmax(0,1fr) minmax(0,1.08fr) minmax(310px,.92fr)!important; align-items:start!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-preview-card { padding:0!important; background:transparent!important; border:0!important; box-shadow:none!important; min-width:0!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-card { border-radius:6px!important; box-shadow:none!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-card-title { padding:0!important; border:0!important; border-radius:0!important; box-shadow:none!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-button-fields { grid-template-columns:minmax(0,1fr)!important; }
:root.sgw-stable-light body #v1360-modelo :is(.v1360-card-title,.v1360-button-head,.v1360-actions) { flex-wrap:wrap!important; min-width:0!important; }
:root.sgw-stable-light body #v1360-modelo :is(.v1360-button-row,.v1360-option,.v1360-help) { border-radius:6px!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone {
  width:350px!important; max-width:100%!important; height:700px!important; min-height:0!important; padding:0!important; margin:0 auto!important;
  display:grid!important; grid-template-rows:26px 64px minmax(0,1fr) 60px 15px!important;
  border:3px solid #c4d0d8!important; border-radius:28px!important; overflow:hidden!important; background:#fff!important; color:#22334a!important; box-shadow:0 8px 24px #22334a12!important;
}
:root.sgw-stable-light body #v1360-modelo .v1360-phone * { box-sizing:border-box!important; -webkit-text-fill-color:currentColor!important; letter-spacing:0!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-status { display:flex!important; justify-content:space-between!important; align-items:center!important; padding:0 22px!important; background:#fff!important; color:#22334a!important; font-size:12px!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-top { display:flex!important; align-items:center!important; gap:8px!important; margin:0!important; padding:8px 12px!important; background:#f6fbf8!important; color:#22334a!important; border-bottom:1px solid #dfe8e2!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-back { font-size:28px!important; color:#147a53!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-avatar { width:38px!important; height:38px!important; flex:0 0 38px!important; background:#e7f5ec!important; border:1px solid #c0dfcd!important; color:#116339!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-contact { min-width:0!important; flex:1!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-contact b { display:block!important; font-size:14px!important; color:#22334a!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-contact small { display:block!important; width:auto!important; padding:0!important; border:0!important; background:transparent!important; border-radius:0!important; font-size:12px!important; color:#465970!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-reset { flex:0 0 32px!important; width:32px!important; height:32px!important; min-width:0!important; min-height:0!important; padding:0!important; background:transparent!important; color:#147a53!important; border:0!important; font-size:24px!important; cursor:pointer!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-chat { min-height:0!important; padding:12px!important; overflow:auto!important; background:#f1f6f2!important; scrollbar-width:thin; }
:root.sgw-stable-light body #v1360-modelo .v1360-chat-date { width:max-content!important; margin:0 auto 12px!important; background:#fff!important; border:1px solid #dfe8e2!important; border-radius:5px!important; padding:4px 9px!important; font-size:12px!important; color:#465970!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-bubble { margin:0 16px 10px 0!important; max-width:none!important; padding:12px 12px 0!important; background:#fff!important; color:#22334a!important; border:1px solid #dfe8e2!important; border-radius:2px 8px 8px!important; white-space:normal!important; font-size:13px!important; line-height:1.5!important; overflow-wrap:anywhere!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-bubble strong { margin:0 0 8px!important; font-size:14px!important; color:#22334a!important; }
:root.sgw-stable-light body #v1360-modelo #p-body { white-space:pre-wrap!important; color:#22334a!important; }
:root.sgw-stable-light body #v1360-modelo #p-footer { font-size:12px!important; color:#465970!important; margin:10px 0 0!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-message-time { text-align:right!important; color:#465970!important; font-size:12px!important; margin:6px 0!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-message-time span { color:#1456af!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-pdf-chip { display:flex!important; align-items:center!important; gap:10px!important; width:auto!important; max-width:none!important; margin:0 16px 8px 0!important; padding:12px!important; background:#fff!important; color:#22334a!important; border:1px solid #dfe8e2!important; border-radius:8px!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-pdf-chip[hidden] { display:none!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-pdf-chip small { display:block!important; font-size:12px!important; color:#465970!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-preview-buttons { display:block!important; max-width:none!important; margin:0 -12px!important; }
:root.sgw-stable-light body #v1360-modelo :is(.v1360-preview-button,.v1360-chat-menu button) { display:block!important; width:100%!important; min-height:40px!important; height:auto!important; white-space:normal!important; overflow-wrap:anywhere!important; padding:10px!important; border:0!important; border-top:1px solid #e4ece7!important; border-radius:0!important; background:#fff!important; color:#1456af!important; text-align:center!important; font-size:13px!important; font-weight:600!important; cursor:pointer!important; }
:root.sgw-stable-light body #v1360-modelo :is(.v1360-preview-button,.v1360-chat-menu button):hover { background:#edf7f1!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-chat-reply { width:fit-content!important; max-width:92%!important; white-space:pre-wrap!important; overflow-wrap:anywhere!important; padding:10px 12px!important; margin:8px 16px 8px 0!important; border:1px solid #dfe8e2!important; border-radius:2px 8px 8px!important; background:#fff!important; color:#22334a!important; font-size:13px!important; line-height:1.5!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-chat-reply.outgoing { margin:8px 0 8px auto!important; background:#dcf5e4!important; border-color:#c1e3ce!important; border-radius:8px 2px 8px 8px!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-chat-menu { margin:8px -12px -10px!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-compose { display:flex!important; align-items:center!important; gap:8px!important; padding:9px!important; border:0!important; margin:0!important; background:#f6fbf8!important; }
:root.sgw-stable-light body #v1360-modelo #p-reply { flex:1!important; min-width:0!important; width:auto!important; height:38px!important; min-height:0!important; padding:8px 12px!important; border:1px solid #dfe8e2!important; border-radius:18px!important; background:#fff!important; color:#22334a!important; font-size:13px!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-compose button { width:38px!important; height:38px!important; min-width:38px!important; min-height:38px!important; padding:0!important; border:0!important; border-radius:50%!important; background:#147a53!important; color:#fff!important; font-size:18px!important; cursor:pointer!important; }
:root.sgw-stable-light body #v1360-modelo .v1360-phone-home { margin:5px auto!important; width:90px!important; height:4px!important; background:#8da197!important; border-radius:3px!important; }
@media(max-width:1150px) {
  :root.sgw-stable-light body #v1360-modelo .v1360-grid { grid-template-columns:repeat(2,minmax(0,1fr))!important; }
  :root.sgw-stable-light body #v1360-modelo .v1360-preview-card { grid-column:1/-1!important; }
}
@media(max-width:800px) {
  :root.sgw-stable-light body main .layout130 { grid-template-columns:minmax(0,1fr)!important; }
  :root.sgw-stable-light body.sgw-clientes-premium main { padding:12px 8px!important; }
  :root.sgw-stable-light body main #sgw689-results :is(th,td):last-child { width:156px!important; min-width:156px!important; }
  :root.sgw-stable-light body main .sgw689-row-actions { flex-direction:column!important; align-items:stretch!important; }
}
@media(max-width:760px) {
  :root.sgw-stable-light body #v1360-modelo .v1360-grid { grid-template-columns:minmax(0,1fr)!important; }
  :root.sgw-stable-light body #v1360-modelo .v1360-preview-card { grid-column:auto!important; }
}
@media(max-width:480px) {
  :root.sgw-stable-light body main :is(.formgrid130,.statusgrid130) { grid-template-columns:minmax(0,1fr)!important; }
  :root.sgw-stable-light body main .v186-ip-grid { grid-template-columns:repeat(2,minmax(0,1fr))!important; }
  :root.sgw-stable-light body #v1360-modelo .v1360-phone { height:650px!important; }
}
