/* ProConta Relatórios Personalizados — estilos da aplicação */
:root{
  --navy:#0A2E5C;
  --navy-deep:#0C1E3D;
  --blue:#1D5FD1;
  --blue-deep:#123E8F;
  --bg-light:#F1F6FD;
  --bg-page:#F5F8FC;
  --white:#FFFFFF;
  --border:#DCE6F5;
  --text:#152238;
  --muted:#5B6B85;
  --good:#0F7A4A;
  --purple:#7C3AED;
  --amber:#92660B;
  --teal:#0E7C6B;
  --indigo:#4338CA;
  --orange:#B5620A;
}
*{box-sizing:border-box;}
body{
  margin:0;
  font-family:'IBM Plex Sans', sans-serif;
  background:var(--bg-page);
  color:var(--text);
  -webkit-font-smoothing:antialiased;
}
.shell{ display:flex; min-height:100vh; align-items:stretch; }

.sidebar{
  width:240px; flex-shrink:0; background:linear-gradient(180deg, var(--navy-deep) 0%, var(--navy) 100%);
  padding:24px 16px; display:flex; flex-direction:column; position:sticky; top:0; height:100vh;
}
.brand{ display:flex; align-items:center; gap:11px; padding:2px 8px 20px; margin-bottom:10px; border-bottom:1px solid rgba(255,255,255,0.12); }
.brand .mark{
  width:38px;height:38px;border-radius:9px; flex-shrink:0;
  background:linear-gradient(160deg, var(--blue) 0%, #4E7FE0 100%);
  display:flex;align-items:center;justify-content:center;
  color:#fff;font-family:'Source Serif 4',serif;font-weight:700;font-size:15px;
}
.brand .mark-img{ width:38px;height:38px;border-radius:9px;flex-shrink:0;display:block; }
.report-band .band-logo{ width:30px;height:30px;border-radius:7px;display:block;margin-bottom:12px; }
.brand .brand-text .name{ font-family:'Source Serif 4', serif; font-size:15px; font-weight:600; color:#fff; line-height:1.2; }
.brand .brand-text .tagline{ font-size:10.5px; color:#9FB6DD; line-height:1.3; }

.nav-item{
  display:flex; align-items:center; gap:11px; padding:11px 12px; border-radius:9px;
  color:#C9D9F2; font-size:13.5px; font-weight:500; cursor:pointer; margin-top:4px;
  transition:background .15s, color .15s; user-select:none;
}
.nav-item svg{ flex-shrink:0; }
.nav-item:hover{ background:rgba(255,255,255,0.07); color:#fff; }
.nav-item.active{ background:rgba(255,255,255,0.14); color:#fff; font-weight:600; }

.main-content{ flex:1; min-width:0; padding:32px 28px 60px; max-width:1180px; }
.view{ display:none; }
.view.active{ display:block; }

.view-header{ margin-bottom:24px; }
.view-header h1{ font-family:'Source Serif 4', serif; font-size:21px; font-weight:600; margin:0 0 4px; color:var(--navy); }
.view-header p{ margin:0; font-size:13.5px; color:var(--muted); }

@media (max-width:900px){
  .shell{ flex-direction:column; }
  .sidebar{ width:100%; height:auto; position:relative; flex-direction:row; align-items:center; padding:14px 16px; overflow-x:auto; }
  .brand{ border-bottom:none; padding:0 14px 0 0; margin:0 10px 0 0; border-right:1px solid rgba(255,255,255,0.12); }
  .nav-item{ margin-top:0; white-space:nowrap; }
  .main-content{ padding:24px 16px 50px; max-width:100%; }
}

/* ---- Dashboard (Visão geral) ---- */
.stats-row{ display:grid; grid-template-columns:repeat(4,1fr); gap:16px; margin-bottom:24px; }
@media (max-width:900px){ .stats-row{ grid-template-columns:repeat(2,1fr); } }
@media (max-width:520px){ .stats-row{ grid-template-columns:1fr; } }
.stat-card{
  background:var(--white); border:1px solid var(--border); border-radius:14px; padding:20px;
  display:flex; align-items:center; gap:14px;
}
.stat-icon{ width:42px; height:42px; border-radius:10px; flex-shrink:0; display:flex; align-items:center; justify-content:center; }
.stat-icon-blue{ background:#E5EEFC; color:var(--blue); }
.stat-icon-indigo{ background:#E9EAFD; color:var(--indigo); }
.stat-icon-amber{ background:#FDF3DC; color:var(--amber); }
.stat-icon-green{ background:#E3F7EC; color:var(--good); }
.stat-label{ font-size:12.5px; color:var(--muted); margin-bottom:4px; }
.stat-value{ font-family:'Source Serif 4', serif; font-size:24px; font-weight:700; color:var(--text); }

.panel-table{ background:var(--white); border:1px solid var(--border); border-radius:14px; padding:24px; }
.panel-table-header{ display:flex; justify-content:space-between; align-items:flex-start; margin-bottom:18px; gap:12px; flex-wrap:wrap; }
.table-title{ font-family:'Source Serif 4', serif; font-size:16px; font-weight:600; color:var(--text); margin:0 0 3px; }
.table-sub{ font-size:12.5px; color:var(--muted); margin:0; }

.dash-table{ width:100%; border-collapse:collapse; font-size:13px; }
.dash-table thead th{
  text-align:left; font-size:10.5px; letter-spacing:.3px; color:var(--muted); font-weight:600;
  padding:0 10px 10px; border-bottom:1px solid var(--border); text-transform:uppercase;
}
.dash-table td{ padding:14px 10px; border-bottom:1px solid var(--border); color:var(--text); vertical-align:middle; }
.dash-table tbody tr:last-child td{ border-bottom:none; }
.dash-cliente-nome{ font-weight:600; }
.dash-cliente-cnpj{ font-size:11.5px; color:var(--muted); }
.dash-empty{ text-align:center; color:var(--muted); font-size:13px; padding:40px 10px; }

.status-pill{ display:inline-block; padding:3px 10px; border-radius:20px; font-size:11px; font-weight:600; }
.status-ok{ background:#E3F7EC; color:var(--good); }
.status-pending{ background:#FDF3DC; color:var(--amber); }

/* ---- Clientes ---- */
.clientes-empty{
  background:var(--white); border:1px dashed var(--border); border-radius:12px; padding:40px 24px;
  text-align:center; color:var(--muted); font-size:13.5px; line-height:1.6;
}
.client-group{ background:var(--white); border:1px solid var(--border); border-radius:12px; margin-bottom:12px; overflow:hidden; transition:box-shadow .2s; }
.client-group.flash-highlight{ box-shadow:0 0 0 3px rgba(29,95,209,0.35); }
.client-group-header{ display:flex; align-items:center; justify-content:space-between; gap:14px; padding:16px 18px; cursor:pointer; flex-wrap:wrap; }
.client-group.selected{ box-shadow:0 0 0 2px var(--blue); }
.client-checkbox{ width:17px; height:17px; margin-right:12px; flex-shrink:0; cursor:pointer; accent-color:var(--blue); }
.client-header-left{ display:flex; align-items:center; }
.client-name{ font-weight:600; color:var(--text); font-size:14px; margin-bottom:3px; }
.client-meta{ font-size:12px; color:var(--muted); }
.client-actions{ display:flex; align-items:center; gap:10px; flex-shrink:0; }
.chevron{ color:var(--muted); font-size:13px; transition:transform .15s; }
.client-history{ border-top:1px solid var(--border); padding:6px 18px 14px; background:var(--bg-light); }

.btn-mini{
  padding:8px 14px; border-radius:7px; border:none; font-size:12.5px; font-weight:600; cursor:pointer;
  font-family:'IBM Plex Sans', sans-serif; transition:opacity .15s; white-space:nowrap;
}
.btn-mini:hover{ opacity:.88; }
.btn-mini-primary{ background:var(--blue); color:#fff; }
.btn-mini-danger{ background:#FDEEEE; color:#9A2A2A; }

.confirm-overlay{ position:fixed; inset:0; background:rgba(12,30,61,0.45); display:flex; align-items:center; justify-content:center; z-index:1000; padding:20px; }
.confirm-box{ background:var(--white); border-radius:12px; padding:22px 24px; max-width:360px; width:100%; box-shadow:0 12px 32px rgba(12,30,61,0.28); }
.confirm-msg{ font-size:13.5px; color:var(--text); margin:0 0 18px; line-height:1.5; }
.confirm-actions{ display:flex; justify-content:flex-end; gap:10px; }

.btn-link{
  background:none; border:none; padding:0; font-size:12.5px; font-weight:600; color:var(--blue);
  cursor:pointer; font-family:'IBM Plex Sans', sans-serif;
}
.btn-link:hover{ color:var(--blue-deep); }

.layout{ display:grid; grid-template-columns:380px 1fr; gap:28px; align-items:start; }
@media (max-width:960px){ .layout{grid-template-columns:1fr;} }

.panel{ background:var(--white); border:1px solid var(--border); border-radius:14px; padding:26px; }
.panel h2{ font-size:14px; color:var(--navy); margin:0 0 18px; font-weight:600; padding-bottom:12px; border-bottom:1px solid var(--border); display:flex; align-items:center; justify-content:space-between; gap:8px; }
.panel h2.spaced{ margin-top:22px; }

.upload-box{
  border:1.5px dashed var(--border); border-radius:10px; padding:18px 16px; text-align:center;
  background:var(--bg-light); margin-bottom:10px; cursor:pointer; transition:border-color .15s, background .15s; display:block;
}
.upload-box:hover{ border-color:var(--blue); background:#EAF1FD; }
.upload-box input[type=file]{ display:none; }
.upload-box .upload-icon{ color:var(--blue); margin-bottom:8px; }
.upload-box .upload-title{ font-size:13px; font-weight:600; color:var(--text); margin-bottom:2px; }
.upload-box .upload-sub{ font-size:11.5px; color:var(--muted); }
.upload-filename{ font-size:12px; color:var(--navy); font-weight:600; margin-top:8px; }

.parse-status{ font-size:12px; border-radius:8px; padding:10px 12px; margin-bottom:16px; line-height:1.5; display:none; }
.parse-status.ok{ background:#E9F8EF; border:1px solid #BEE8CE; color:#0F7A4A; display:block; }
.parse-status.warn{ background:#FDF3DC; border:1px solid #F0DBA1; color:#92660B; display:block; }
.parse-status.err{ background:#FDEEEE; border:1px solid #F3C6C6; color:#9A2A2A; display:block; }
.parse-status.loading{ background:var(--bg-light); border:1px solid var(--border); color:var(--muted); display:block; }

.batch-row{ display:flex; justify-content:space-between; align-items:center; gap:10px; padding:9px 12px; border:1px solid var(--border); border-radius:8px; margin-bottom:6px; font-size:12.5px; }
.batch-row .nome{ font-weight:600; color:var(--text); }
.batch-row .comp{ color:var(--muted); font-size:11.5px; }
.batch-row .tag-ok{ color:var(--good); font-weight:600; font-size:11.5px; }
.batch-row .tag-err{ color:#9A2A2A; font-weight:600; font-size:11.5px; }
.batch-row .tag-neutro{ color:var(--muted); font-weight:600; font-size:11.5px; }

.field{ margin-bottom:16px; }
.field label{ display:block; font-size:13px; font-weight:600; color:var(--text); margin-bottom:6px; }
.field .hint{ font-size:11.5px; color:var(--muted); margin-top:5px; line-height:1.4; }
.field input, .field select, .field textarea{
  width:100%; padding:10px 12px; border:1px solid var(--border); border-radius:8px;
  font-family:'IBM Plex Sans', sans-serif; font-size:13.5px; color:var(--text);
  background:var(--bg-light); transition:border-color .15s, box-shadow .15s;
}
.field textarea{ resize:vertical; min-height:90px; line-height:1.5; }
.field input:focus, .field select:focus, .field textarea:focus{
  outline:none; border-color:var(--blue); box-shadow:0 0 0 3px rgba(29,95,209,0.12); background:#fff;
}
.field input.auto-filled{ border-color:#9FCDB0; background:#F1FBF5; }
.field input:disabled, .field select:disabled{ background:#EEF2F7; color:var(--muted); cursor:not-allowed; border-color:var(--border); }
.money-wrap{ position:relative; }
.money-wrap .prefix{ position:absolute; left:12px; top:50%; transform:translateY(-50%); color:var(--muted); font-size:14px; pointer-events:none; }
.money-wrap input{ padding-left:32px; }

.btn{ width:100%; padding:12px 16px; border:none; border-radius:8px; font-family:'IBM Plex Sans', sans-serif; font-size:14.5px; font-weight:600; cursor:pointer; transition:background .15s, transform .05s, opacity .15s; }
.btn-primary{ background:var(--blue); color:#fff; margin-top:6px; }
.btn-primary:hover{ background:var(--blue-deep); }
.btn-secondary{ background:var(--navy); color:#fff; margin-top:10px; }
.btn-secondary:hover{ opacity:.92; }
.btn:disabled{ background:#B9C6DC; cursor:not-allowed; }
.btn:active{ transform:translateY(1px); }

.error-msg{ background:#FDEEEE; border:1px solid #F3C6C6; color:#9A2A2A; font-size:12.5px; padding:9px 11px; border-radius:7px; margin-top:14px; line-height:1.4; display:none; }

.data-source-tag{ display:inline-flex; align-items:center; gap:5px; font-size:10.5px; font-weight:600; padding:3px 9px; border-radius:20px; background:#E9F8EF; color:var(--good); margin-left:8px; }
.data-source-tag.manual{ background:var(--bg-light); color:var(--muted); }

/* --- Preview / Report --- */
.report-shell{ background:var(--white); border:1px solid var(--border); border-radius:14px; overflow:hidden; }
.report-empty{ padding:80px 40px; text-align:center; color:var(--muted); }
.report-empty .icon{ width:56px;height:56px;margin:0 auto 18px; border-radius:50%; background:var(--bg-light); display:flex;align-items:center;justify-content:center; color:var(--blue); }
.report-empty h3{ font-family:'Source Serif 4', serif; color:var(--navy); font-size:18px; margin:0 0 8px; font-weight:600; }
.report-empty p{ font-size:13.5px; max-width:340px; margin:0 auto; line-height:1.5; }

#report{ display:none; }

.report-band{
  background:linear-gradient(120deg, var(--navy-deep) 0%, var(--blue-deep) 100%);
  color:#fff; padding:26px 32px; display:flex; justify-content:space-between; align-items:flex-start; gap:20px;
}
.report-band .eyebrow{ font-size:11.5px; letter-spacing:.3px; color:#BFD4F5; margin:0 0 8px; font-weight:500; }
.report-band h2{ font-family:'Source Serif 4', serif; font-size:23px; font-weight:600; margin:0 0 8px; }
.report-band .meta{ font-size:12.5px; color:#D6E4FA; }
.comp-badge{
  background:rgba(255,255,255,0.1); border:1px solid rgba(255,255,255,0.18); border-radius:10px;
  padding:10px 18px; text-align:center; flex-shrink:0;
}
.comp-badge .label{ font-size:10px; color:#BFD4F5; letter-spacing:.4px; margin-bottom:4px; }
.comp-badge .value{ font-family:'Source Serif 4', serif; font-size:19px; font-weight:600; color:#fff; }

.report-body{ padding:26px 32px 30px; }

.kpi-row{ display:grid; grid-template-columns:repeat(4,1fr); gap:16px; margin-bottom:26px; }
@media (max-width:900px){ .kpi-row{grid-template-columns:repeat(2,1fr);} }
@media (max-width:520px){ .kpi-row{grid-template-columns:1fr;} }
.kpi{ background:var(--white); border:1px solid var(--border); border-left:3px solid var(--blue); border-radius:9px; padding:16px 18px; }
.kpi.c-blue{ border-left-color:var(--blue); }
.kpi.c-green{ border-left-color:var(--good); }
.kpi.c-purple{ border-left-color:var(--purple); }
.kpi.c-indigo{ border-left-color:var(--indigo); }
.kpi .label{ font-size:10.5px; letter-spacing:.3px; color:var(--muted); font-weight:600; margin-bottom:8px; }
.kpi .value{ font-family:'Source Serif 4', serif; font-size:clamp(16px, 1.6vw, 22px); font-weight:600; color:var(--text); margin-bottom:4px; white-space:nowrap; }
.kpi.c-green .value{ color:var(--good); }
.kpi.c-purple .value{ color:var(--purple); }
.kpi.c-indigo .value{ color:var(--indigo); }
.kpi .sub{ font-size:11.5px; color:var(--muted); }

.section-title{ display:flex; align-items:center; gap:9px; font-size:13.5px; font-weight:600; color:var(--navy); margin:30px 0 14px; }
.section-title .bar{ width:4px; height:16px; background:var(--blue); border-radius:2px; display:inline-block; }

.table-wrap{ border:1px solid var(--border); border-radius:10px; overflow:hidden; margin-bottom:8px; }
.detail-table{ width:100%; border-collapse:collapse; font-size:13px; }
.detail-table thead th{
  text-align:left; font-size:10.5px; letter-spacing:.2px; color:var(--muted); font-weight:600;
  padding:11px 14px; background:var(--bg-light); border-bottom:1px solid var(--border);
}
.detail-table td{ padding:12px 14px; border-bottom:1px solid var(--border); color:var(--text); }
.detail-table tbody tr:last-child td{ border-bottom:none; }
.detail-table td.num{ text-align:right; font-variant-numeric:tabular-nums; }
.detail-table th.num{ text-align:right; }
.detail-table td.trib{ font-weight:600; }
.detail-table td.destino{ color:var(--muted); font-size:12.5px; }
.detail-table tfoot td{ padding:13px 14px; font-weight:700; background:var(--bg-light); border-top:2px solid var(--border); border-bottom:none; }

.badge{ display:inline-block; padding:3px 10px; border-radius:20px; font-size:11.5px; font-weight:600; }
.badge-purple{ background:#F1E9FE; color:var(--purple); }
.badge-blue{ background:#E5EEFC; color:var(--blue); }
.badge-green{ background:#E3F7EC; color:var(--good); }
.badge-amber{ background:#FDF3DC; color:var(--amber); }
.badge-teal{ background:#E1F5F1; color:var(--teal); }
.badge-indigo{ background:#E9EAFD; color:var(--indigo); }

.source-note{ font-size:11px; color:var(--muted); margin:0 0 22px; font-style:italic; }

.historico-chart-card{
  background:var(--white); border:1px solid var(--border); border-radius:14px;
  padding:20px 22px 14px; margin-bottom:26px;
}
.historico-chart-card svg{ width:100%; height:auto; display:block; }
.historico-tooltip-label{ font-family:'IBM Plex Sans', sans-serif; }

.faixa6-note{ font-size:11.5px; color:var(--muted); margin:0 0 20px; padding:10px 14px; background:var(--bg-light); border-radius:8px; }

.diag-callout{ background:var(--white); border:1px solid var(--border); border-left:4px solid var(--amber); border-radius:10px; padding:16px 20px; margin-bottom:8px; }
.diag-callout-title{ display:flex; align-items:center; gap:7px; font-size:13px; font-weight:700; color:var(--amber); margin:0 0 10px; }
.diag-callout ul{ margin:0; padding-left:18px; }
.diag-callout li{ font-size:12.5px; color:var(--text); line-height:1.55; margin-bottom:7px; }
.diag-callout li:last-child{ margin-bottom:0; }
.diag-callout li strong{ color:var(--navy); }

.report-footer{
  border-top:1px solid var(--border); padding:16px 32px; display:flex; justify-content:space-between;
  align-items:center; gap:12px; font-size:11px; color:var(--muted); background:var(--bg-page); flex-wrap:wrap;
}

[hidden]{ display:none !important; }

/* ---- Login / acesso ---- */
.auth-screen{ position:fixed; inset:0; z-index:2000; display:flex; flex-wrap:wrap; align-content:flex-start; background:var(--bg-page); overflow-y:auto; }
.auth-marca{
  flex:1 1 560px; min-width:0; min-height:100vh; box-sizing:border-box; position:relative; overflow:hidden;
  background:var(--navy-deep); color:#fff; padding:48px 64px; display:flex; flex-direction:column; justify-content:space-between; gap:48px;
}
.auth-brand{ display:flex; align-items:center; gap:12px; }
.auth-brand img{ width:40px; height:40px; border-radius:10px; display:block; }
.auth-brand .n{ font-family:'Source Serif 4', serif; font-size:18px; font-weight:600; color:#fff; line-height:1.2; }
.auth-brand .t{ font-size:12px; color:#9FB6DD; }
.auth-copy{ display:flex; flex-direction:column; gap:26px; max-width:520px; position:relative; z-index:1; }
.auth-headline{ margin:0; font-family:'Source Serif 4', serif; font-size:42px; line-height:1.15; font-weight:500; letter-spacing:-.5px; }
.auth-lead{ margin:0; font-size:16px; line-height:1.6; color:#C9D9F2; }
.auth-beneficios{ display:flex; flex-direction:column; gap:16px; }
.auth-beneficio{ display:flex; gap:14px; align-items:flex-start; }
.auth-beneficio .ic{ width:36px; height:36px; border-radius:9px; background:rgba(255,255,255,.08); color:#8FB4F0; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.auth-beneficio .b-t{ font-weight:600; font-size:14.5px; }
.auth-beneficio .b-s{ font-size:13.5px; color:#9FB6DD; line-height:1.5; }
.auth-rodape{ font-size:12px; color:#7F97C2; position:relative; z-index:1; }
.auth-mini{
  position:absolute; right:-60px; bottom:120px; width:300px; background:#fff; border-radius:12px; overflow:hidden;
  box-shadow:0 30px 60px rgba(0,0,0,.35); transform:rotate(-6deg); color:var(--text);
}
.auth-mini .m-topo{ background:var(--blue-deep); padding:14px 16px; }
.auth-mini .m-eyebrow{ font-size:7px; letter-spacing:.4px; color:#BFD4F5; }
.auth-mini .m-nome{ font-size:12px; font-weight:600; color:#fff; margin-top:4px; }
.auth-mini .m-kpis{ padding:12px 14px; display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:8px; }
.auth-mini .m-kpi{ border:1px solid var(--border); border-left:3px solid var(--blue); border-radius:6px; padding:7px 8px; }
.auth-mini .m-kpi.verde{ border-left-color:var(--good); }
.auth-mini .m-kpi .l{ font-size:6px; color:var(--muted); }
.auth-mini .m-kpi .v{ font-size:10px; font-weight:600; }
.auth-mini .m-kpi.verde .v{ color:var(--good); }
.auth-mini .m-barras{ padding:0 14px 14px; display:flex; align-items:flex-end; gap:6px; height:56px; }
.auth-mini .m-barras i{ flex:1; background:var(--blue); border-radius:2px; }
.auth-form-lado{ flex:1 1 480px; min-width:0; min-height:100vh; box-sizing:border-box; display:flex; align-items:center; justify-content:center; padding:48px 32px; }
.auth-card{ width:100%; max-width:380px; }
.auth-titulo{ margin:0 0 6px; font-family:'Source Serif 4', serif; font-size:28px; font-weight:600; color:var(--navy); }
.auth-card p.sub{ font-size:14px; color:var(--muted); margin:0 0 24px; line-height:1.5; }
.auth-card .field{ margin-bottom:18px; }
.auth-card .field input{ height:46px; padding:0 14px; border:1px solid #C9D6EA; border-radius:10px; font-size:15px; background:#fff; }
.auth-label-linha{ display:flex; justify-content:space-between; align-items:baseline; margin-bottom:6px; }
.auth-label-linha label{ margin:0 !important; }
.auth-label-linha .btn-link{ font-size:13px; font-weight:500; }
.senha-wrap{ position:relative; }
.senha-wrap input{ padding-right:50px !important; }
.ver-senha{ position:absolute; right:2px; top:1px; width:44px; height:44px; border:none; background:none; color:var(--muted); cursor:pointer; display:flex; align-items:center; justify-content:center; border-radius:8px; }
.ver-senha:hover, .ver-senha[aria-pressed="true"]{ color:var(--blue); }
.auth-entrar{ height:48px; border-radius:10px; font-size:15px; margin-top:4px; }
.auth-nota{ display:flex; gap:10px; align-items:flex-start; margin-top:24px; padding:14px 16px; border-radius:10px; background:#fff; border:1px solid var(--border); color:var(--muted); }
.auth-nota svg{ flex-shrink:0; margin-top:1px; }
.auth-nota p{ margin:0; font-size:13px; line-height:1.5; }
.auth-nota a{ color:var(--blue); font-weight:500; word-break:break-word; }
.auth-msg{ font-size:12.5px; border-radius:8px; padding:9px 11px; margin-bottom:16px; line-height:1.45; }
.auth-msg.err{ background:#FDEEEE; border:1px solid #F3C6C6; color:#9A2A2A; }
.auth-msg.ok{ background:#E9F8EF; border:1px solid #BEE8CE; color:#0F7A4A; }
@media (max-width:1100px){ .auth-mini{ display:none; } }
@media (max-width:900px){
  .auth-marca{ min-height:0; padding:24px 20px; gap:0; }
  .auth-copy, .auth-rodape{ display:none; }
  .auth-form-lado{ min-height:0; padding:32px 20px 48px; align-items:flex-start; }
}

/* ---- Usuário e escritório na barra lateral ---- */
.sidebar-footer{ margin-top:auto; padding-top:16px; border-top:1px solid rgba(255,255,255,0.12); }
.esc-picker label{ display:block; font-size:10.5px; color:#9FB6DD; margin:0 0 5px 4px; letter-spacing:.3px; }
.esc-picker select{
  width:100%; padding:8px 10px; border-radius:8px; border:1px solid rgba(255,255,255,0.18);
  background:rgba(255,255,255,0.08); color:#fff; font-family:inherit; font-size:12.5px; margin-bottom:12px;
}
.esc-picker select option{ color:#152238; }
.user-box{ display:flex; align-items:center; gap:10px; padding:4px; }
.user-avatar{
  width:32px; height:32px; border-radius:50%; background:rgba(255,255,255,0.14); color:#fff; flex-shrink:0;
  display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:600;
}
.user-info{ min-width:0; flex:1; }
.user-info .un{ color:#fff; font-size:12.5px; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.user-info .ue{ color:#9FB6DD; font-size:11px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.btn-sair{
  background:none; border:1px solid rgba(255,255,255,0.2); color:#C9D9F2; border-radius:7px;
  padding:5px 9px; font-size:11.5px; cursor:pointer; font-family:inherit; flex-shrink:0;
}
.btn-sair:hover{ color:#fff; border-color:rgba(255,255,255,0.4); }
@media (max-width:900px){
  .sidebar-footer{ margin:0 0 0 auto; padding:0 0 0 14px; border-top:none; border-left:1px solid rgba(255,255,255,0.12); display:flex; align-items:center; gap:10px; }
  .esc-picker label, .user-info{ display:none; }
  .esc-picker select{ margin:0; width:auto; max-width:160px; }
}

/* ---- Administração ---- */
.admin-tabs{ display:flex; gap:4px; margin-bottom:16px; border-bottom:1px solid var(--border); }
.admin-tab{
  background:none; border:none; padding:10px 14px; font-family:inherit; font-size:13.5px; font-weight:600;
  color:var(--muted); cursor:pointer; border-bottom:2px solid transparent; margin-bottom:-1px;
}
.admin-tab.active{ color:var(--blue); border-bottom-color:var(--blue); }
.admin-toolbar{ display:flex; justify-content:space-between; align-items:center; gap:12px; flex-wrap:wrap; margin-bottom:14px; }
.admin-toolbar select, .admin-toolbar input{
  padding:8px 10px; border:1px solid var(--border); border-radius:8px; font-family:inherit; font-size:13px; background:#fff; color:var(--text);
}
.table-scroll{ overflow-x:auto; }
.status-off{ background:#FDEEEE; color:#9A2A2A; }
.status-muted{ background:#EEF2F7; color:var(--muted); font-weight:500; }
.acoes-cel{ display:flex; gap:6px; justify-content:flex-end; flex-wrap:nowrap; }
.btn-mini-ghost{ background:var(--bg-light); color:var(--navy); }
.modal-box{ max-width:460px; max-height:calc(100vh - 40px); overflow-y:auto; }
.modal-box h3{ font-family:'Source Serif 4', serif; font-size:17px; color:var(--navy); margin:0 0 16px; font-weight:600; }
.field label.check-inline{ display:flex; align-items:center; gap:8px; font-weight:500; font-size:12.5px; margin:8px 0 0; }
.field label.check-inline input{ width:auto; padding:0; }
.toast{
  position:fixed; bottom:20px; left:50%; transform:translateX(-50%); background:var(--navy-deep); color:#fff;
  padding:11px 16px; border-radius:9px; font-size:13px; z-index:3000; box-shadow:0 10px 28px rgba(0,0,0,.25); max-width:90vw;
}

/* ---- Personalização do relatório ---- */
.logo-drop{ display:flex; gap:14px; align-items:center; }
.logo-prev{
  width:150px; height:68px; border:1px dashed var(--border); border-radius:10px; background:var(--bg-light);
  display:flex; align-items:center; justify-content:center; text-align:center; color:var(--muted); font-size:11px; line-height:1.4; flex-shrink:0; overflow:hidden;
}
.logo-prev img{ max-width:134px; max-height:56px; display:block; }
.logo-prev:has(img){ background:#fff; border-style:solid; }
.logo-acoes{ display:flex; flex-direction:column; gap:6px; align-items:flex-start; }
.cor-linha{ display:flex; align-items:center; gap:12px; flex-wrap:wrap; }
.field input[type=color]{ width:48px; height:40px; padding:3px; cursor:pointer; flex-shrink:0; }
.swatches{ display:flex; gap:7px; flex-wrap:wrap; }
.swatch{ width:26px; height:26px; border-radius:50%; border:2px solid #fff; box-shadow:0 0 0 1px var(--border); cursor:pointer; padding:0; }
.swatch.ativo{ box-shadow:0 0 0 2px var(--text); }
.report-band.marca{ background:var(--band-bg) !important; color:var(--band-text) !important; }
.report-band.marca .eyebrow, .report-band.marca .meta, .report-band.marca .comp-badge .label{ color:var(--band-soft) !important; }
.report-band.marca .comp-badge{ background:var(--band-box) !important; border-color:transparent !important; }
.report-band.marca .comp-badge .value{ color:var(--band-text) !important; }
.report-band .band-esq{ display:flex; align-items:center; gap:22px; min-width:0; }
.report-band .band-txt{ min-width:0; }
.report-band .band-txt .meta{ margin-bottom:0; }
.report-band .band-logo.custom{ width:auto; height:auto; max-width:180px; max-height:64px; background:#fff; padding:8px 10px; border-radius:8px; box-sizing:content-box; margin:0; flex-shrink:0; }
@media (max-width:640px){ .report-band .band-esq{ flex-direction:column; align-items:flex-start; gap:14px; } }
.marca-dest .section-title .bar{ background:var(--band-dest) !important; }
#repFooterMsg{ flex-basis:100%; font-style:italic; }
#repFooterMsg:empty, #repFooterContato:empty{ display:none; }

/* ---- Acabamento: carregamento, avisos ---- */
.sk{
  display:inline-block; height:11px; border-radius:6px; vertical-align:middle;
  background:linear-gradient(90deg, #E6ECF5 25%, #F2F5FA 37%, #E6ECF5 63%); background-size:400% 100%;
  animation:sk-brilho 1.3s ease infinite;
}
.sk-num{ width:52px; height:22px; }
.sk-card{ display:block; width:100%; height:66px; border-radius:12px; margin-bottom:12px; }
@keyframes sk-brilho{ 0%{ background-position:100% 50%; } 100%{ background-position:0 50%; } }
.auth-carregando{ display:flex; align-items:center; gap:12px; font-size:13.5px; color:var(--muted); }
.spinner{ width:20px; height:20px; border-radius:50%; border:2.5px solid var(--border); border-top-color:var(--blue); animation:girar .8s linear infinite; flex-shrink:0; }
@keyframes girar{ to{ transform:rotate(360deg); } }
.aviso-box{ max-width:400px; }
.aviso-box h3{ display:flex; align-items:center; gap:9px; font-family:'Source Serif 4', serif; font-size:17px; color:var(--navy); margin:0 0 10px; font-weight:600; }
.aviso-box h3 svg{ color:var(--amber); flex-shrink:0; }
.diag-callout-title svg{ flex-shrink:0; }
@media (prefers-reduced-motion: reduce){ .sk, .spinner{ animation:none; } }

/* ---- Barra lateral: item ativo ---- */
.nav-item.active{ box-shadow:inset 3px 0 0 #6FA0F5; }

/* ---- Visão geral ---- */
.sr-only{ position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
[data-view="geral"].view.active{ display:flex; flex-direction:column; gap:24px; }
.vg-topo{ display:flex; justify-content:space-between; align-items:flex-end; gap:16px; flex-wrap:wrap; }
.vg-saudacao{ margin:0 0 6px; font-size:13px; color:var(--muted); min-height:1em; }
.vg-titulo{ margin:0; font-family:'Source Serif 4', serif; font-size:28px; font-weight:600; color:var(--navy); }
.vg-acoes{ display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
.vg-acoes label{ font-size:13px; color:var(--muted); }
.vg-acoes select{ height:42px; padding:0 12px; border:1px solid #C9D6EA; border-radius:9px; background:#fff; font-family:inherit; font-size:14px; color:var(--text); }
.vg-btn-primario{ height:42px; padding:0 18px; border:none; border-radius:9px; background:var(--blue); color:#fff; font-family:inherit; font-size:14px; font-weight:600; cursor:pointer; display:inline-flex; align-items:center; gap:8px; }
.vg-btn-primario:hover{ background:var(--blue-deep); }
.vg-hero{ background:var(--navy-deep); color:#fff; border-radius:16px; padding:28px 32px; display:flex; flex-wrap:wrap; gap:28px; align-items:center; justify-content:space-between; }
.vg-hero-info{ flex:1 1 420px; min-width:0; display:flex; flex-direction:column; gap:14px; }
.vg-hero h2{ margin:0; font-size:13px; font-weight:500; color:#9FB6DD; letter-spacing:.3px; }
.vg-hero-num{ display:flex; align-items:baseline; gap:10px; flex-wrap:wrap; font-size:16px; color:#C9D9F2; }
.vg-hero-num .big{ font-family:'Source Serif 4', serif; font-size:44px; font-weight:600; line-height:1; color:#fff; }
.vg-barra{ height:10px; border-radius:6px; background:rgba(255,255,255,.12); overflow:hidden; }
.vg-barra div{ height:100%; width:0; background:#6FA0F5; border-radius:6px; transition:width .5s ease; }
.vg-hero p{ margin:0; font-size:13.5px; color:#C9D9F2; }
.vg-hero-acoes{ display:flex; gap:10px; flex-wrap:wrap; }
.vg-btn-claro, .vg-btn-contorno{ height:44px; padding:0 18px; border-radius:9px; font-family:inherit; font-size:14px; font-weight:600; cursor:pointer; }
.vg-btn-claro{ background:#fff; color:var(--navy-deep); border:none; }
.vg-btn-contorno{ background:none; color:#fff; border:1px solid rgba(255,255,255,.3); }
.vg-btn-contorno:hover{ border-color:rgba(255,255,255,.6); }
.vg-kpis{ display:grid; grid-template-columns:repeat(auto-fit, minmax(220px, 1fr)); gap:16px; }
.vg-kpi{ background:#fff; border:1px solid var(--border); border-radius:14px; padding:20px 22px; display:flex; flex-direction:column; gap:10px; }
.vg-kpi .l{ font-size:12.5px; color:var(--muted); }
.vg-kpi .v{ font-family:'Source Serif 4', serif; font-size:26px; font-weight:600; color:var(--text); line-height:1.1; white-space:nowrap; }
.vg-kpi .r{ display:flex; justify-content:space-between; align-items:flex-end; gap:8px; min-height:28px; color:var(--blue); }
.vg-kpi .s{ font-size:12px; font-weight:600; color:var(--muted); }
.vg-kpi .sk-bloco{ height:96px; }
.vg-colunas{ display:flex; flex-wrap:wrap; gap:20px; align-items:flex-start; }
.vg-card{ background:#fff; border:1px solid var(--border); border-radius:14px; padding:22px 24px; min-width:0; box-sizing:border-box; }
.vg-pend{ flex:1 1 320px; scroll-margin-top:20px; }
.vg-ult{ flex:2 1 520px; }
.vg-card-topo{ display:flex; justify-content:space-between; align-items:center; gap:10px; margin-bottom:12px; }
.vg-card-topo h2{ margin:0; font-family:'Source Serif 4', serif; font-size:17px; font-weight:600; color:var(--text); }
.vg-tag{ font-size:12px; font-weight:600; padding:4px 10px; border-radius:20px; white-space:nowrap; }
.vg-tag.pend{ background:#FDF3DC; color:var(--amber); }
.vg-tag.ok{ background:#E3F7EC; color:var(--good); }
.vg-lista{ list-style:none; margin:0; padding:0; max-height:420px; overflow-y:auto; }
.vg-lista li{ display:flex; justify-content:space-between; align-items:center; gap:10px; padding:11px 0; border-top:1px solid #EEF2F8; }
.vg-lista li.vazio{ color:var(--muted); font-size:13px; justify-content:flex-start; }
.vg-lista .info{ min-width:0; }
.vg-lista .n{ font-size:13.5px; font-weight:600; }
.vg-lista .d{ font-size:12px; color:var(--muted); }
.vg-tabela-wrap{ overflow-x:auto; position:relative; }
.vg-tabela{ width:100%; border-collapse:collapse; font-size:13.5px; min-width:520px; }
.vg-tabela th{ text-align:left; font-size:11px; font-weight:600; color:var(--muted); letter-spacing:.3px; text-transform:uppercase; padding:10px 8px; border-bottom:1px solid var(--border); }
.vg-tabela td{ padding:12px 8px; border-bottom:1px solid #EEF2F8; vertical-align:middle; }
.vg-tabela tbody tr:last-child td{ border-bottom:none; }
.vg-tabela .num{ text-align:right; font-variant-numeric:tabular-nums; white-space:nowrap; }
.vg-tabela .n{ font-weight:600; }
.vg-tabela .d{ font-size:12px; color:var(--muted); }
.vg-tabela .var{ font-weight:600; }
.vg-tabela .var.sobe{ color:var(--good); }
.vg-tabela .var.desce{ color:#B42318; }
.vg-tabela .var.neutro{ color:var(--muted); font-weight:400; }
.vg-tabela td.acao{ text-align:right; width:44px; }
.vg-icone{ width:36px; height:36px; border:1px solid var(--border); border-radius:8px; background:#fff; color:var(--navy); cursor:pointer; display:inline-flex; align-items:center; justify-content:center; }
.vg-icone:hover{ border-color:var(--blue); color:var(--blue); }
.vg-vazio{ padding:28px 8px; text-align:center; color:var(--muted); font-size:13px; }

/* ---- Criar senha ---- */
.senha-regras{ list-style:none; margin:2px 0 20px; padding:0; display:grid; gap:7px; }
.senha-regras li{ display:flex; align-items:center; gap:9px; font-size:13px; color:var(--muted); }
.senha-regras li::before{
  content:''; width:16px; height:16px; border-radius:50%; border:1.5px solid #B9C6DC; flex-shrink:0; box-sizing:border-box;
}
.senha-regras li.ok{ color:var(--good); }
.senha-regras li.ok::before{
  border-color:var(--good); background:var(--good) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/11px no-repeat;
}
.auth-links{ margin-top:18px; text-align:center; }

.actions-row{ display:flex; gap:10px; margin-top:18px; }
.actions-row .btn{ margin-top:0; }

/* ---- Clientes: busca, filtros e ações ---- */
.cli-filtros{ display:flex; flex-wrap:wrap; gap:10px; align-items:flex-end; margin-bottom:12px; }
.cli-busca{ flex:1 1 280px; position:relative; min-width:0; }
.cli-busca svg{ position:absolute; left:12px; top:50%; transform:translateY(-50%); color:var(--muted); pointer-events:none; }
.cli-busca input{ width:100%; height:40px; padding:0 12px 0 36px; border:1px solid var(--border); border-radius:9px; font-family:inherit; font-size:13.5px; background:#fff; color:var(--text); }
.cli-busca input:focus, .cli-filtro select:focus{ outline:none; border-color:var(--blue); box-shadow:0 0 0 3px rgba(29,95,209,0.12); }
.cli-filtro{ display:flex; flex-direction:column; gap:4px; }
.cli-filtro span{ font-size:11.5px; font-weight:600; color:var(--muted); }
.cli-filtro select{ height:40px; padding:0 10px; border:1px solid var(--border); border-radius:9px; font-family:inherit; font-size:13px; background:#fff; color:var(--text); min-width:150px; }
.cli-lixeira-btn{ height:40px; display:inline-flex; align-items:center; gap:7px; }
.cli-acoes{ display:flex; justify-content:space-between; align-items:center; flex-wrap:wrap; gap:12px; margin-bottom:16px; }
.cli-selecao{ display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.cli-selecao .sep{ color:var(--border); }
.cli-contagem{ font-size:12.5px; color:var(--muted); margin-left:6px; }
.cli-botoes{ display:flex; gap:10px; flex-wrap:wrap; }
.cli-botoes .btn{ width:auto; padding:10px 18px; margin-top:0; }
.btn-perigo{ background:#FDEEEE; color:#9A2A2A; }
.btn-perigo:hover{ background:#FADADA; }
.tag-sem-mov{ display:inline-block; margin-left:6px; padding:2px 8px; border-radius:20px; background:#EEF2F7; color:var(--muted); font-size:10.5px; font-weight:600; vertical-align:middle; white-space:nowrap; }
@media (max-width:640px){
  .cli-filtro{ flex:1 1 140px; }
  .cli-filtro select{ min-width:0; width:100%; }
  .cli-botoes, .cli-botoes .btn{ width:100%; }
}

/* ---- Lixeira ---- */
.lx-voltar{ display:inline-block; margin-bottom:10px; }
.lx-topo{ display:flex; justify-content:flex-end; margin:-8px 0 12px; }

/* ---- Termos de uso e privacidade ---- */
.auth-card.largo{ max-width:560px; }
.termos-texto{ max-height:46vh; overflow-y:auto; border:1px solid var(--border); border-radius:10px; background:#fff; padding:16px 18px; font-size:13px; line-height:1.6; color:var(--text); margin-bottom:16px; }
.termos-texto h4{ font-size:13.5px; color:var(--navy); margin:14px 0 4px; }
.termos-texto h4:first-of-type{ margin-top:4px; }
.termos-texto p{ margin:0 0 8px; }
.termos-versao{ font-size:11.5px; color:var(--muted); }
.termos-check{ display:flex; gap:10px; align-items:flex-start; font-size:13.5px; color:var(--text); margin-bottom:14px; cursor:pointer; line-height:1.45; }
.termos-check input{ width:18px; height:18px; margin-top:1px; flex-shrink:0; accent-color:var(--blue); }
.termos-leitura{ max-width:640px; }
.termos-leitura h3{ font-family:'Source Serif 4', serif; font-size:18px; color:var(--navy); margin:0 0 12px; font-weight:600; }
.termos-leitura .termos-texto{ max-height:62vh; margin-bottom:0; }
.link-termos{ display:block; width:100%; background:none; border:none; padding:10px 4px 0; text-align:left; color:#9FB6DD; font-family:inherit; font-size:11.5px; cursor:pointer; }
.link-termos:hover{ color:#fff; text-decoration:underline; }
@media (max-width:900px){ .link-termos{ display:none; } }

/* ---- Janelas sobrepostas: confirmação e avisos ficam por cima de formulários ---- */
#termosLeituraOverlay, #atividadeOverlay, #formOverlay{ z-index:1000; }
#confirmOverlay{ z-index:1100; }
#avisoOverlay{ z-index:1200; }
.atividade-corpo{ max-height:60vh; overflow-y:auto; }
.aviso-perigo{ background:#FDEEEE; border:1px solid #F3C6C6; color:#7A2020; border-radius:8px; padding:11px 13px; font-size:13px; line-height:1.5; margin-bottom:16px; }
.batch-row .comp{ line-height:1.45; }
/* Cartões do relatório na tela: quebram de linha em vez de cortar o valor */
.report-body .kpi-row{ grid-template-columns:repeat(auto-fit, minmax(150px, 1fr)); }
.report-body .kpi .value{ font-size:clamp(16px, 1.4vw, 21px); }

/* Abertura da página e conferência do acesso: tela neutra só com o aviso de carregamento */
.auth-screen.so-carregando .auth-marca{ display:none; }
.auth-screen.so-carregando .auth-form-lado{ flex:1 1 100%; min-height:100vh; align-items:center; justify-content:center; }
.auth-screen.so-carregando .auth-card{ max-width:none; width:auto; }

/* =====================================================================
   v1.5 — Menu lateral, Clientes, painel do cliente e Administração
   ===================================================================== */

/* ---- Menu lateral ---- */
.sidebar{ gap:2px; overflow-y:auto; }
button.nav-item{ width:100%; border:none; background:none; font-family:inherit; text-align:left; min-height:42px; }
.nav-item .nav-txt{ flex:1; }
.nav-cont{ font-size:11.5px; background:rgba(255,255,255,0.16); color:#fff; border-radius:10px; padding:1px 8px; font-weight:600; }
.nav-alerta{ font-size:11px; font-weight:700; color:#0C1E3D; background:#F5C04A; border-radius:10px; padding:1px 7px; }
.nav-grupo{ font-size:10.5px; letter-spacing:.6px; color:#8EA6CF; padding:14px 12px 4px; font-weight:600; }
.esc-picker{ margin:2px 0 6px; }
.esc-picker label{ display:block; font-size:10.5px; letter-spacing:.5px; color:#9FB6DD; margin:0 0 5px 4px; font-weight:600; }
.esc-picker select{ width:100%; padding:10px 10px; border-radius:10px; border:1px solid rgba(255,255,255,0.18); background:rgba(255,255,255,0.08); color:#fff; font-family:inherit; font-size:13.5px; font-weight:600; min-height:44px; margin:0; }
.esc-picker select option{ color:#152238; }
.btn-importar{ margin:8px 0 4px; width:100%; display:flex; align-items:center; justify-content:center; gap:8px; background:#1D5FD1 !important; color:#fff !important; border:none; border-radius:10px; min-height:44px; font-family:inherit; font-size:14px; font-weight:600; cursor:pointer; box-shadow:none !important; }
.btn-importar:hover{ background:#123E8F !important; }
.btn-importar.active{ box-shadow:0 0 0 2px #6FA0F5 !important; }
.sidebar-footer{ margin-top:auto; padding-top:16px; }
.sidebar-versao{ font-size:11px; color:#8EA6CF; padding:10px 4px 0; }
.sidebar-versao .link-termos{ display:inline; width:auto; padding:0; color:#C9D9F2; font-size:11px; text-decoration:underline; }
@media (max-width:900px){
  .sidebar{ gap:6px; }
  .nav-grupo{ display:none; }
  #navAdmin{ display:contents; }
  #navAdmin[hidden]{ display:none; }
  .esc-picker{ margin:0; flex-shrink:0; }
  .esc-picker label{ display:none; }
  .esc-picker select{ min-height:38px; padding:6px 8px; max-width:180px; }
  .btn-importar{ width:auto; margin:0; padding:0 14px; flex-shrink:0; white-space:nowrap; min-height:38px; }
  button.nav-item{ width:auto; flex-shrink:0; }
  .sidebar-footer{ margin:0 0 0 auto; padding:0 0 0 14px; }
  .sidebar-versao{ display:none; }
}

/* ---- Faixa do modo administrador ---- */
.modo-admin{ display:flex; align-items:center; gap:12px; flex-wrap:wrap; background:#FDF3DC; border:1px solid #F0DBA1; color:#5C3F05; border-radius:10px; padding:10px 14px; font-size:13px; margin:-8px 0 22px; }
.modo-admin[hidden]{ display:none; }
.modo-admin-txt{ flex:1; min-width:240px; }
.modo-admin-btn{ background:#fff; border:1px solid #E5C77A; color:#5C3F05; border-radius:8px; padding:6px 12px; font-family:inherit; font-size:12.5px; font-weight:600; cursor:pointer; min-height:34px; }

/* ---- Botões das telas novas ---- */
.cli-bt{ display:inline-flex; align-items:center; justify-content:center; gap:7px; background:#fff; color:#0A2E5C; border:1px solid #C9D6EA; border-radius:9px; padding:0 14px; min-height:38px; font-family:inherit; font-size:13px; font-weight:600; cursor:pointer; white-space:nowrap; }
.cli-bt:hover:not(:disabled){ border-color:#1D5FD1; }
.cli-bt-azul{ background:#1D5FD1; color:#fff; border-color:#1D5FD1; }
.cli-bt-azul:hover:not(:disabled){ background:#123E8F; border-color:#123E8F; }
.cli-bt-perigo{ color:#9A2A2A; border-color:#E3A7A7; }
.cli-bt-perigo:hover:not(:disabled){ border-color:#9A2A2A; background:#FDF4F4; }
.cli-bt:disabled{ opacity:.45; cursor:not-allowed; }
.chip{ display:inline-flex; align-items:center; gap:6px; padding:3px 10px; border-radius:20px; font-size:12px; font-weight:600; white-space:nowrap; }
.chip-ok{ background:#E3F7EC; color:#0B6B40; }
.chip-neutro{ background:#EEF2F7; color:#3D4C66; }
.chip-alerta{ background:#FDF3DC; color:#6B4A06; }
.chip-perigo{ background:#FDEEEE; color:#9A2A2A; }
.chip-info{ background:#E5EEFC; color:#123E8F; }

/* ---- Clientes ---- */
.cli-topo{ display:flex; justify-content:space-between; align-items:flex-end; gap:16px; flex-wrap:wrap; margin-bottom:18px; }
.cli-topo-acoes{ display:flex; gap:8px; flex-wrap:wrap; }
.cli-barra{ display:flex; flex-wrap:wrap; gap:10px; align-items:center; margin-bottom:14px; }
.cli-barra select{ height:40px; padding:0 10px; border:1px solid #C9D6EA; border-radius:9px; font-family:inherit; font-size:13.5px; font-weight:600; color:#152238; background:#fff; min-width:190px; }
.cli-busca{ flex:1 1 260px; position:relative; display:block; min-width:0; }
.cli-busca svg{ position:absolute; left:12px; top:50%; transform:translateY(-50%); color:#5B6B85; pointer-events:none; }
.cli-busca input{ width:100%; box-sizing:border-box; height:40px; padding:0 12px 0 36px; border:1px solid #C9D6EA; border-radius:9px; font-family:inherit; font-size:13.5px; background:#fff; color:#152238; }
.cli-busca input:focus, .cli-barra select:focus{ outline:none; border-color:#1D5FD1; box-shadow:0 0 0 3px rgba(29,95,209,0.12); }
.seg{ display:inline-flex; flex-wrap:wrap; background:#E9EFF8; border-radius:10px; padding:3px; gap:2px; }
.seg button{ border:none; background:none; color:#3D4C66; font-family:inherit; font-size:13px; font-weight:500; border-radius:8px; padding:0 12px; min-height:34px; cursor:pointer; }
.seg button[aria-pressed="true"]{ background:#fff; color:#0A2E5C; font-weight:600; box-shadow:0 1px 2px rgba(12,30,61,0.12); }
.cli-card{ background:#fff; border:1px solid #DCE6F5; border-radius:14px; overflow:hidden; }
.cli-card-topo{ display:flex; align-items:center; gap:12px; flex-wrap:wrap; padding:10px 12px; background:#F8FAFD; border-bottom:1px solid #DCE6F5; }
.cli-sel-todos{ display:inline-flex; align-items:center; gap:10px; font-size:13.5px; font-weight:600; color:#152238; cursor:pointer; min-height:36px; padding:0 2px; }
.cli-sel-todos input, .cli-tabela input[type=checkbox]{ width:17px; height:17px; accent-color:#1D5FD1; margin:0; cursor:pointer; }
.cli-sel-cont{ font-size:13px; color:#5B6B85; border-left:1px solid #DCE6F5; padding-left:12px; }
.cli-tabela-wrap{ overflow-x:auto; position:relative; }
.cli-tabela{ width:100%; border-collapse:collapse; min-width:760px; }
.cli-tabela th{ text-align:left; font-size:11px; font-weight:600; letter-spacing:.3px; color:#5B6B85; text-transform:uppercase; padding:11px 12px; border-bottom:1px solid #DCE6F5; white-space:nowrap; }
.cli-tabela td{ padding:12px; border-bottom:1px solid #EEF2F8; font-size:13.5px; vertical-align:middle; color:#152238; }
.cli-tabela tbody tr:last-child td{ border-bottom:none; }
.cli-tabela .num{ text-align:right; font-variant-numeric:tabular-nums; white-space:nowrap; }
.cli-tabela .col-sel{ width:36px; }
.cli-tabela .col-acao{ width:48px; }
.cli-tabela tr.sel{ background:#EEF4FE; }
.cli-nome{ background:none; border:none; padding:0; font-family:inherit; font-size:13.5px; font-weight:600; color:#152238; cursor:pointer; text-align:left; }
.cli-nome:hover{ color:#1D5FD1; text-decoration:underline; }
.cli-cnpj{ font-size:12px; color:#5B6B85; margin-top:2px; }
.cli-sobe{ color:#0B6B40; font-weight:600; }
.cli-desce{ color:#B42318; font-weight:600; }
.cli-mudo{ color:#5B6B85; }
.btn-tres{ background:none; border:none; color:#3D4C66; min-width:36px; min-height:36px; border-radius:8px; cursor:pointer; display:inline-flex; align-items:center; justify-content:center; }
.btn-tres:hover, .btn-tres[aria-expanded="true"]{ background:#E1E9F6; color:#0A2E5C; }
.cli-vazio{ padding:40px 20px; text-align:center; color:#5B6B85; font-size:13.5px; line-height:1.6; }
.cli-rodape{ font-size:12.5px; color:#5B6B85; margin-top:10px; }
.menu-flutuante{ position:fixed; z-index:1500; width:250px; background:#fff; border:1px solid #DCE6F5; border-radius:12px; box-shadow:0 12px 32px rgba(12,30,61,0.18); padding:6px; }
.menu-flutuante[hidden]{ display:none; }
.menu-flutuante button{ display:block; width:100%; text-align:left; background:none; border:none; padding:10px 12px; border-radius:8px; font-family:inherit; font-size:13.5px; color:#152238; cursor:pointer; min-height:40px; }
.menu-flutuante button:hover, .menu-flutuante button:focus-visible{ background:#F1F6FD; outline:none; }
.menu-flutuante .menu-perigo{ color:#B42318; }
.menu-sep{ height:1px; background:#EEF2F8; margin:4px 6px; }

/* ---- Painel do cliente ---- */
.painel-fundo{ position:fixed; inset:0; background:rgba(12,30,61,0.38); z-index:900; }
.painel-fundo[hidden], .painel-cliente[hidden]{ display:none; }
.painel-cliente{ position:fixed; top:0; right:0; bottom:0; width:560px; max-width:100%; box-sizing:border-box; background:#fff; box-shadow:-16px 0 40px rgba(12,30,61,0.22); display:flex; flex-direction:column; z-index:950; }
.pc-topo{ padding:22px 24px 18px; border-bottom:1px solid #DCE6F5; display:flex; gap:12px; align-items:flex-start; }
.pc-topo-txt{ flex:1; min-width:0; }
.pc-eyebrow{ font-size:11.5px; font-weight:600; letter-spacing:.4px; color:#5B6B85; }
.pc-topo h2{ margin:2px 0 4px; font-family:'Source Serif 4', serif; font-size:22px; font-weight:600; color:#0A2E5C; overflow-wrap:anywhere; }
.pc-meta{ font-size:13px; color:#5B6B85; }
.pc-fechar{ background:#F1F6FD; border:none; color:#0A2E5C; min-width:40px; min-height:40px; border-radius:10px; cursor:pointer; display:inline-flex; align-items:center; justify-content:center; }
.pc-corpo{ flex:1; overflow-y:auto; padding:20px 24px 24px; display:flex; flex-direction:column; gap:20px; }
.pc-acoes{ display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.pc-acoes select{ height:40px; padding:0 10px; border:1px solid #C9D6EA; border-radius:9px; font-family:inherit; font-size:13.5px; font-weight:600; background:#fff; color:#152238; }
.pc-kpis{ display:grid; grid-template-columns:repeat(2, minmax(0, 1fr)); gap:10px; }
.pc-kpi{ border:1px solid #DCE6F5; border-radius:12px; padding:14px 16px; }
.pc-kpi .l{ font-size:12px; color:#5B6B85; }
.pc-kpi .v{ font-family:'Source Serif 4', serif; font-size:21px; font-weight:600; margin-top:4px; color:#152238; }
.pc-kpi .s{ font-size:12px; color:#5B6B85; margin-top:2px; }
.pc-kpi.alerta{ background:#FFF8E8; border-color:#F0DBA1; }
.pc-kpi.alerta .l, .pc-kpi.alerta .v, .pc-kpi.alerta .s{ color:#6B4A06; }
.pc-sec-t{ font-size:13.5px; font-weight:600; color:#0A2E5C; margin-bottom:10px; }
.pc-barras{ display:flex; align-items:flex-end; gap:6px; height:140px; padding:0 2px; border-bottom:1px solid #DCE6F5; }
.pc-barras .b{ flex:1; min-width:0; display:flex; justify-content:center; height:100%; align-items:flex-end; }
.pc-barras .b i{ display:block; width:100%; max-width:26px; border-radius:4px 4px 0 0; background:#9DBBEE; min-height:2px; }
.pc-barras .b.atual i{ background:#1D5FD1; }
.pc-meses{ display:flex; gap:6px; padding:6px 2px 0; }
.pc-meses span{ flex:1; min-width:0; text-align:center; font-size:10.5px; color:#5B6B85; }
.pc-meses span.atual{ color:#1D5FD1; font-weight:600; }
.pc-hist{ border:1px solid #DCE6F5; border-radius:12px; overflow:auto; max-height:320px; }
.pc-hist .cli-tabela{ min-width:0; }
.pc-hist tr.atual{ background:#EEF4FE; }
.pc-rodape{ margin-top:auto; padding-top:10px; border-top:1px solid #EEF2F8; font-size:12.5px; color:#5B6B85; display:flex; justify-content:space-between; gap:12px; flex-wrap:wrap; align-items:center; }
.pc-link-perigo{ background:none; border:none; color:#B42318; font-family:inherit; font-size:12.5px; font-weight:600; cursor:pointer; padding:0; min-height:32px; }
.pc-link-perigo:hover{ text-decoration:underline; }
body.painel-aberto{ overflow:hidden; }

/* ---- Administração ---- */
#admLista, #admEscritorio{ display:flex; flex-direction:column; gap:20px; max-width:1040px; }
#admLista[hidden], #admEscritorio[hidden]{ display:none; }
#admLista .cli-topo{ margin-bottom:0; }
.adm-aviso{ background:#FFF8E8; border:1px solid #F0DBA1; border-radius:12px; padding:12px 16px; display:flex; align-items:center; gap:12px; flex-wrap:wrap; color:#5C3F05; font-size:13.5px; }
.adm-aviso + .adm-aviso{ margin-top:8px; }
.adm-aviso .t{ flex:1; min-width:240px; }
.adm-aviso .cli-bt:not(.cli-bt-azul){ border-color:#E5C77A; color:#5C3F05; }
.adm-sec{ display:flex; flex-direction:column; gap:10px; }
.adm-sec-topo{ display:flex; justify-content:space-between; align-items:center; gap:12px; flex-wrap:wrap; }
.adm-sec h2, .adm-card h2{ margin:0; font-size:16px; font-weight:600; color:#0A2E5C; }
.adm-busca{ flex:0 1 300px; }
.adm-tabela{ min-width:720px; }
.adm-tabela .col-acao2{ width:110px; }
.adm-tabela td:last-child{ text-align:right; }
.adm-card{ background:#fff; border:1px solid #DCE6F5; border-radius:14px; padding:18px 22px; display:flex; flex-direction:column; gap:12px; }
.adm-sub{ margin:2px 0 0; font-size:12.5px; color:#5B6B85; }
.adm-pessoa{ display:flex; align-items:center; gap:12px; padding:12px 0; border-top:1px solid #EEF2F8; flex-wrap:wrap; }
.adm-pessoa:first-child{ border-top:none; padding-top:2px; }
.adm-avatar{ width:36px; height:36px; border-radius:50%; background:#E5EEFC; color:#123E8F; display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:600; flex-shrink:0; }
.adm-pessoa .info{ flex:1; min-width:200px; }
.adm-pessoa .n{ font-weight:600; font-size:14px; color:#152238; }
.adm-pessoa .acoes{ display:flex; gap:6px; flex-wrap:wrap; }
.adm-vazio{ font-size:13px; color:#5B6B85; padding:4px 0; }
.ae-voltar{ align-self:flex-start; min-height:32px; font-size:13px; }
.ae-topo p{ margin:6px 0 0; font-size:13.5px; color:#5B6B85; }
.ae-titulo{ display:flex; align-items:center; gap:12px; flex-wrap:wrap; }
.ae-titulo h1{ margin:0; font-family:'Source Serif 4', serif; font-size:26px; font-weight:600; color:#0A2E5C; }
.ae-validade{ margin:0; font-size:14px; color:#152238; }
.ae-renovar{ display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.ae-renovar > span{ font-size:13px; color:#3D4C66; margin-right:4px; }
.ae-linha{ display:flex; align-items:center; gap:14px; padding:14px 0; border-top:1px solid #EEF2F8; flex-wrap:wrap; }
.ae-linha > div{ flex:1; min-width:220px; }
.ae-l-t{ font-weight:600; font-size:14px; color:#152238; }
.ae-perigo{ color:#9A2A2A; }
