/* Layout inspirado em aplicativos desktop; preserva a paleta Argo. */
.dashboard-metrics { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 8px; background: var(--surface); margin-bottom: 18px; overflow: hidden; }
.dashboard-stat { display: flex; flex-direction: column; gap: 4px; padding: 14px 18px; border-right: 1px solid var(--line-soft); }
.dashboard-stat:last-child { border-right: 0; }
.dashboard-stat:hover { background: var(--surface-raised); }
.dashboard-stat span { color: var(--muted); font-size: .78rem; }
.dashboard-stat strong { font-size: 1.55rem; line-height: 1.2; font-weight: 650; font-variant-numeric: tabular-nums; }
.app-shell { font-size: 14px; }
.app-shell .sidebar { width: 218px; }
.app-shell .workspace { margin-left: 218px; }
.app-shell .brand { height: 64px; padding: 0 18px; margin-bottom: 18px; }
.app-shell .brand-logo { width: 30px; height: 34px; }
.app-shell .brand-name { font-size: 1rem; }
.app-shell .brand-name small { font-size: .72rem; }
.app-shell .nav-caption { letter-spacing: .055em; font-size: .65rem; padding: 0 18px; }
.app-shell .sidebar nav { padding: 0 8px; }
.app-shell .nav-link { min-height: 38px; padding: 8px 11px; gap: 10px; border-radius: 6px; margin: 2px 0; font-size: .82rem; }
.app-shell .nav-separator { margin: 18px 10px; }
.app-shell .sidebar-bottom { padding: 16px; }
.app-shell .topbar { height: 64px; padding: 0 22px; gap: 16px; }
.app-shell .topbar-title { font-size: .65rem; letter-spacing: .04em; }
.app-shell .global-search-wrap { height: 34px; border-radius: 6px; }
.app-shell .global-search-wrap input { font-size: .8rem; }
.app-shell .topbar-right { gap: 10px; }
.app-shell .avatar { width: 30px; height: 30px; font-size: .72rem; }
.app-shell .account-name { font-size: .78rem; }
.app-shell .main-content { padding: 22px; }
.app-shell .page-heading { min-height: 40px; margin-bottom: 16px; }
.app-shell .page-heading h1 { font-size: 1.35rem; letter-spacing: -.02em; }
.app-shell .btn { min-height: 34px; padding: 6px 12px; border-radius: 6px; font-size: .8rem; }
.app-shell .panel { border-radius: 8px; }
.app-shell .panel-heading { padding: 14px 16px; }
.app-shell .client-directory { display: flex; flex-direction: column; min-height: calc(100vh - 210px); }
.app-shell .directory-toolbar { padding: 12px 16px; gap: 14px; border-bottom: 1px solid var(--line-soft); background: var(--surface-raised); }
.app-shell .directory-toolbar .local-search { min-height: 34px; border-radius: 6px; max-width: 560px; }
.app-shell .directory-toolbar .local-search input { padding: 6px 0; font-size: .8rem; }
.app-shell .directory-count { margin-left: auto; font-size: .75rem; }
.app-shell .directory-filters > summary { padding: 9px 16px; font-size: .75rem; }
.app-shell .directory-filters .filter-bar { padding: 4px 16px 12px; }
.app-shell .directory-groups { flex: 1; padding: 0; min-height: 240px; }
.app-shell .directory-group { border-bottom: 1px solid var(--line-soft); }
.app-shell .directory-group:last-child { border-bottom: 0; }
.app-shell .client-group > summary { min-height: 40px; padding: 9px 90px 9px 16px; gap: 8px; font-size: .82rem; }
.app-shell .group-chevron .icon { width: 14px; height: 14px; }
.app-shell .group-device-count { font-variant-numeric: tabular-nums; }
.app-shell .directory-client-link { top: 11px; right: 16px; font-size: .73rem; }
.app-shell .directory-device { min-height: 42px; padding: 6px 16px 6px 40px; gap: 12px; }
.app-shell .directory-device-name { font-size: .82rem; }
.app-shell .directory-device-id { font-size: .74rem; font-variant-numeric: tabular-nums; }
.app-shell .directory-device-status { width: 142px; flex-shrink: 0; }
.app-shell .directory-device .btn { min-height: 28px; font-size: .75rem; }
.app-shell .directory-device:hover { box-shadow: inset 3px 0 0 var(--blue); }
.app-shell .client-detail-groups .client-group > summary { padding-right: 16px; }
.app-shell .pagination { min-height: 44px; padding: 10px 16px; background: var(--surface-raised); }
.app-shell .workspace-footer { padding: 12px 22px; font-size: .7rem; }
dialog { border-radius: 10px; }
.dialog-heading { padding: 14px 18px; background: var(--surface-raised); }
.dialog-heading h2 { font-size: .95rem; }
.dialog-body { padding: 20px; }
.dialog-actions { padding: 12px 18px; }
@media (max-width: 1100px) {
  .app-shell .topbar-title { display: none; }
}
@media (max-width: 760px) {
  .dashboard-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dashboard-stat { border-bottom: 1px solid var(--line-soft); padding: 12px; }
  .app-shell .sidebar { width: 218px; }
  .app-shell .workspace { margin-left: 0; }
  .app-shell .main-content { padding: 18px; }
}
@media (max-width: 600px) {
  .app-shell .topbar { padding: 0 12px; gap: 8px; }
  .app-shell .main-content { padding: 14px; }
  .app-shell .directory-toolbar { padding: 10px 12px; gap: 8px; }
  .app-shell .directory-toolbar .local-search { flex-basis: auto; min-width: 0; }
  .app-shell .directory-device { padding-left: 28px; padding-right: 12px; gap: 8px; flex-wrap: wrap; }
  .app-shell .directory-device-name { min-width: 160px; }
  .app-shell .directory-device-status { width: auto; margin-left: 25px; }
  .app-shell .directory-device .btn { margin-left: auto; }
  .app-shell .workspace-footer { padding: 12px 14px; }
}
