﻿  :root{
    --bg:#0b0f16; --panel:#0b1220; --muted:#9ca3af; --border:#1f2937;
    --fg:#e6edf3; --brand:#2563eb; --brand-b:#1d4ed8;
    --row-h:36px; --cell-py:6px; --cell-px:6px; --font-sm:13px; --font-xs:12px;
    --ok-bg:#052e16; --ok-fg:#86efac; --ok-b:#064e3b;
    --warn-bg:#3f1f09; --warn-fg:#fdba74; --warn-b:#7c2d12;
    --bad-bg:#3b0a0a; --bad-fg:#fca5a5; --bad-b:#7f1d1d;
  }

  *{ box-sizing:border-box }
  body{ font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Arial,sans-serif; margin:0; background:var(--bg); color:var(--fg) }
  header{ display:flex; gap:12px; align-items:center; padding:12px 16px; background:#111827; border-bottom:1px solid var(--border); position:sticky; top:0; z-index:10 }
  input,button,select,textarea{ font-size:14px; border-radius:8px; border:1px solid #374151; background:#0f172a; color:var(--fg); padding:8px 10px }
  button{ background:var(--brand); border-color:var(--brand-b); cursor:pointer }
  button:disabled{ opacity:.6; cursor:not-allowed }
  .wrap{ width:100%; max-width:min(1680px,96vw); margin:0 auto; padding:16px }
  .toolbar{ display:flex; gap:8px; align-items:center; margin:8px 0 16px; flex-wrap:wrap }
  .spacer{ flex:1 }
  .muted{ color:var(--muted) }
  .inline{ display:flex; gap:6px; align-items:center }
  .login-info{ display:none; gap:6px; align-items:center; font-size:13px; color:#e5e7eb }
  .login-info strong{ color:#fff; }
  .login-info .login-email{ color:#94a3b8; font-size:12px }

  /* ===== Tabela ===== */
  .table-wrap{ border:1px solid var(--border); border-radius:12px; background:var(--panel); overflow:auto }
  .table{ width:100%; table-layout:fixed; border-collapse:separate; border-spacing:0 }
  .table thead th{
    font-size:var(--font-xs); text-transform:uppercase; letter-spacing:.03em;
    color:#9ca3af; background:#0b1220; position:sticky; top:0;
    border-bottom:1px solid #1f2937; padding:6px var(--cell-px); text-align:center; white-space:nowrap;
  }
  .table thead th.sortable{ cursor:pointer; user-select:none; }
  .table thead th.sortable .sort-ico{ margin-left:6px; font-size:11px; color:var(--muted); }
  .table thead th.sortable.active-sort{ color:#e5e7eb; }
  .table thead th.sortable.active-sort .sort-ico{ color:#e5e7eb; }
  .table tbody td{
    font-size:var(--font-sm); padding:var(--cell-py) var(--cell-px);
    white-space:nowrap; overflow:hidden; text-overflow:ellipsis; vertical-align:middle;
    text-align:center;
    border-bottom:1px solid #101826;
  }
  .table tbody tr{ height:var(--row-h) }
  .table tbody tr:nth-child(even){
    background:#0d1626;
  }
  .table tbody tr:nth-child(even) .td-actions{
    background:#0d1626;
  }
  .table tbody tr:hover{ background:#101d33 }
  .table tbody tr:hover .td-actions{ background:#101d33; }
  .table tbody td.td-status{ overflow:visible; text-overflow:clip; }

  .status-with-hist{ display:flex; align-items:center; justify-content:center; gap:6px; }
  .btn-icon{ padding:2px 6px; border-radius:6px; font-size:12px; line-height:1.2; }
  .btn-icon.btn-ghost{ background:transparent; border-color:transparent; color:#cbd5e1; }
  .btn-icon.btn-ghost:hover{ border-color:#334155; background:#111827; }

  /* Coluna Ações sticky, compacta e sem “comer” a próxima */
  .col-actions,.td-actions{ width:122px; min-width:110px; text-align:center }
  .td-actions,.col-actions{ position:sticky; left:0; z-index:2; background:#0b1220 }
  .table thead th.col-actions{ z-index:4 }
  .td-actions{ box-shadow:none }
  .table tbody td.td-actions{ overflow:visible; text-overflow:initial; white-space:nowrap }
  .td-actions .btn-sm{ padding:2px 4px; line-height:1.1 }

  /* Larguras das demais colunas (enxutas para caber tudo sem rolagem) */
  .col-status,.td-status{ width:184px; min-width:0; text-align:center; padding-left:4px; padding-right:4px }
  .backup-status{ width:72px; min-width:68px; text-align:center; }
  .table tbody td.backup-status{ overflow:visible; text-overflow:clip; white-space:nowrap; }
  #backupReportTable{ width:100%; }
  #backupReportTable th{ width:133px; min-width:133px; }
  .backup-count{ width:70px; min-width:64px; text-align:center; }
  .backup-path{ max-width:150px; }
  #backupReportTable .col-actions,
  #backupReportTable .td-actions{ width:120px; min-width:110px; }
  .col-farol,.td-farol{ width:120px; min-width:0 }
  .col-veeam,.td-veeam{ width:70px; min-width:0; text-align:center }
  .col-agent,.td-agent{ width:218px; max-width:220px; min-width:0 }
  .col-clientsite,.td-clientsite{ width:200px; max-width:190px; min-width:0 }
  .col-lastseen,.td-lastseen{ width:150px; min-width:0 }
  .col-lastsync,.td-lastsync{ width:142px; min-width:0 }
  .col-result,.td-result{ width:auto; max-width:170px; min-width:0 }
  .col-upload,.td-upload{ width:100px; min-width:0 }
  .col-service,.td-service{ width:89px; min-width:0 }
  .col-agentver,.td-agentver{ width:auto; min-width:0 }

  @media (max-width:1150px){ .col-agentver,.td-agentver{ display:none } }
  @media (max-width:1050px){ .col-upload,.td-upload{ display:none } }
  @media (max-width:980px){ .col-result,.td-result{ display:none } }
  @media (max-width:900px){ .col-lastsync,.td-lastsync{ display:none } }
  @media (max-width:640px){
    header{ flex-wrap:wrap; justify-content:flex-start; }
    header > *{ flex:1 1 auto; }
    .wrap{ padding:12px 10px 24px; }
    .toolbar{ flex-direction:column; align-items:stretch; gap:12px; }
    .toolbar > div,
    .toolbar .inline,
    .toolbar input,
    .toolbar select,
    .toolbar button,
    #count{
      width:100%;
    }
    .toolbar .inline{ justify-content:space-between; }
    #count{ text-align:right; }
  }

  @media (max-width:720px){
    .table-wrap{
      border:none;
      background:transparent;
      padding-bottom:8px;
    }
    .table{
      width:100%;
      border-collapse:separate;
    }
    .table thead{ display:none; }
    .table tbody{
      display:flex;
      flex-direction:column;
      gap:12px;
    }
    .table tbody tr{
      display:flex;
      flex-direction:column;
      height:auto;
      border:1px solid var(--border);
      border-radius:12px;
      background:#0f172a;
      padding:12px;
      box-shadow:0 12px 20px rgba(2,6,23,0.45);
    }
    .table tbody tr:nth-child(even){
      background:#0f172a;
    }
    .table tbody td,
    .table tbody td.td-actions{
      position:relative;
      display:flex;
      flex-direction:column;
      align-items:flex-start;
      gap:4px;
      width:100%;
      text-align:left;
      white-space:normal;
      border-bottom:none;
      padding:0;
      background:transparent;
    }
    .table tbody td + td{
      margin-top:10px;
      padding-top:10px;
      border-top:1px solid #101826;
    }
    .table tbody td::before{
      content:attr(data-label);
      font-size:11px;
      font-weight:600;
      text-transform:uppercase;
      letter-spacing:.05em;
      color:#94a3b8;
    }
    .table tbody td.td-actions{
      order:-1;
      border-top:none !important;
      margin-top:0;
      padding-top:0;
    }
    .table tbody td.td-actions::before{
      margin-bottom:4px;
    }
    .table tbody td.td-actions .btn-sm{
      width:100%;
      justify-content:center;
    }
    .td-actions,.col-actions{
      position:static;
      width:auto;
      min-width:0;
      box-shadow:none;
      background:transparent;
    }
    .farol-cell{ flex-wrap:wrap; gap:6px; }
    .td-clientsite,.td-agent,.td-lastseen,.td-result{
      word-break:break-word;
    }
  }

  .farol-cell{ display:flex; align-items:center; gap:8px }
  .farol-text{ font-size:var(--font-xs); color:#cbd5e1 }
  .farol-empty{ color:var(--muted); font-size:var(--font-xs) }
  button.farol-dot{
    width:16px; height:16px; border-radius:50%;
    border:0; padding:0; margin:0;
    min-width:16px;
    background:#4b5563;
    box-shadow:0 0 0 2px #1f2937;
    cursor:pointer;
    color:transparent;
    display:inline-block;
  }
  button.farol-dot:focus-visible{ outline:2px solid var(--brand); outline-offset:2px }
  button.farol-dot.farol-ok{
    background:var(--ok-fg);
    box-shadow:0 0 0 2px var(--ok-b);
  }
  button.farol-dot.farol-warn{
    background:var(--warn-fg);
    box-shadow:0 0 0 2px var(--warn-b);
  }
  button.farol-dot.farol-idle{
    background:#4b5563;
    box-shadow:0 0 0 2px #1f2937;
  }
  .veeam-chip{
    display:inline-flex;
    align-items:center;
    gap:4px;
    border:1px solid #0f8f4b;
    color:#0f8f4b;
    background:#e8f6ee;
    padding:2px 10px;
    border-radius:999px;
    font-size:11px;
    font-weight:600;
    cursor:pointer;
    transition:background .2s ease;
  }
  .veeam-chip:hover{ background:#d3f0e2; }
  .veeam-icon{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:16px;
    height:16px;
    border-radius:50%;
    background:#0f8f4b;
    color:#fff;
    font-size:10px;
    font-weight:700;
    letter-spacing:-0.5px;
  }
  .veeam-chip.muted{
    border-color:#374151;
    color:#9ca3af;
    background:#0f172a;
  }
  .veeam-chip.muted .veeam-icon{
    background:#374151;
  }
  .veeam-summary{
    background:#576b6c;
    border:1px solid #394748;
    border-radius:8px;
    padding:10px 14px;
    font-size:13px;
    margin-bottom:12px;
    display:flex;
    flex-wrap:wrap;
    gap:20px;
    color:#f9fbff;
  }
  .veeam-summary strong{ display:block; font-size:12px; color:#f9fbff; text-transform:uppercase; letter-spacing:.05em }
  .veeam-summary .muted{ color:#00ff35 }
  #restoreTestsTable .muted{ color:#00ff35 }

  /* pills */
  .pill{ display:inline-flex; align-items:center; gap:6px; padding:2px 8px; border-radius:999px; font-size:12px; line-height:1; border:1px solid transparent }
  .pill.ok{ background:var(--ok-bg); color:var(--ok-fg); border-color:var(--ok-b) }
  .pill.warn{ background:var(--warn-bg); color:var(--warn-fg); border-color:var(--warn-b) }
  .pill.bad{ background:var(--bad-bg); color:var(--bad-fg); border-color:var(--bad-b) }
  .pill.neutral{ background:#111827; color:#cbd5e1; border-color:#1f2937 }
  .pill.inventory{ background:#831843; color:#ffffff; border-color:#be185d }
  .pill.push-off{
    background:#2b1d1a;
    color:#fda4af;
    border-color:#7f1d1d;
    font-size:10px;
    text-transform:uppercase;
    letter-spacing:.05em;
  }
  #notifHistoryBadge{
    min-width:22px;
    height:22px;
    padding:0;
    border-radius:50%;
    font-weight:700;
    color:#fff;
    background:var(--brand);
    border-color:var(--brand-b);
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:0;
  }
.pill.orange{
  background: #3f1f09;    /* fundo escuro quente */
  color: #f59e0b;         /* texto laranja */
  border: 1px solid #7c2d12;
}
  .td-agent.push-off{
    white-space:normal;
  }
  .td-agent.push-off .agent-name{
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
  }
  .td-agent.push-off .pill{
    margin-top:4px;
  }

.farol-summary{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(210px, 1fr));
  gap:12px;
  margin-bottom:12px;
}
.metric-card{
  background:#0f172a;
  border:1px solid var(--border);
  border-radius:12px;
  padding:10px 12px;
  display:flex;
  flex-direction:column;
  gap:4px;
  min-height:92px;
}
.metric-card small{
  text-transform:uppercase;
  letter-spacing:.05em;
  font-size:10px;
  color:#94a3b8;
}
.metric-card .metric-value{
  font-size:17px;
  font-weight:500;
  color:#e2e8f0;
}
.metric-card .metric-extra{
  color:#94a3b8;
  font-size:12px;
}
.metric-card.ok{
  border-color:var(--ok-b);
}
.metric-card.ok .metric-value{
  color:var(--ok-fg);
}
.metric-card.warn{
  border-color:var(--warn-b);
}
.metric-card.warn .metric-value{
  color:var(--warn-fg);
}
.metric-card.bad{
  border-color:var(--bad-b);
}
.metric-card.bad .metric-value{
  color:var(--bad-fg);
}
.json-table-wrap{
  border:1px solid var(--border);
  border-radius:12px;
  overflow:hidden;
  margin-bottom:12px;
  background:#0b1220;
  display:none;
}
.json-table{
  width:100%;
  border-collapse:collapse;
}
.json-table thead th{
  text-align:left;
  font-size:12px;
  letter-spacing:.04em;
  text-transform:uppercase;
  padding:8px 12px;
  background:#0f172a;
  border-bottom:1px solid var(--border);
  color:#94a3b8;
}
.json-table tbody td{
  padding:8px 12px;
  border-bottom:1px solid #101826;
  font-size:13px;
  vertical-align:top;
}
.json-table tbody tr:last-child td{
  border-bottom:none;
}
.json-table td.key-cell{
  font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,"Liberation Mono",monospace;
  width:36%;
  color:#e2e8f0;
  white-space:normal;
  word-break:break-word;
}
.json-table td.val-cell{
  color:var(--fg);
  white-space:normal;
  word-break:break-word;
}
.json-table tbody tr:hover td{
  background:#101a2a;
}
.json-chip{
  display:inline-flex;
  align-items:center;
  padding:2px 8px;
  border-radius:999px;
  background:#1e293b;
  color:#e2e8f0;
  font-size:12px;
  margin:2px 6px 2px 0;
}
.json-chip .pill{
  margin:0;
}
.mini-pre{
  margin:4px 0;
  padding:6px 8px;
  border-radius:8px;
  border:1px solid var(--border);
  background:#0b1220;
  font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,"Liberation Mono",monospace;
  font-size:12px;
  white-space:pre-wrap;
  word-break:break-word;
}
details.json-raw{
  background:#0f172a;
  border:1px solid var(--border);
  border-radius:12px;
  margin-bottom:12px;
}

details.json-raw > summary{
  padding:10px 14px;
  cursor:pointer;
  font-size:13px;
  color:#cbd5e1;
  list-style:none;
}
details.json-raw > summary::-webkit-details-marker{
  display:none;
}
details.json-raw[open] > summary{
  border-bottom:1px solid var(--border);
}
details.json-raw .viewer{
  margin:0;
  max-height:60vh;
}
.code-block{
  margin:10px 14px 14px;
  border:1px solid #1f2937;
  border-radius:12px;
  background:#0b1018;
  overflow:hidden;
  box-shadow:0 4px 18px rgba(15,23,42,0.35);
}
.code-block .code-header{
  background:#111a2a;
  border-bottom:1px solid #1f2937;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:8px 12px;
  font-size:12px;
  letter-spacing:.04em;
  text-transform:uppercase;
  color:#cbd5e1;
}
.code-block .code-header .code-lang{
  font-weight:600;
  color:#94a3b8;
}
.code-block .code-header button{
  border:1px solid #334155;
  background:#1e293b;
  color:#e2e8f0;
  font-size:12px;
  border-radius:8px;
  padding:3px 10px;
  cursor:pointer;
}
.code-block .code-header button:hover{
  filter:brightness(1.08);
}
.code-block .code-header button:disabled{
  opacity:0.55;
  cursor:not-allowed;
}
.code-block pre{
  margin:0;
  padding:16px 18px;
  font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,"Liberation Mono",monospace;
  font-size:13px;
  line-height:1.55;
  background:#0b1018;
  color:#e2e8f0;
  overflow:auto;
}
.json-key{ color:#f7768e; }
.json-string{ color:#9fe89d; }
.json-number{ color:#7dcfff; }
.json-boolean{ color:#e0af68; }
.json-null{ color:#c4b5fd; font-style:italic; }

.json-raw-empty{
  margin:10px 14px 14px;
  padding:12px 16px;
  border-radius:12px;
  border:1px solid var(--border);
  background:#0f172a;
  color:#cbd5e1;
  font-size:13px;
}

/* tamanho padrão */
.modal-card{ width:min(640px,90vw); max-height:80vh; }
/* grandinha p/ logs/resultados */
.modal-card.lg{ width:min(1100px,95vw); max-height:90vh; }
.modal-body{ overflow:auto; }
/* leitura de log/json confortável */
pre.viewer{
  white-space:pre-wrap; word-break:break-word;
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  padding:12px; border-radius:10px;
  max-height:75vh; overflow:auto;
}

  .ellipsis{ white-space:nowrap; overflow:hidden; text-overflow:ellipsis; min-width:0 }
  .nowrap{ white-space:nowrap }
  .num{ text-align:right }
  .cell-actions{ display:flex; gap:6px; justify-content:flex-end }

  /* Botões genéricos */
  .btn-sm{ padding:4px 6px; border-radius:8px; font-size:12px; border:1px solid #334155; background:#1e293b; color:#e2e8f0; display:inline-flex; align-items:center; gap:6px; }
  .btn-sm .icon{ font-weight:600; }
  .btn-sm:hover{ filter:brightness(1.08) }
  .btn-sm[disabled]{ opacity:0.45; cursor:not-allowed; pointer-events:none }
  .btn-ghost{ background:#0f172a; border:1px solid #2a374a }
  #btnThemeToggle{
    width:36px;
    height:32px;
    padding:0;
    justify-content:center;
    font-size:16px;
  }
  #btnThemeToggle .theme-icon{ line-height:1; }
 .btn-accent {
    background: #265a76;
    border: 1px solid #3a70a9;
    color: #fff;
    box-shadow: 0 0 10px rgba(249, 115, 22, 0.25);
    opacity: 0.92;
}
 .btn-accent:hover{ filter:brightness(1.02); box-shadow:0 0 14px rgba(118,128,182,0.35); opacity:1; }
 .loading-overlay{
   position:fixed;
   inset:0;
   background:rgba(8,13,23,0.88);
   display:none;
   align-items:center;
   justify-content:center;
   z-index:200;
   backdrop-filter:blur(2px);
 }
 .loading-overlay .box{
   background:#0f172a;
   border:1px solid #1e293b;
   border-radius:14px;
   padding:16px 22px;
   display:flex;
   align-items:center;
   gap:12px;
   color:#f1f5f9;
   font-size:15px;
   letter-spacing:.01em;
   box-shadow:0 10px 30px rgba(2,6,23,0.65);
 }
 .loading-overlay .spinner{
   width:22px;
   height:22px;
   border-radius:50%;
   border:3px solid rgba(255,255,255,0.25);
   border-top-color:#f97316;
   animation:loading-spin 0.85s linear infinite;
 }
 @keyframes loading-spin{
   to{ transform:rotate(360deg); }
 }
  .btn-red{ background:#b91c1c; border-color:#991b1b }
  .btn-red:hover{ filter:brightness(1.08) }
  .btn-yellow{ background:#a16207; border-color:#925e06 }

  /* Logo no header */
  header .logo{ height:31px; width:auto; display:block }

  /* ===== Modal base ===== */
  .modal-backdrop{
    position:fixed;
    inset:0;
    background:rgba(0,0,0,.6);
    display:none;
    align-items:flex-start;
    justify-content:center;
    padding:40px 16px;
    overflow-y:auto;
    z-index:50
  }
  .modal{ width:min(100%,1200px); max-height:85vh; background:#0b1220; border:1px solid var(--border); border-radius:12px; overflow:hidden; display:flex; flex-direction:column }
  .modal header{ position:unset; background:#0f172a; border-bottom:1px solid var(--border); padding:10px 12px; display:flex; gap:8px; align-items:center }
  .modal h3{ margin:0; font-size:16px }
  .modal .content{ padding:12px; overflow:auto }
  .modal .actions{ display:flex; gap:8px; justify-content:flex-end; padding:12px; border-top:1px solid var(--border); background:#0f172a }
  .form-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
    gap:12px;
  }
  .form-field{
    display:flex;
    flex-direction:column;
    gap:6px;
  }
  .input-compact{
    max-width:90px;
  }
  .form-field.full{ grid-column:1 / -1; }
  .twofa-card{
    border:1px solid var(--border);
    border-radius:12px;
    padding:12px;
    background:#0f172a;
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
    gap:16px;
  }
  .twofa-card .twofa-block{
    display:flex;
    flex-direction:column;
    gap:8px;
  }
  .twofa-card code{
    background:#0b1220;
    border:1px solid #1f2937;
    border-radius:8px;
    padding:8px;
    font-size:14px;
  }
  .grid2{ display:grid; grid-template-columns:1fr 1fr; gap:12px }
  .grid3{ display:grid; grid-template-columns:repeat(auto-fit,minmax(200px,1fr)); gap:12px }
  .grid1{ display:grid; grid-template-columns:1fr; gap:12px }
  .row{ display:flex; gap:8px; align-items:center }
  label.small{ font-size:12px; color:#cbd5e1 }

  /* Mensagens */
  .msg{ padding:8px 10px; border-radius:8px; margin:8px 0; border:1px solid; display:none }
  .msg.ok{ background:#052e16; color:#86efac; border-color:#064e3b }
  .msg.err{ background:#3b0a0a; color:#fca5a5; border-color:#7f1d1d }
  .msg.warn{ background:#3f2e0a; color:#fde68a; border-color:#a16207 }
  .pill.pink{ background:#3a0a2a; color:#f7b5d0; border:1px solid #6d184d }

  /* ===== Histórico ===== */
  #modalHistBg .modal{ width:min(100%,1200px) }
  #modalHistBg .modal .content{ font-size:13px; }
  #modalVeeamBg{ align-items:flex-start; padding-top:30px }
  #modalVeeamBg .modal{ width:min(100%,1500px); max-height:90vh }
  #modalVeeamBg #veeamTable td,
  #modalVeeamBg #veeamTable th{
    vertical-align:top;
    width:auto;
  }
  #modalVeeamBg #veeamTable td.message-cell{
    white-space:normal;
    word-break:break-word;
    min-width:260px;
  }
  #modalVeeamBg #veeamTable td.result-cell{
    white-space:nowrap;
    min-width:110px;
  }
  #modalVeeamBg #veeamTable td.next-run-cell{
    white-space:nowrap;
    min-width:140px;
  }
  .local-repo-summary{
    display:flex;
    flex-wrap:wrap;
    gap:12px;
    align-items:center;
    margin:10px 0;
  }
  .local-repo-pill{
    min-width:auto;
    text-align:center;
    padding:4px 12px;
    border-radius:999px;
    font-size:12px;
    font-weight:600;
    border:1px solid transparent;
    background:#1e293b;
    color:#e2e8f0;
  }
  .local-repo-pill.warn{
    background:#7c2d12;
    color:#fdba74;
    border-color:#fb923c;
  }
  .local-repo-pill.ok{
    background:#14532d;
    color:#bbf7d0;
    border-color:#22c55e;
  }
  .local-repo-pill.err{
    background:#450a0a;
    color:#fecaca;
    border-color:#b91c1c;
  }
  .local-repo-summary code,
  .local-repo-base{
    background:#0f172a;
    border:1px solid var(--border);
    border-radius:6px;
    padding:2px 8px;
    display:inline-flex;
    align-items:center;
  }
  .local-repo-base{ gap:6px; min-height:28px; }
  .local-repo-inline{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    align-items:center;
  }
  .local-repo-inline strong{
    font-size:13px;
    font-weight:600;
  }
  .local-repo-search{
    display:flex;
    align-items:center;
    gap:6px;
    background:#0f172a;
    border:1px solid var(--border);
    border-radius:6px;
    padding:0 8px;
    height:34px;
  }
  .local-repo-search input{
    background:transparent;
    border:none;
    color:#e2e8f0;
    min-width:200px;
    font-size:13px;
    outline:none;
  }
  .local-repo-search input::placeholder{
    color:#64748b;
  }
  .local-repo-search-icon{
    display:inline-flex;
    color:#94a3b8;
  }
  .local-repo-search-icon svg{
    width:16px;
    height:16px;
  }
  .local-repo-search-clear{
    border:none;
    background:transparent;
    color:#94a3b8;
    cursor:pointer;
    font-size:16px;
    line-height:1;
    padding:0;
  }
  .local-repo-search-clear:hover{
    color:#e2e8f0;
  }
  .local-repo-search-clear:disabled{
    opacity:.35;
    cursor:default;
  }
  .local-repo-entry{
    display:flex;
    flex-direction:column;
    gap:2px;
  }
  .local-repo-entry-main{
    display:flex;
    align-items:center;
    gap:5px;
  }
  .local-repo-entry.local-repo-entry-child{
    margin-left:50px;
  }
  .local-repo-chain-badge{
    display:inline-flex;
    align-items:center;
    gap:3px;
    font-size:9px;
    text-transform:uppercase;
    letter-spacing:.03em;
    border-radius:999px;
    padding:1px 5px;
    font-weight:600;
    background:#e2e8f0;
    color:#1e293b;
    white-space:nowrap;
    border:1px solid rgba(148,163,184,.6);
  }
  .local-repo-chain-badge svg{
    width:9px;
    height:9px;
  }
  .local-repo-chain-badge svg path{
    fill:currentColor;
  }
  .local-repo-chain-badge.vbk{
    background:#e1f8e8;
    color:#15803d;
    border-color:rgba(74,222,128,.6);
  }
  .local-repo-chain-badge.vbm{
    background:#e0f2fe;
    color:#0369a1;
    border-color:rgba(14,165,233,.6);
  }
  .local-repo-chain-badge.vib{
    background:#efe9ff;
    color:#5b21b6;
    border-color:rgba(99,102,241,.6);
  }
  .local-repo-chain-badge.sql{
    background:#0f172a;
    color:#38bdf8;
    border-color:rgba(56,189,248,.6);
  }
  .local-repo-entry-name{
    font-size:11px;
  }
  .local-repo-chain-note{
    font-size:10px;
    color:#94a3b8;
    line-height:1.2;
  }
  .local-repo-folder-label{
    display:inline-flex;
    align-items:center;
    gap:6px;
  }
  .local-repo-folder-label svg{
    width:16px;
    height:16px;
    color:#fcd34d;
  }
  .local-repo-toggle{
    border:1px solid #1f2937;
    background:#0f172a;
    color:#cbd5e1;
    border-radius:999px;
    width:22px;
    height:22px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    cursor:pointer;
    padding:0;
  }
  .local-repo-toggle:hover{
    color:#38bdf8;
    border-color:#38bdf8;
  }
  .local-repo-toggle svg{
    width:12px;
    height:12px;
  }
  .local-repo-toggle svg path{
    stroke:currentColor;
    stroke-width:2;
    stroke-linecap:round;
    fill:none;
  }
  .notif-stack{
    position:fixed;
    top:20px;
    right:60px;
    display:flex;
    flex-direction:column;
    gap:10px;
    z-index:6000;
    pointer-events:none;
  }
  .notif-toast{
    min-width:240px;
    max-width:320px;
    background:rgba(15,23,42,.97);
    color:#e2e8f0;
    border-radius:12px;
    border:1px solid rgba(148,163,184,.4);
    border-left:4px solid #38bdf8;
    padding:12px 14px;
    box-shadow:0 15px 35px rgba(2,6,23,.45);
    animation:notif-slide-in .25s ease-out;
    pointer-events:auto;
  }
  .notif-toast.success{ border-color:#22c55e; }
  .notif-toast.error{ border-color:#ef4444; }
  .notif-toast.warn{ border-color:#fbbf24; }
  .notif-toast.hide{
    opacity:0;
    transform:translateX(6px);
    transition:opacity .25s ease, transform .25s ease;
  }
  .notif-toast-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    margin-bottom:4px;
  }
  .notif-toast strong{
    display:block;
    font-size:13px;
  }
  .notif-toast p{
    margin:0;
    font-size:12px;
    color:#cbd5e1;
    line-height:1.35;
  }
  .notif-toast button{
    background:transparent;
    border:none;
    color:#94a3b8;
    font-size:18px;
    line-height:1;
    cursor:pointer;
    padding:0;
  }
  .notif-toast button:hover{
    color:#f8fafc;
  }
  @keyframes notif-slide-in{
    from{ opacity:0; transform:translateX(12px); }
    to{ opacity:1; transform:translateX(0); }
  }
  .notif-history-panel{
    position:fixed;
    top:100px;
    right:60px;
    width:360px;
    max-height:calc(100vh - 140px);
    background:rgba(8,13,26,.98);
    border:1px solid rgba(148,163,184,.35);
    border-radius:14px;
    box-shadow:0 25px 45px rgba(2,6,23,.55);
    padding:14px;
    display:none;
    flex-direction:column;
    gap:10px;
    z-index:6005;
    overflow:hidden;
  }
  .notif-history-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
  }
  .notif-history-title{
    font-size:15px;
    font-weight:600;
    color:#f8fafc;
  }
  .notif-history-body{
    overflow-y:auto;
    max-height:calc(100vh - 190px);
    display:flex;
    flex-direction:column;
    gap:10px;
  }
  .notif-history-item{
    background:#0f172a;
    border:1px solid rgba(148,163,184,.25);
    border-radius:10px;
    padding:10px 12px;
    display:flex;
    flex-direction:column;
    gap:6px;
  }
  .notif-history-top{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:8px;
    font-size:12px;
    color:#cbd5e1;
  }
  .notif-history-head{
    display:flex;
    align-items:center;
    gap:8px;
  }
  .notif-history-type{
    font-weight:600;
    color:#e2e8f0;
  }
  .notif-history-time{
    font-size:11px;
    padding:2px 6px;
    border-radius:999px;
    background:#111827;
    border:1px solid #1f2937;
    color:#94a3b8;
  }
  .notif-history-status{
    font-weight:600;
    text-transform:uppercase;
    font-size:11px;
    letter-spacing:.05em;
  }
  .notif-history-status.success{ color:#22c55e; }
  .notif-history-status.error{ color:#ef4444; }
  .notif-history-status.warn{ color:#fbbf24; }
  .notif-history-meta{
    font-size:11px;
    color:#94a3b8;
  }
  .notif-history-item p{
    margin:0;
    font-size:12px;
    color:#e2e8f0;
  }
  .notif-history-actions{
    display:flex;
    gap:6px;
    flex-wrap:wrap;
  }
  .notif-history-actions .btn-sm{
    flex:1 1 30%;
  }
  .notif-history-empty{
    font-size:12px;
    color:#94a3b8;
    text-align:center;
    padding:20px 0;
  }
  .cmd-row-highlight{
    animation: cmd-highlight 2s ease-out;
    box-shadow:0 0 0 2px rgba(56,189,248,.9) inset;
  }
  @keyframes cmd-highlight{
    from{ box-shadow:0 0 0 2px rgba(56,189,248,1) inset; }
    to{ box-shadow:0 0 0 0 rgba(56,189,248,0) inset; }
  }
  #localRepoTable tr.repo-row-collapsed{
    display:none;
  }
  #localRepoTable tr.repo-row-vbk td:nth-child(4){
    color:#00ff35;
    font-weight:600;
  }
  .local-repo-divider{
    color:#475569;
  }
  #localRepoTable td,#localRepoTable th{ vertical-align:top; }
  .veeam-tabs{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    margin:12px 0;
    border-bottom:1px solid var(--border);
  }
  .veeam-tab{
    border:1px solid var(--border);
    border-bottom:none;
    border-radius:8px 8px 0 0;
    background:#0f172a;
    color:#cbd5e1;
    padding:6px 12px;
    font-size:13px;
    cursor:pointer;
  }
  .veeam-tab .tab-icon{
    width:14px;
    height:14px;
    display:inline-block;
    margin-right:6px;
    vertical-align:-2px;
    fill:currentColor;
  }
  .veeam-tab[disabled]{
    opacity:0.4;
    cursor:not-allowed;
    pointer-events:none;
  }
  .veeam-tab.active{
    background:#1e293b;
    color:#ffffff;
    font-weight:600;
  }
  .veeam-pane{ display:none; }
  .veeam-pane.active{ display:block; }
  .restore-form{
    background:#111827;
    border:1px solid #1f2937;
    border-radius:8px;
    padding:12px;
    margin-bottom:14px;
  }
  .restore-form .grid2{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
    gap:12px;
  }
  .restore-form .compact input,
  .restore-form .compact select{
    max-width:200px;
  }
  .restore-form input,
  .restore-form textarea,
  .restore-form select{
    width:100%;
  }
  .restore-job-custom{
    margin-top:6px;
  }
  .restore-form textarea{
    min-height:80px;
  }
  .restore-form input[type="checkbox"]{
    width:auto;
    height:auto;
    padding:0;
    margin:0;
  }
  .restore-actions{
    display:flex;
    gap:8px;
    align-items:center;
    margin-top:10px;
    flex-wrap:wrap;
  }
  #modalHistBg .tbl-mini th, #modalHistBg .tbl-mini td{ white-space:nowrap }
  .tabs{ display:flex; gap:6px; margin-bottom:8px }
  .tab{ padding:6px 10px; border:1px solid #334155; border-radius:999px; background:#0f172a; color:#cbd5e1; cursor:pointer }
  .tab.active{ background:#1e293b; color:#e2e8f0 }
  .tbl-mini{ width:100%; border-collapse:separate; border-spacing:0 }
  .tbl-mini th,.tbl-mini td{ padding:8px; border-bottom:1px solid #0e1726; text-align:left; vertical-align:top }
  .tbl-mini tbody tr:nth-child(even){ background:#0d1626 }
  .tbl-mini tbody tr:hover{ background:#101d33 }
  #backblazeTable{ font-size:12.5px }
  #backblazeTable th,#backblazeTable td{ padding:6px 8px; vertical-align:middle }
  #backblazeTable th.chk,#backblazeTable td.chk{
    width:28px;
    padding-left:6px;
    padding-right:6px;
    text-align:center;
  }
  #backblazeTable .td-actions{ white-space:nowrap }
  #backblazeTable .td-actions .btn-sm{ padding:4px 8px }
  #backblazeTable .b2-group-row td{
    background:#0f1b2b;
    border-bottom:1px solid #132238;
    font-weight:600;
  }
  #backblazeTable .b2-group-toggle{
    background:#0b3a47;
    color:#67e8f9;
    border:1px solid #0e7490;
    border-radius:6px;
    padding:0 6px;
    margin-right:8px;
    font-weight:700;
    line-height:18px;
    cursor:pointer;
  }
  #backblazeTable .b2-group-label{ color:#e2e8f0 }
  #backblazeTable .b2-group-meta{ color:#94a3b8; font-weight:500; font-size:11px; margin-left:8px }
  .theme-light #backblazeTable .b2-group-row td{ background:#eef2ff; border-bottom-color:#dbeafe }
  .theme-light #backblazeTable .b2-group-label{ color:#1e293b }
  .theme-light #backblazeTable .b2-group-meta{ color:#475569 }
  #backblazeTable .sort-btn{
    background:transparent;
    border:0;
    color:inherit;
    font:inherit;
    padding:0;
    display:inline-flex;
    align-items:center;
    gap:6px;
    cursor:pointer;
  }
  #backblazeTable .sort-btn:focus-visible{
    outline:2px solid #38bdf8;
    outline-offset:2px;
    border-radius:4px;
  }
  #backblazeTable .sort-ind{
    width:0;
    height:0;
    border-left:4px solid transparent;
    border-right:4px solid transparent;
    border-top:6px solid #94a3b8;
    opacity:0.6;
  }
  #backblazeTable th.sort-asc .sort-ind{
    border-top:0;
    border-bottom:6px solid #93c5fd;
    opacity:1;
  }
  #backblazeTable th.sort-desc .sort-ind{
    border-top:6px solid #93c5fd;
    opacity:1;
  }
  #backblazeTable th.sort-none .sort-ind{ opacity:0.3 }
  .theme-light #backblazeTable .sort-ind{ border-top-color:#64748b }
  .theme-light #backblazeTable th.sort-asc .sort-ind{ border-bottom-color:#2563eb }
  .theme-light #backblazeTable th.sort-desc .sort-ind{ border-top-color:#2563eb }
  #backblazeTable .b2-dir-tag{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    font-size:10px;
    font-weight:700;
    letter-spacing:0.4px;
    text-transform:uppercase;
    padding:2px 6px;
    border-radius:999px;
    margin-right:6px;
    background:#0b3a47;
    color:#67e8f9;
    border:1px solid #0e7490;
    vertical-align:middle;
  }
  #backblazeTable .b2-dir{ color:#67e8f9; font-weight:600 }
  .theme-light #backblazeTable .b2-dir-tag{
    background:#cffafe;
    color:#0e7490;
    border-color:#99f6e4;
  }
  .theme-light #backblazeTable .b2-dir{ color:#0e7490 }

  /* contador */
  .count{ font-size:12px; color:#94a3b8; margin-left:6px }

  /* Empilhamento das modais (resultado acima de comandos) */
  #modalCmdBg{ z-index:60 }
  #modalResBg{ z-index:80 }
  #modalShellBg{ z-index:70 }

  /* ===== Novo Agente: layout elástico p/ textarea ===== */
  #modalNewBg .content{ display:flex; flex-direction:column; gap:12px }
  #modalNewBg .content .grid2{ flex:0 0 auto }
  #modalNewBg .grid2 .row input{ min-width:260px; flex:1 1 260px }
  #modalNewBg .content .row{  flex:0 0 auto }
  #modalNewBg #cfgBlock{ display:flex; flex-direction:column; min-height:340px; flex:1 1 auto }
  #modalNewBg #cfgPreview{ flex:1 1 auto; min-height:0; width:100%; resize:vertical }

  /* ===== Editar: largura maior e INI elástico ===== */
  #modalEditBg .modal{ width:min(100%,1100px); max-height:90vh }
  #modalEditBg .content{ display:flex; flex-direction:column; gap:12px }
  #modalEditBg .content .grid1,
  #modalEditBg .content .grid2{ flex:0 0 auto }
  #modalEditBg .edit-basic-grid{
    grid-template-columns:repeat(4,minmax(160px,1fr));
    grid-template-areas:
      "edit-id edit-name edit-client edit-site"
      "edit-key edit-key edit-key edit-key"
      "edit-push edit-push edit-hb edit-hb";
  }
  #modalEditBg .edit-id-field{ grid-area:edit-id; }
  #modalEditBg .edit-name-field{ grid-area:edit-name; }
  #modalEditBg .edit-client-field{ grid-area:edit-client; }
  #modalEditBg .edit-site-field{ grid-area:edit-site; }
  #modalEditBg .edit-hb-field{ grid-area:edit-hb; }
  #modalEditBg .edit-key-field{ grid-area:edit-key; }
  #modalEditBg .edit-push-field{ grid-area:edit-push; }
  @media (max-width:900px){
    #modalEditBg .edit-basic-grid{
      grid-template-columns:repeat(2,minmax(180px,1fr));
      grid-template-areas:
        "edit-id edit-name"
        "edit-client edit-site"
        "edit-key edit-key"
        "edit-push edit-hb";
    }
  }
  #modalEditBg #editCfgBlock{ display:flex; flex-direction:column; min-height:360px; flex:1 1 auto }
  #modalEditBg #editCfgPreview{ flex:1 1 auto; min-height:0; width:100%; resize:vertical }
  #modalEditBg #rowEditKey{ flex-wrap:nowrap; gap:6px; align-items:center }
  #modalEditBg #rowEditKey input{ min-width:240px; max-width:360px; flex:1 1 240px }
  #modalEditBg .edit-key-field .row{ flex-wrap:nowrap }

  /* ===== Comandos: layout elástico real (payload grande) ===== */
  #modalCmdBg .modal{ max-height:90vh; display:flex; flex-direction:column }
  #modalCmdBg .content{ flex:1 1 auto; display:flex; flex-direction:column; gap:12px; overflow:hidden; min-height:0 }
  /* bloco do payload vira flex pra textarea crescer */
  #modalCmdBg .grid1{ display:flex; flex-direction:column; flex:1 1 auto; min-height:0 }
  /* vence qualquer min-height inline */
  #cmdPayload{
    flex:1 1 auto;
    min-height:180px !important;
    width:100%;
    resize:vertical;
    font-family:monospace; font-size:13px;
  }
  /* listagem: altura mínima, sem rolagem interna obrigatória */
  #modalCmdBg .table-wrap{ flex:1 1 240px; min-height:220px; max-height:50vh; overflow:auto }
  #modalCmdBg .cmd-toolbar{ flex-wrap:wrap; align-items:center; }

/* ===== Terminal remoto ===== */
#modalShellBg .modal{
  width:min(100%,1300px);
  max-height:90vh;
  display:flex;
  flex-direction:column;
}
  #modalShellBg .content{
    display:flex;
    flex-direction:column;
    gap:12px;
  }
  #shellResultWrap{
    border:1px solid var(--border);
    border-radius:10px;
    background:#0f172a;
    padding:12px;
    display:none;
    flex-direction:column;
    gap:12px;
  }
  #shellResultWrap textarea{
    font-family:monospace;
    font-size:14px;
  }
  #shellLog{
    width:100%;
    min-height:320px;
    max-height:50vh;
    white-space:pre-wrap;
    line-height:1.35;
    background:#000000;
    border:1px solid #1e293b;
    border-radius:8px;
    padding:12px;
    color:#b7ea16;
  }
  #modalShellBg .input-row{
    display:flex;
    gap:8px;
    align-items:center;
    flex-wrap:wrap;
  }
  #shellCommandInput{
    flex:1 1 auto;
    min-width:260px;
    font-family:monospace;
    font-size:15px;
    padding:10px;
    border-radius:8px;
    border:1px solid var(--border);
    background:#0b1220;
    color:#e2e8f0;
  }
  #modalShellBg .input-row button{
    flex:0 0 auto;
  }
  #shellResultWrap .summary-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
    gap:10px;
  }
  .copy-inline{
    display:flex;
    gap:8px;
    align-items:center;
  }
  .copy-inline input,
  .copy-inline textarea{
    flex:1;
    resize:vertical;
    min-height:48px;
    font-family:monospace;
    font-size:14px;
  }
  #shellStatus{
    font-size:13px;
    font-weight:600;
    display:inline-flex;
    align-items:center;
    gap:6px;
    padding:4px 12px;
    border-radius:999px;
    background:#1e293b;
    color:#cbd5f5;
  }
  #shellStatus::before{
    content:'';
    width:8px;
    height:8px;
    border-radius:50%;
    background:#94a3b8;
    box-shadow:0 0 8px rgba(148,163,184,0.6);
  }
  #shellStatus.ok{
    background:#022c22;
    color:#34d399;
  }
  #shellStatus.ok::before{
    background:#34d399;
    box-shadow:0 0 10px rgba(52,211,153,0.85);
  }
  #shellStatus.err{
    background:#3b0a0a;
    color:#f87171;
  }
  #shellStatus.err::before{
    background:#f87171;
    box-shadow:0 0 10px rgba(248,113,113,0.85);
  }
  #shellStatus.muted{
    background:#1e293b;
    color:#94a3b8;
  }
  #shellStatus.muted::before{
    background:#94a3b8;
    box-shadow:0 0 8px rgba(148,163,184,0.6);
  }
  #shellTips{
    font-size:12px;
    color:#9ca3af;
    line-height:1.4;
  }
  #shellSummaryRaw{
    background:#111a2c;
    border:1px solid var(--border);
    border-radius:10px;
    padding:10px;
    margin-top:6px;
    max-height:180px;
    overflow:auto;
    font-family:monospace;
    font-size:12px;
    color:#e2e8f0;
  }
  #shellCheats{
    border:1px solid var(--border);
    border-radius:10px;
    background:#0d1626;
    padding:12px;
    display:flex;
    flex-direction:column;
    gap:10px;
  }
  #shellCheats ul{
    list-style:none;
    margin:0;
    padding:0;
    display:flex;
    flex-direction:column;
    gap:8px;
  }
  #shellCheats li{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    align-items:center;
  }
  #shellCheats code{
    flex:1 1 auto;
    font-family:monospace;
    font-size:13px;
    background:#020617;
    color:#cbd5f5;
    border-radius:6px;
    padding:6px 8px;
    border:1px solid rgba(148,163,184,0.3);
    word-break:break-all;
  }

  /* ===== Resultado do Comando: textarea grandona ===== */
#modalResBg .modal{
  width:min(100%,1100px);
  max-height:90vh;
  display:flex;
  flex-direction:column;
}

  #modalResBg .content{ flex:1 1 auto; display:flex; flex-direction:column; gap:12px; overflow:hidden; min-height:0 }
#modalResBg #resPreview{ min-height:220px; }
#modalResBg #resPreviewExtra{ margin-top:12px; }
#modalResBg #resPreviewExtra img{ max-width:100%; max-height:320px; border-radius:8px; background:#0f172a; padding:8px; }
#modalResBg .disk-report{ display:flex; flex-direction:column; gap:12px; margin-top:12px; max-height:55vh; overflow:auto; padding-right:4px; }
#modalResBg .disk-report-summary{ display:flex; flex-wrap:wrap; gap:8px; align-items:center; }
#modalResBg .disk-chip{ background:#162338; border:1px solid var(--border); border-radius:999px; padding:4px 12px; font-size:12px; letter-spacing:.05em; text-transform:uppercase; color:#cbd5f5; }
#modalResBg .disk-chip.warn{ border-color:#f59e0b; color:#fcd34d; }
#modalResBg .disk-chip.crit{ border-color:#ef4444; color:#f87171; }
#modalResBg .disk-summary-meta{ font-size:12px; color:#94a3b8; }
#modalResBg .disk-section{ background:#0f172a; border:1px solid var(--border); border-radius:10px; padding:12px; }
#modalResBg .disk-section h4{ margin:0 0 8px; font-size:13px; text-transform:uppercase; letter-spacing:.05em; color:#9ca3af; }
#modalResBg .disk-card-grid{ display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:10px; }
#modalResBg .disk-card{ background:#111a2c; border:1px solid transparent; border-radius:8px; padding:10px; display:flex; flex-direction:column; gap:6px; }
#modalResBg .disk-card.warn{ border-color:#f59e0b; }
#modalResBg .disk-card.crit{ border-color:#ef4444; }
#modalResBg .disk-card-title{ font-weight:600; font-size:14px; color:#e2e8f0; }
#modalResBg .disk-card-meta{ font-size:12px; color:#a5b4fc; }
#modalResBg .disk-card-details{ font-size:12px; color:#cbd5f5; line-height:1.4; }
#modalResBg .disk-meter{ position:relative; height:6px; border-radius:999px; background:#1f2738; overflow:hidden; }
#modalResBg .disk-meter span{ position:absolute; inset:0; border-radius:999px; background:#3b82f6; }
#modalResBg .disk-card.warn .disk-meter span{ background:#f59e0b; }
#modalResBg .disk-card.crit .disk-meter span{ background:#ef4444; }
#modalResBg .disk-warning-list{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:6px; font-size:12px; }
#modalResBg .disk-warning-list li{ padding:6px 8px; border-radius:6px; background:#101828; border:1px solid #1d2636; color:#cbd5f5; }
#modalResBg .disk-warning-list li.warn{ border-color:#f59e0b; color:#fde68a; }
#modalResBg .disk-warning-list li.crit{ border-color:#ef4444; color:#fecaca; }
#modalResBg .disk-footnote{ font-size:12px; color:#8ea3d1; margin-top:6px; }

  /* ===== Inventário ===== */
  #modalInvBg .modal{
    width:min(100%,1100px);
    max-height:90vh;
    display:flex;
    flex-direction:column;
  }
  #modalInvBg .content{
    flex:1 1 auto;
    display:flex;
    flex-direction:column;
    gap:12px;
    min-height:0;
  }
  #modalInvBg .table-wrap{ flex:0 0 auto; max-height:300px; overflow:auto }

  /* ===== Inventário Detalhado ===== */
  #modalInvDetailBg .modal{
    width:min(100%,1100px);
    max-height:95vh;
    display:flex;
    flex-direction:column;
  }
  #modalInvDetailBg .content{
    flex:1 1 auto;
    display:flex;
    flex-direction:column;
    gap:14px;
    min-height:0;
    overflow:auto;
  }
  .section-card{
    background:#0f172a;
    border:1px solid var(--border);
    border-radius:12px;
    padding:12px 14px;
  }
  .kv-grid{
    display:grid;
    grid-template-columns:minmax(140px,200px) 1fr;
    gap:6px 12px;
    font-size:13px;
  }
  .kv-grid .kv-label{
    color:#9ca3af;
    font-size:12px;
    text-transform:uppercase;
    letter-spacing:.04em;
  }
  .kv-grid .kv-value{
    color:var(--fg);
    font-size:13px;
  }
  .list-condensed{
    margin:6px 0 0;
    padding-left:18px;
    font-size:13px;
  }
  .list-condensed li{ margin-bottom:4px; }
  .volume-list{ display:flex; flex-direction:column; gap:8px }
  .volume-item{ background:#101826; border:1px solid #1f2937; border-radius:10px; padding:8px 10px }
  .volume-meta{ font-size:13px; color:#e2e8f0 }
  .volume-bar{ height:6px; border-radius:999px; background:#1f2937; margin-top:6px; overflow:hidden }
  .volume-bar-fill{ height:100%; background:linear-gradient(90deg,#0f766e 0%,#10b981 60%,#22d3ee 100%); }
  .volume-bar-legend{ display:flex; justify-content:space-between; font-size:11px; color:#94a3b8; margin-top:4px }
  .soft-preview{
    max-height:220px;
    overflow:auto;
    border:1px solid var(--border);
    border-radius:10px;
    padding:8px 10px;
    background:#0b1220;
  }
  #modalSchedulerBg .modal{
    width:min(100%,1250px);
    max-width:1250px;
  }
  .recurrence-weekdays{
    display:flex;
    flex-wrap:wrap;
    gap:6px;
  }
  .recurrence-weekdays label{
    display:flex;
    align-items:center;
    gap:4px;
    font-size:12px;
    background:#111827;
    border:1px solid #293347;
    border-radius:6px;
    padding:4px 8px;
  }
  .scheduler-summary{
    margin-top:10px;
    background:#0f172a;
    border:1px solid var(--border);
    border-radius:10px;
    padding:8px 12px;
    display:flex;
    flex-wrap:wrap;
    gap:16px;
  }
  .scheduler-summary .summary-item{
    display:flex;
    flex-direction:column;
    gap:2px;
    min-width:180px;
  }
  .scheduler-summary small{
    text-transform:uppercase;
    letter-spacing:.05em;
    font-size:10px;
    color:#94a3b8;
  }
  .scheduler-summary strong{
    font-size:13px;
    color:#e2e8f0;
  }
  .theme-light{
    --bg:#f5f7fb; --panel:#ffffff; --muted:#64748b; --border:#e2e8f0;
    --fg:#0f172a; --brand:#1d4ed8; --brand-b:#1e40af;
    --ok-bg:#dcfce7; --ok-fg:#166534; --ok-b:#86efac;
    --warn-bg:#ffedd5; --warn-fg:#9a3412; --warn-b:#fdba74;
    --bad-bg:#fee2e2; --bad-fg:#991b1b; --bad-b:#fecaca;
  }
  .theme-light body{ background:var(--bg); color:var(--fg) }
  .theme-light header{ background:#f8fafc; border-bottom:1px solid var(--border) }
  .theme-light input,
  .theme-light button,
  .theme-light select,
  .theme-light textarea{
    background:#ffffff;
    color:#0f172a;
    border-color:#cbd5e1;
  }
  .theme-light button{ background:var(--brand); border-color:var(--brand-b); color:#ffffff }
  .theme-light .btn-sm{ background:#f1f5f9; border-color:#cbd5e1; color:#0f172a }
  .theme-light .btn-ghost{ background:#f8fafc; border-color:#cbd5e1 }
  .theme-light .btn-icon.btn-ghost{ color:#475569 }
  .theme-light .btn-icon.btn-ghost:hover{ background:#e2e8f0; border-color:#cbd5e1 }
  .theme-light .table-wrap{ background:var(--panel); border-color:var(--border) }
  .theme-light .table thead th{ background:#f1f5f9; color:#475569; border-bottom:1px solid var(--border) }
  .theme-light .table tbody td{ border-bottom:1px solid #e2e8f0 }
  .theme-light .table tbody tr:nth-child(even){ background:#f8fafc }
  .theme-light .table tbody tr:nth-child(even) .td-actions{ background:#f8fafc }
  .theme-light .table tbody tr:hover{ background:#e2e8f0 }
  .theme-light .table tbody tr:hover .td-actions{ background:#e2e8f0 }
  .theme-light .td-actions,
  .theme-light .col-actions{ background:#f1f5f9 }
  .theme-light .pill.neutral{ background:#e2e8f0; color:#334155; border-color:#cbd5e1 }
  .theme-light .pill.inventory{ background:#f5d0fe; color:#701a75; border-color:#e9d5ff }
  .theme-light .pill.push-off{ background:#ffe4e6; color:#9f1239; border-color:#fecdd3 }
  .theme-light .scheduler-summary{ background:#ffffff; border-color:#e2e8f0 }
  .theme-light .scheduler-summary strong{ color:#0f172a }
  .theme-light .scheduler-summary small{ color:#64748b }
  .theme-light .section-card{ background:#ffffff; border-color:#e2e8f0 }
  .theme-light .volume-item{ background:#ffffff; border-color:#e2e8f0 }
  .theme-light .volume-meta{ color:#0f172a }
  .theme-light .volume-bar{ background:#e2e8f0 }
  .theme-light .soft-preview{ background:#ffffff }
  .theme-light .modal{ background:#ffffff; border-color:#e2e8f0 }
  .theme-light .modal header{ background:#f1f5f9; border-bottom:1px solid #e2e8f0 }
  .theme-light .modal .actions{ background:#f8fafc; border-top:1px solid #e2e8f0 }
  .theme-light .modal-backdrop{ background:rgba(15,23,42,0.25) }
  .theme-light .notif-history-panel{ background:rgba(248,250,252,0.98); border-color:#e2e8f0 }
  .theme-light .notif-history-item{ background:#ffffff; border-color:#e2e8f0 }
  .theme-light .notif-history-title{ color:#0f172a }
  .theme-light .notif-history-top{ color:#475569 }
  .theme-light .notif-history-meta{ color:#64748b }
  .theme-light .notif-history-item p{ color:#0f172a }
  .theme-light .notif-toast{ background:#ffffff; border-color:#e2e8f0; color:#0f172a }
  .theme-light .notif-toast p{ color:#334155 }
  .theme-light .notif-toast button{ color:#64748b }
  .theme-light .loading-overlay{ background:rgba(148,163,184,0.35) }
  .theme-light .loading-overlay .box{
    background:#ffffff;
    border-color:#e2e8f0;
    color:#0f172a;
    box-shadow:0 10px 30px rgba(15,23,42,0.12);
  }
  .theme-light .loading-overlay .spinner{
    border-color:rgba(15,23,42,0.2);
    border-top-color:#2563eb;
  }
  .theme-light button.farol-dot{
    background:#cbd5e1;
    box-shadow:0 0 0 2px #e2e8f0;
  }
  .theme-light button.farol-dot.farol-ok{
    background:#22c55e;
    box-shadow:0 0 0 2px #86efac;
  }
  .theme-light button.farol-dot.farol-warn{
    background:#f97316;
    box-shadow:0 0 0 2px #fdba74;
  }
  .theme-light button.farol-dot.farol-idle{
    background:#cbd5e1;
    box-shadow:0 0 0 2px #e2e8f0;
  }
  .theme-light .json-table-wrap{ background:#ffffff; border-color:#e2e8f0 }
  .theme-light .json-table thead th{
    background:#f1f5f9;
    color:#475569;
    border-bottom:1px solid #e2e8f0;
  }
  .theme-light .json-table tbody td{ border-bottom:1px solid #e2e8f0; color:#0f172a }
  .theme-light .json-table td.key-cell{ color:#0f172a }
  .theme-light .json-table tbody tr:nth-child(odd) td{ background:#ffffff }
  .theme-light .json-table tbody tr:nth-child(even) td{ background:#f8fafc }
  .theme-light .json-table tbody tr:hover td{ background:#e2e8f0 }
  .theme-light .json-chip{ background:#e2e8f0; color:#0f172a }
  .theme-light .tbl-mini th,
  .theme-light .tbl-mini td{ border-bottom:1px solid #e2e8f0; color:#0f172a }
  .theme-light .tbl-mini tbody tr:nth-child(odd){ background:#ffffff }
  .theme-light .tbl-mini tbody tr:nth-child(even){ background:#f8fafc }
  .theme-light .tbl-mini tbody tr:hover{ background:#e2e8f0 }
  .theme-light .tab{
    background:#f1f5f9;
    border-color:#cbd5e1;
    color:#334155;
  }
  .theme-light .tab.active{ background:#e2e8f0; color:#0f172a }
  .theme-light .veeam-tab{
    background:#f8fafc;
    border-color:#cbd5e1;
    color:#334155;
  }
  .theme-light .veeam-tab.active{ background:#e2e8f0; color:#0f172a }
  .theme-light .restore-form{ background:#f8fafc; border-color:#e2e8f0 }
  .theme-light .local-repo-search{
    background:#ffffff;
    border-color:#e2e8f0;
  }
  .theme-light .local-repo-search input{ color:#0f172a }
  .theme-light .local-repo-search input::placeholder{ color:#94a3b8 }
  .theme-light .local-repo-toggle{
    background:#f8fafc;
    border-color:#cbd5e1;
    color:#475569;
  }
  .theme-light .farol-text{ color:#475569 }
  .theme-light .farol-empty{ color:#64748b }
  @media (max-width:720px){
    .theme-light .table tbody tr{
      background:#ffffff;
      border-color:#e2e8f0;
      box-shadow:0 10px 18px rgba(15,23,42,0.08);
    }
    .theme-light .table tbody tr:nth-child(even){
      background:#ffffff;
    }
    .theme-light .table tbody td + td{
      border-top:1px solid #e2e8f0;
    }
    .theme-light .table tbody td::before{
      color:#64748b;
    }
  }
