#funcionarios .func-search-wrap{
  position:relative;
  width:min(560px, 100%);
}


#funcionarios .func-search-ico{
  position:absolute;
  left:14px;
  top:50%;
  transform:translateY(-50%);
  font-size:15px;
  color:#94a3b8;
  pointer-events:none;
}

#funcionarios .func-header__primary{
  display:flex;
  align-items:center;
  gap:12px;
}

#funcionarios .func-search-input{
  width:100%;
  height:44px;
  padding:0 16px 0 40px;
  border-radius:14px;
  border:1px solid #dbe4ef;
  background:linear-gradient(180deg,#ffffff,#fbfdff);
  color:#0f172a;
  margin-right:0;
  box-shadow:0 8px 20px rgba(15,23,42,.04);
  transition:border-color .16s ease, box-shadow .16s ease, background .16s ease;
}

#funcionarios .func-search-input::placeholder{
  color:#94a3b8;
}

#funcionarios .func-search-input:focus{
  outline:none;
  border-color:#93c5fd;
  box-shadow:0 0 0 4px rgba(59,130,246,.10), 0 12px 24px rgba(15,23,42,.06);
  background:#fff;
}

#funcionarios #funcBtnNovo.func-link-novo{
  width:auto;
  min-width:0;
  height:auto;
  padding:0;
  border:none;
  background:transparent;
  color:#2563eb;
  font-size:15px;
  font-weight:800;
  letter-spacing:-0.01em;
  box-shadow:none;
  border-radius:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
}

#funcionarios #funcBtnNovo.func-link-novo:hover{
  transform:none;
  filter:none;
  color:#1d4ed8;
  text-decoration:none;
}

#funcionarios #funcBtnNovo.func-link-novo::before{
  content:"+";
  display:inline-block;
  font-size:16px;
  font-weight:900;
  line-height:1;
}

#funcionarios .table-wrap,
#funcionarios .func-table-wrap{
  border:1px solid #e6edf5;
  border-radius:22px;
  overflow:hidden;
  background:rgba(255,255,255,.88);
  box-shadow:0 18px 38px rgba(15,23,42,.06);
  backdrop-filter:blur(10px);
}

#funcionarios table thead th{
  background:#f8fbff;
  color:#475569;
  font-size:11px;
  font-weight:800;
  letter-spacing:.10em;
  text-transform:uppercase;
  padding:16px 16px;
  border-bottom:1px solid #e7eef7;
}

#funcionarios table tbody td{
  padding:16px 16px;
  border-bottom:1px solid #edf2f7;
  vertical-align:middle;
}

#funcionarios table tbody tr{
  transition:
    background .16s ease,
    transform .14s ease,
    box-shadow .16s ease;
}

#funcionarios table tbody tr:hover{
  background:#fbfdff;
}

#funcionarios table tbody tr:last-child td{
  border-bottom:none;
}

#funcionarios .func-header,
#funcionarios .func-topbar{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:18px;
  flex-wrap:wrap;
}

#funcionarios .func-header-left{
  min-width:280px;
}

#funcionarios .func-header-right{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
  justify-content:flex-end;
}


#funcionarios .func-link-novo{
  margin-right:18px;
}

/* ===================== FUNCIONÁRIOS – estética premium final ===================== */
#funcionarios .func-header{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:16px;
  flex-wrap:wrap;
  margin:4px 0 16px;
}

#funcionarios .func-header__titles{
  display:flex;
  flex-direction:column;
  gap:4px;
}

#funcionarios .func-title{
  margin:0;
  font-size:18px;
  font-weight:800;
  letter-spacing:-0.01em;
  color:#0f172a;
}

#funcionarios .func-subtitle{
  color:#64748b;
  font-size:13px;
  line-height:1.45;
}

#funcionarios .func-header__actions{
  display:flex;
  gap:10px;
  align-items:center;
  justify-content:flex-end;
  flex-wrap:wrap;
  margin-left:auto;
}

#funcionarios .btn{
  appearance:none;
  width:auto;
  min-height:40px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:0 14px;
  border-radius:12px;
  border:1px solid #dbe3ee;
  background:#fff;
  color:#0f172a;
  font-size:13px;
  font-weight:700;
  cursor:pointer;
  box-shadow:0 6px 18px rgba(15,23,42,.06);
  transition:
    transform .12s ease,
    filter .15s ease,
    box-shadow .15s ease,
    border-color .15s ease,
    background .15s ease;
}

#funcionarios .btn:hover{
  transform:translateY(-1px);
  filter:none;
  box-shadow:0 10px 24px rgba(15,23,42,.10);
}

#funcionarios .btn--primary{
  background:linear-gradient(135deg,#1e4a6c,#2563eb);
  color:#fff;
  border-color:transparent;
  box-shadow:0 12px 28px rgba(37,99,235,.25);
}

#funcionarios .btn--primary:hover{
  box-shadow:0 16px 32px rgba(37,99,235,.28);
}

#funcionarios .btn--ghost{
  background:#fff;
  color:#0f172a;
}

#funcionarios .filters-wrap{
  position:relative;
}

#funcionarios .filters-menu{
  position:absolute;
  right:0;
  top:calc(100% + 8px);
  width:min(460px, 92vw);
  padding:14px;
  display:none;
  z-index:20;
  background:rgba(255,255,255,.98);
  backdrop-filter:blur(12px);
  border:1px solid #e5eaf0;
  border-radius:16px;
  box-shadow:0 22px 46px rgba(15,23,42,.14);
  color:#0f172a;
}

#funcionarios .filters-menu.show{
  display:block;
}

#funcionarios .func-company-menu{
  width:260px;
}

#funcionarios .func-company-menu .menu-item{
  width:100%;
  text-align:left;
  border:none;
  background:#fff;
  color:#0f172a;
  padding:10px 12px;
  border-radius:10px;
  font-size:13px;
  font-weight:700;
  cursor:pointer;
  transition:background .15s ease;
}

#funcionarios .func-company-menu .menu-item:hover{
  background:#f5f7fb;
}

#funcionarios .filters-title{
  font-weight:800;
  color:#0f172a;
  margin-bottom:8px;
  font-size:14px;
}

#funcionarios .filters-row{
  display:flex;
  gap:14px;
  flex-wrap:wrap;
}

#funcionarios .filters-group{
  min-width:180px;
  flex:1 1 180px;
}

#funcionarios .filters-label{
  font-size:12px;
  color:#64748b;
  margin-bottom:8px;
  font-weight:700;
}

#funcionarios .chips{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}

#funcionarios .chip{
  border:1px solid #dbe3ee;
  background:#fff;
  color:#16243a;
  padding:7px 11px;
  border-radius:999px;
  font-size:12px;
  font-weight:700;
  cursor:pointer;
  transition:
    transform .12s ease,
    box-shadow .12s ease,
    border-color .12s ease,
    background .12s ease;
}

#funcionarios .chip:hover{
  transform:translateY(-1px);
  box-shadow:0 8px 18px rgba(15,23,42,.08);
  border-color:#bfd4f6;
}

#funcionarios .chip.is-active{
  background:#eaf2ff;
  color:#1d4ed8;
  border-color:#bfdbfe;
}

#funcionarios .muted{
  color:#6b7280;
  font-size:12px;
}

#funcionarios .func-toolbar-bottom{
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:space-between;
  margin:0 0 14px;
}

#funcionarios .ctrl{
  background:#fff;
  border:1px solid #dbe3ee;
  border-radius:14px;
  padding:0 14px;
  min-height:44px;
  font-size:14px;
  color:#0f172a;
  box-shadow:0 6px 18px rgba(15,23,42,.04);
  transition:
    border-color .15s ease,
    box-shadow .15s ease,
    transform .12s ease;
}

#funcionarios .ctrl::placeholder{
  color:#94a3b8;
}

#funcionarios .ctrl:focus{
  outline:none;
  border-color:#93c5fd;
  box-shadow:
    0 0 0 4px rgba(59,130,246,.12),
    0 8px 20px rgba(15,23,42,.06);
}

#funcionarios .ctrl--search{
  min-width:320px;
  width:100%;
  max-width:560px;
}

#funcionarios .func-panel{
  background:rgba(255,255,255,.96);
  border:1px solid #e6ebf2;
  border-radius:18px;
  box-shadow:0 18px 40px rgba(15,23,42,.08);
  padding:0;
  overflow:hidden;
}

/* aqui está o limite antes do cabeçalho */
#funcionarios .table-wrap{
  border:1px solid #e6edf5;
  border-radius:22px;
  overflow:hidden;
  background:rgba(255,255,255,.88);
  box-shadow:0 18px 38px rgba(15,23,42,.06);
  backdrop-filter:blur(10px);
}

#funcionarios .func-table{
  width:100%;
  border-collapse:separate;
  border-spacing:0;
  table-layout:fixed;
}

#funcionarios .func-table thead th:nth-child(1),
#funcionarios .func-table tbody td:nth-child(1){
  width:25%;
}

#funcionarios .func-table thead th:nth-child(2),
#funcionarios .func-table tbody td:nth-child(2){
  width:16%;
}

#funcionarios .func-table thead th:nth-child(3),
#funcionarios .func-table tbody td:nth-child(3){
  width:16%;
}

#funcionarios .func-table thead th:nth-child(4),
#funcionarios .func-table tbody td:nth-child(4){
  width:13%;
}

#funcionarios .func-table thead th:nth-child(5),
#funcionarios .func-table tbody td:nth-child(5){
  width:15%;
  text-align:center;
}

#funcionarios .func-table thead th:nth-child(6),
#funcionarios .func-table tbody td:nth-child(6){
  width:15%;
  text-align:right;
}

#funcionarios .func-table thead{
  position:relative;
  z-index:5;
}

#funcionarios .func-table thead th{
  position:sticky;
  top:8px;
  z-index:8;
  background:#f8fbff;
  color:#475569;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.10em;
  font-size:11px;
  border-bottom:1px solid #e7eef7;
  padding:14px 12px;
  vertical-align:middle;
  background-clip:padding-box;
  text-align:left;
}

#funcionarios .func-table tbody{
  position:relative;
  z-index:1;
}

#funcionarios .func-table tbody td{
  padding:14px 12px;
  border-bottom:1px solid #edf2f7;
  vertical-align:middle;
  color:#1f2937;
  font-size:14px;
  background:#fff;
  text-align:left;
}

#funcionarios .func-table tbody tr{
  height:68px;
}

#funcionarios .func-table tbody tr:nth-child(even) td{
  background:#fcfdff;
}

#funcionarios .func-table tbody tr:hover td{
  background:#fbfdff;
}

#funcionarios .func-pagination{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:14px 0 6px;
  flex-wrap:wrap;
}

#funcionarios .func-page-btn{
  width:38px;
  min-width:38px;
  max-width:38px;
  height:38px;
  padding:0;
  border:1px solid rgba(37, 99, 235, 0.10);
  border-radius:12px;
  background:#fff;
  color:#1d4ed8;
  font-size:13px;
  font-weight:800;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 6px 14px rgba(15, 23, 42, 0.04);
  cursor:pointer;
  transition:transform .06s ease, box-shadow .12s ease, background .12s ease, color .12s ease;
}

#funcionarios .func-page-btn:hover{
  transform:translateY(-1px);
  background:#eff6ff;
  box-shadow:0 10px 18px rgba(37, 99, 235, 0.10);
}

#funcionarios .func-page-btn.is-active{
  background:linear-gradient(135deg, #2563eb, #3b82f6);
  color:#fff;
  border-color:transparent;
  box-shadow:0 10px 20px rgba(37, 99, 235, 0.22);
}

#funcionarios .func-page-btn.is-disabled{
  opacity:.45;
  cursor:not-allowed;
  box-shadow:none;
  transform:none;
}

#funcionarios .avatar{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:38px;
  height:38px;
  flex:0 0 38px;
  border-radius:50%;
  margin-right:0;
  background:linear-gradient(180deg,#eef4ff,#dfeafe);
  color:#1d4ed8;
  font-weight:800;
  font-size:12px;
  border:1px solid #cfe0ff;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.85),
    0 8px 18px rgba(37,99,235,.08);
}

#funcionarios .avatar svg{
  width:18px;
  height:18px;
  display:block;
}

#funcionarios .avatar-tone-blue{
  background:linear-gradient(180deg,#eef4ff,#dbeafe);
  color:#1d4ed8;
  border-color:#cfe0ff;
}

#funcionarios .avatar-tone-1,
#funcionarios .avatar-tone-2,
#funcionarios .avatar-tone-3,
#funcionarios .avatar-tone-4{
  background:linear-gradient(180deg,#eef4ff,#dbeafe);
  color:#1d4ed8;
  border-color:#cfe0ff;
}

#funcionarios .colab-cell{
  display:flex;
  align-items:center;
  gap:12px;
  min-width:0;
}

#funcionarios .colab-meta{
  display:flex;
  flex-direction:column;
  justify-content:center;
  min-width:0;
}

#funcionarios .colab-name{
  font-weight:800;
  font-size:14px;
  color:#0f172a;
  line-height:1.25;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

#funcionarios .colab-sub{
  margin-top:3px;
  font-size:12px;
  color:#64748b;
  line-height:1.2;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
#funcionarios table tbody td:nth-child(2),
#funcionarios table tbody td:nth-child(3){
  color:#334155;
}

#funcionarios .badge,
#funcionarios .status-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:30px;
  padding:0 12px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  letter-spacing:-0.01em;
  border:1px solid transparent;
}

#funcionarios .b-ok,
#funcionarios .status-badge.is-active{
  background:#ecfdf3;
  color:#0f8a5f;
  border-color:#a7f3d0;
}

#funcionarios .b-warn{
  background:#fff7ed;
  color:#9a3412;
  border-color:#fed7aa;
}

#funcionarios .b-bad{
  background:#fef2f2;
  color:#991b1b;
  border-color:#fecaca;
}

#funcionarios .b-neutral{
  background:#eff6ff;
  color:#1d4ed8;
  border-color:#dbeafe;
}

#funcionarios .b-muted{
  background:#f8fafc;
  color:#64748b;
  border-color:#e2e8f0;
}

#funcionarios .mono{
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size:13px;
  color:#475569;
}

#funcionarios .row-actions{
  text-align:right;
  white-space:nowrap;
}

#funcionarios .action-wrap{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:8px;
}

#funcionarios .icon-btn{
  appearance:none;
  width:34px;
  height:34px;
  padding:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:10px;
  border:1px solid #dbe3ee;
  background:#fff;
  color:#2563eb;
  cursor:pointer;
  box-shadow:none;
  transition:
    transform .14s ease,
    box-shadow .16s ease,
    border-color .16s ease,
    background .16s ease,
    color .16s ease;
  font-size:14px;
  line-height:1;
}

#funcionarios .icon-btn:hover{
  transform:translateY(-1px);
  border-color:#bfdbfe;
  background:#f8fbff;
  color:#1d4ed8;
}

#funcionarios .action-wrap .icon-btn.delete{
  border-color:#fecaca;
  color:#b91c1c;
  background:#fff;
}

#gestaoGerentes .func-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:14px;
}

#gestaoGerentes .func-header__titles{
  display:flex;
  flex-direction:column;
  gap:6px;
}

#gestaoGerentes .func-title{
  margin:0;
  font-size:20px;
  color:#0f172a;
  letter-spacing:-0.02em;
}

#gestaoGerentes .func-subtitle{
  color:#475569;
  font-size:13px;
}

#gestaoGerentes .func-header__actions{
  display:flex;
  gap:10px;
  align-items:center;
}

#gestaoGerentes .btn{
  display:inline-flex;
  align-items:center;
  gap:6px;
  border:1px solid #dbe3ee;
  background:#fff;
  border-radius:12px;
  padding:9px 12px;
  font-weight:800;
  color:#0f172a;
  cursor:pointer;
  transition:transform .15s ease, box-shadow .16s ease, background .15s ease;
}

#gestaoGerentes .btn:hover{
  transform:translateY(-1px);
  box-shadow:0 10px 24px rgba(15,23,42,.10);
}

#gestaoGerentes .btn--primary{
  background:linear-gradient(135deg,#1e4a6c,#2563eb);
  color:#fff;
  border-color:transparent;
  box-shadow:0 12px 28px rgba(37,99,235,.25);
}

#gestaoGerentes .func-toolbar-bottom{
  display:flex;
  align-items:center;
  gap:12px;
  margin-bottom:12px;
}

#gestaoGerentes .ctrl{
  width:100%;
  max-width:360px;
}

#gestaoGerentes .func-panel{
  background:#fff;
  border:1px solid #e5eaf0;
  border-radius:16px;
  box-shadow:0 18px 42px rgba(15,23,42,.10);
  padding:12px;
}

#gestaoGerentes .table-wrap{
  width:100%;
  overflow:auto;
}

#gestaoGerentes .func-table{
  width:100%;
  border-collapse:collapse;
}

#gestaoGerentes .func-table th,
#gestaoGerentes .func-table td{
  padding:12px;
  text-align:left;
  border-bottom:1px solid #e5eaf0;
}

#gestaoGerentes .gg-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:4px 10px;
  border-radius:999px;
  font-weight:800;
  font-size:12px;
  border:1px solid transparent;
}

#gestaoGerentes .gg-badge--estoque{
  background:#eff6ff;
  border-color:#dbeafe;
  color:#1d4ed8;
}

#gestaoGerentes .gg-badge--func{
  background:#eef2ff;
  border-color:#e0e7ff;
  color:#4f46e5;
}

#gestaoGerentes .gg-badge--ok{
  background:#ecfdf3;
  border-color:#bbf7d0;
  color:#15803d;
}

#gestaoGerentes .gg-badge--muted{
  background:#f8fafc;
  border-color:#e2e8f0;
  color:#64748b;
}

#gestaoGerentes .gg-badge--off{
  background:#fff7ed;
  border-color:#fed7aa;
  color:#9a3412;
}

#gestaoGerentes .gg-actions{
  display:flex;
  gap:8px;
  justify-content:flex-end;
}

#gestaoGerentes .gg-action{
  height:32px;
  padding:0 10px;
  font-size:12px;
}

#cadGerenteOverlay{
  backdrop-filter: blur(3px);
}

#cadGerenteModal{
  border-radius: 18px;
}

#cadGerenteModal .cad-gerente-shell{
  background: #fff;
  border: 1px solid #e5eaf0;
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(15,23,42,.18);
  padding: 20px;
}

#cadGerenteModal .cad-gerente-top{
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

#cadGerenteModal .cad-gerente-title{
  margin: 0;
  font-size: 22px;
  color: #0f172a;
  letter-spacing: -.02em;
}

#cadGerenteModal .cad-gerente-subtitle{
  margin-top: 4px;
  color: #64748b;
  font-size: 13px;
}

#cadGerenteModal .cad-gerente-grid{
  display: grid;
  gap: 10px;
}

#cadGerenteModal .cad-gerente-label{
  font-size: 13px;
  font-weight: 800;
  color: #334155;
}

#cadGerenteModal .cad-gerente-field{
  width: 100%;
  min-height: 42px;
  border: 1px solid #dbe3ee;
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
  color: #0f172a;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}

#cadGerenteModal .cad-gerente-field:focus{
  border-color: #60a5fa;
  box-shadow: 0 0 0 4px rgba(96,165,250,.18);
}

#cadGerenteModal .cad-gerente-perms{
  display: grid;
  gap: 10px;
  margin-top: 6px;
  padding: 12px;
  background: #f8fafc;
  border: 1px solid #e5eaf0;
  border-radius: 14px;
}

#cadGerenteModal .ck-line{
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 700;
  color: #1e293b;
}

#cadGerenteModal .ck-line input[type="checkbox"]{
  width: 16px;
  height: 16px;
  accent-color: #2563eb;
}

#cadGerenteModal .cad-gerente-actions{
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
}

#cadGerenteModal .cad-gerente-msg{
  min-height: 20px;
  color: #475569;
  font-size: 13px;
  font-weight: 700;
}

@media (max-width: 980px){
  #funcionarios .func-header{
    align-items:stretch;
  }

  #funcionarios .func-header__actions{
    width:100%;
    justify-content:flex-start;
  }

  #funcionarios .func-toolbar-bottom{
    flex-direction:column;
    align-items:stretch;
  }

  #funcionarios .ctrl--search{
    min-width:0;
    max-width:none;
  }
}

@media (max-width: 640px){
  #funcionarios .func-panel{
    border-radius:14px;
  }

  #funcionarios .func-table thead th{
    padding:12px 14px;
    font-size:10px;
    top:8px;
  }

  #funcionarios .func-table tbody td{
    padding:12px 14px;
    font-size:13px;
  }

  #funcionarios .btn{
    width:100%;
    justify-content:center;
  }
}



/* ===================== NOVO COLABORADOR ===================== */

#novoColaborador {
  margin-top: 16px;
}

/* Header (título + subtítulo) */
#novoColaborador .novo-colab-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

#novoColaborador h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: #0f172a; /* mesmo tom da Home/Novo EPI */
}

#novoColaborador .novo-colab-subtitle {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #6b7280;
}

/* Card branco com formulário + biometria lado a lado */
#novoColaborador .novo-colab-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.06);
  padding: 16px 18px 18px;
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1.4fr);
  gap: 20px;
}

/* Em telas menores, vira uma coluna só */
@media (max-width: 900px) {
  #novoColaborador .novo-colab-card {
    grid-template-columns: 1fr;
  }
}

/* Layout do formulário */
#formNovoColaborador.novo-colab-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
}

/* Labels dos campos */
#formNovoColaborador label {
  font-size: 13px;
  font-weight: 500;
  color: #0f172a;
}

/* Inputs dos campos */
#formNovoColaborador input {
  width: 100%;
  box-sizing: border-box;
  border-radius: 8px;
  border: 1px solid #d1d5db;
  padding: 8px 10px;
  font-size: 14px;
  background: #f9fafb;
  outline: none;
  transition:
    border-color 0.12s ease,
    box-shadow 0.12s ease,
    background-color 0.12s ease;
}

#formNovoColaborador input:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
  background: #ffffff;
}

/* Botão Salvar com o mesmo estilo do + Cadastrar EPI */
#novoColaborador .novo-colab-save {
  grid-column: 1 / -1;
  justify-self: flex-end;
  margin-top: 4px;

  border: none;
  cursor: pointer;
  padding: 10px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;

  background: linear-gradient(135deg, #1d4ed8, #2563eb);
  color: #fff;
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.35);
  transition:
    transform 0.12s ease,
    box-shadow 0.12s ease,
    filter 0.12s ease;
}

#novoColaborador .novo-colab-save:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgba(37, 99, 235, 0.45);
}

#novoColaborador .novo-colab-save:active {
  transform: translateY(0);
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.35);
}

/* Bloco da biometria */
#novoColaborador .novo-colab-bio-title {
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 4px;
}

#novoColaborador .novo-colab-bio-text {
  font-size: 13px;
  color: #6b7280;
  margin: 0 0 10px 0;
}

/* Botões Digital / Facial */
#novoColaborador .novo-colab-bio-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 6px;
}

#novoColaborador .novo-colab-bio-btn {
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.18);
  cursor: pointer;
  transition:
    transform 0.12s ease,
    box-shadow 0.12s ease,
    filter 0.12s ease;
}

#novoColaborador .novo-colab-bio-btn:hover {
  filter: brightness(1.03);
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.25);
}

/* Mensagem da biometria */
#novoColaborador .novo-colab-msg {
  margin-top: 2px;
  font-size: 12px;
  color: #334155;
}


/* ===================== NOVO COLABORADOR COMO MODAL ===================== */

body.novo-colab-modal-lock{
  overflow: hidden;
}

#novoColaboradorOverlay.novo-colab-modal-overlay{
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.52);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  z-index: 880;
}

#novoColaboradorOverlay.novo-colab-modal-overlay.is-open{
  display: block;
}

#novoColaborador{
  position: relative;
}

#novoColaborador .novo-colab-modal-close{
  display: none;
}

#novoColaborador.novo-colab-modal-open{
  display: block !important;
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(980px, 94vw);
  max-height: 90vh;
  overflow: auto;
  margin-top: 0;
  padding: 4px;
  z-index: 890;
  background: transparent;
}

#novoColaborador.novo-colab-modal-open .novo-colab-header{
  padding-right: 48px;
}

#novoColaborador.novo-colab-modal-open .novo-colab-modal-close{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 0;
  right: 0;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 12px;
  background: rgba(255,255,255,0.96);
  color: #475569;
  box-shadow: 0 10px 24px rgba(15,23,42,0.18);
  cursor: pointer;
  z-index: 2;
  padding: 0;
  font-size: 22px;
  line-height: 1;
}

#novoColaborador.novo-colab-modal-open .novo-colab-modal-close:hover{
  background: #ffffff;
  color: #0f172a;
}

@media (max-width: 900px){
  #novoColaborador.novo-colab-modal-open{
    width: min(96vw, 96vw);
    max-height: 92vh;
  }
}



/* ===== Alertas premium refinados da aba Funcionários ===== */
body.func-dialog-lock{
  overflow:hidden;
}

#funcDialogOverlay{
  position:fixed;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:24px;
  background:rgba(15,23,42,.46);
  opacity:0;
  pointer-events:none;
  transition:opacity .18s ease;
  z-index:12000;
  backdrop-filter:blur(8px);
  -webkit-backdrop-filter:blur(8px);
}

#funcDialogOverlay.show{
  opacity:1;
  pointer-events:auto;
}

#funcDialogModal{
  width:min(430px, calc(100vw - 28px));
  display:grid;
  grid-template-columns:52px 1fr;
  gap:14px;
  background:linear-gradient(180deg,#ffffff 0%, #f8fbff 100%);
  border:1px solid #dbeafe;
  border-radius:24px;
  padding:18px 18px 16px;
  box-shadow:
    0 30px 70px rgba(2,6,23,.20),
    0 12px 28px rgba(37,99,235,.08);
  color:#0f172a;
  transform:translateY(10px) scale(.985);
  transition:transform .18s ease;
}

#funcDialogOverlay.show #funcDialogModal{
  transform:translateY(0) scale(1);
}

#funcDialogModal.func-dialog--danger{
  border-color:#fecaca;
  box-shadow:
    0 30px 70px rgba(2,6,23,.18),
    0 12px 28px rgba(239,68,68,.08);
}

#funcDialogModal.func-dialog--success{
  border-color:#bbf7d0;
  box-shadow:
    0 30px 70px rgba(2,6,23,.18),
    0 12px 28px rgba(16,185,129,.08);
}

#funcDialogIcon{
  width:52px;
  height:52px;
  border-radius:16px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(180deg,#eef4ff 0%, #e6efff 100%);
  color:#2563eb;
  border:1px solid #d7e5ff;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.95),
    0 8px 18px rgba(37,99,235,.08);
}

#funcDialogIcon svg{
  width:22px;
  height:22px;
  display:block;
}

#funcDialogModal.func-dialog--danger #funcDialogIcon{
  background:linear-gradient(180deg,#fff3f3 0%, #fff0f1 100%);
  color:#dc2626;
  border-color:#fecdd3;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.95),
    0 8px 18px rgba(220,38,38,.08);
}

#funcDialogModal.func-dialog--success #funcDialogIcon{
  background:linear-gradient(180deg,#effdf5 0%, #ebfbf3 100%);
  color:#059669;
  border-color:#a7f3d0;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.95),
    0 8px 18px rgba(5,150,105,.08);
}

.func-dialog__main{
  min-width:0;
  align-self:center;
}

.func-dialog__title{
  margin:1px 0 5px 0;
  font-size:18px;
  font-weight:800;
  line-height:1.15;
  letter-spacing:-.02em;
  color:#0f172a;
}

.func-dialog__text{
  margin:0;
  font-size:14px;
  line-height:1.55;
  color:#475569;
  white-space:pre-line;
}

.func-dialog__actions{
  grid-column:1 / -1;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:4px;
}

.func-dialog__btn{
  width:100%;
  height:42px;
  border-radius:14px;
  padding:0 16px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-size:14px;
  font-weight:700;
  cursor:pointer;
  transition:transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease, color .16s ease;
}

.func-dialog__btn:hover{
  transform:translateY(-1px);
}

.func-dialog__btn:focus-visible{
  outline:none;
  box-shadow:0 0 0 4px rgba(59,130,246,.18);
}

.func-dialog__btn--ghost{
  background:linear-gradient(180deg,#ffffff 0%, #f8fafc 100%);
  color:#334155;
  border:1px solid #dbe3ee;
  box-shadow:0 6px 14px rgba(15,23,42,.04);
}

.func-dialog__btn--ghost:hover{
  border-color:#cbd5e1;
  background:#f8fafc;
}

.func-dialog__btn--primary{
  color:#fff;
  border:1px solid transparent;
  background:linear-gradient(180deg,#3b82f6 0%, #2563eb 100%);
  box-shadow:0 12px 22px rgba(37,99,235,.24);
}

.func-dialog__btn--danger{
  color:#fff;
  border:1px solid transparent;
  background:linear-gradient(180deg,#ef4444 0%, #dc2626 100%);
  box-shadow:0 12px 22px rgba(220,38,38,.22);
}

.func-dialog__btn--success{
  color:#fff;
  border:1px solid transparent;
  background:linear-gradient(180deg,#10b981 0%, #059669 100%);
  box-shadow:0 12px 22px rgba(5,150,105,.22);
}

/* ===== Histórico premium da aba Funcionários ===== */
#histFuncOverlay{
  position:fixed;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:26px;
  background:rgba(15,23,42,.50);
  opacity:0;
  visibility:hidden;
  pointer-events:none;
  transition:opacity .18s ease, visibility .18s ease;
  z-index:11980;
  backdrop-filter:blur(8px);
  -webkit-backdrop-filter:blur(8px);
}

#histFuncOverlay.show{
  opacity:1;
  visibility:visible;
  pointer-events:auto;
}

#histFuncModal{
  width:min(1180px, 96vw);
  max-height:min(88vh, 920px);
  display:flex;
  flex-direction:column;
  overflow:hidden;
  background:linear-gradient(180deg,#ffffff 0%, #f8fbff 100%);
  border:1px solid #dbeafe;
  border-radius:26px;
  box-shadow:
    0 34px 80px rgba(2,6,23,.20),
    0 14px 36px rgba(37,99,235,.07);
  transform:translateY(12px) scale(.988);
  transition:transform .18s ease;
}

#histFuncOverlay.show #histFuncModal{
  transform:translateY(0) scale(1);
}

.hist-func-modal__header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:18px;
  padding:22px 24px 18px;
  border-bottom:1px solid #e9eef7;
  background:linear-gradient(180deg,#ffffff 0%, #fbfdff 100%);
}

.hist-func-modal__title{
  margin:0;
  font-size:28px;
  line-height:1.04;
  letter-spacing:-.03em;
  font-weight:800;
  color:#0f172a;
}

.hist-func-modal__subtitle{
  margin:8px 0 0 0;
  font-size:14px;
  line-height:1.55;
  color:#64748b;
}

.hist-func-modal__header-actions{
  display:flex;
  align-items:center;
  gap:10px;
  flex-shrink:0;
}

.hist-func-count{
  height:38px;
  padding:0 14px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  border:1px solid #dbeafe;
  background:#eff6ff;
  color:#1d4ed8;
  font-size:13px;
  font-weight:700;
  white-space:nowrap;
}

.hist-func-close{
  width:40px;
  height:40px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:12px;
  border:1px solid #dbe3ee;
  background:linear-gradient(180deg,#ffffff 0%, #f8fafc 100%);
  color:#334155;
  cursor:pointer;
  transition:transform .16s ease, border-color .16s ease, background .16s ease;
  box-shadow:0 8px 16px rgba(15,23,42,.04);
}

.hist-func-close:hover{
  transform:translateY(-1px);
  border-color:#cbd5e1;
  background:#f8fafc;
}

.hist-func-close svg{
  width:18px;
  height:18px;
  display:block;
}

.hist-func-toolbar{
  display:flex;
  align-items:center;
  gap:12px;
  padding:16px 24px 18px;
}

.hist-func-search{
  position:relative;
  flex:1;
  display:flex;
  align-items:center;
}

.hist-func-search svg{
  position:absolute;
  left:16px;
  width:18px;
  height:18px;
  color:#94a3b8;
  pointer-events:none;
}

.hist-func-search input{
  width:100%;
  height:48px;
  padding:0 16px 0 46px;
  border-radius:15px;
  border:1px solid #dbe3ee;
  background:linear-gradient(180deg,#ffffff 0%, #f8fbff 100%);
  color:#0f172a;
  font-size:14px;
  outline:none;
  transition:border-color .16s ease, box-shadow .16s ease, background .16s ease;
}

.hist-func-search input::placeholder{
  color:#94a3b8;
}

.hist-func-search input:focus{
  border-color:#93c5fd;
  box-shadow:0 0 0 4px rgba(59,130,246,.12);
  background:#fff;
}

.hist-func-content{
  min-height:220px;
  padding:0 24px 24px;
  overflow:auto;
}

.hist-func-table-wrap{
  border:1px solid #e6edf7;
  border-radius:22px;
  overflow:hidden;
  background:#fff;
  box-shadow:0 16px 34px rgba(15,23,42,.05);
}

.hist-func-table{
  width:100%;
  table-layout:fixed;
  border-collapse:separate;
  border-spacing:0;
}

.hist-func-table thead th{
  padding:16px 18px;
  text-align:left;
  font-size:12px;
  font-weight:800;
  letter-spacing:.08em;
  text-transform:uppercase;
  color:#334155;
  background:linear-gradient(180deg,#f8fbff 0%, #f1f6fd 100%);
  border-bottom:1px solid #e6edf7;
}

.hist-func-table tbody td{
  padding:16px 18px;
  vertical-align:top;
  border-bottom:1px solid #edf2f8;
  background:#fff;
}

.hist-func-table tbody tr:last-child td{
  border-bottom:none;
}

.hist-func-table tbody tr:hover td{
  background:#fbfdff;
}

.hist-func-table thead th:nth-child(1),
.hist-func-table tbody td:nth-child(1){
  width:14%;
}

.hist-func-table thead th:nth-child(2),
.hist-func-table tbody td:nth-child(2){
  width:16%;
}

.hist-func-table thead th:nth-child(3),
.hist-func-table tbody td:nth-child(3){
  width:16%;
}

.hist-func-table thead th:nth-child(4),
.hist-func-table tbody td:nth-child(4){
  width:16%;
}

.hist-func-table thead th:nth-child(5),
.hist-func-table tbody td:nth-child(5){
  width:18%;
}

.hist-func-date{
  display:grid;
  gap:4px;
}

.hist-func-date__day{
  font-size:14px;
  font-weight:700;
  color:#0f172a;
  line-height:1.3;
}

.hist-func-date__time{
  font-size:12px;
  color:#64748b;
  line-height:1.3;
}

.hist-func-person{
  display:grid;
  gap:4px;
  min-width:0;
}

.hist-func-person__name{
  font-size:14px;
  font-weight:700;
  color:#0f172a;
  line-height:1.35;
  word-break:break-word;
}

.hist-func-person__sub{
  font-size:12px;
  color:#64748b;
  line-height:1.45;
  word-break:break-word;
}

.hist-func-reason{
  font-size:13px;
  line-height:1.55;
  color:#475569;
  word-break:break-word;
  white-space:pre-line;
}

.hist-func-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:30px;
  padding:0 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  line-height:1;
  border:1px solid transparent;
  white-space:nowrap;
}

.hist-func-badge--blue{
  background:#eff6ff;
  color:#1d4ed8;
  border-color:#dbeafe;
}

.hist-func-badge--green{
  background:#ecfdf5;
  color:#047857;
  border-color:#bbf7d0;
}

.hist-func-badge--red{
  background:#fff1f2;
  color:#dc2626;
  border-color:#fecdd3;
}

.hist-func-badge--amber{
  background:#fffbeb;
  color:#b45309;
  border-color:#fde68a;
}

.hist-func-badge--violet{
  background:#f5f3ff;
  color:#6d28d9;
  border-color:#ddd6fe;
}

.hist-func-badge--slate{
  background:#f8fafc;
  color:#475569;
  border-color:#e2e8f0;
}

.hist-func-empty{
  min-height:220px;
  display:grid;
  place-items:center;
  padding:18px;
}

.hist-func-empty__card{
  width:min(460px,100%);
  text-align:center;
  padding:28px 24px;
  border-radius:22px;
  border:1px solid #e6edf7;
  background:linear-gradient(180deg,#ffffff 0%, #f8fbff 100%);
  box-shadow:0 16px 34px rgba(15,23,42,.05);
}

.hist-func-empty__icon{
  width:56px;
  height:56px;
  margin:0 auto 14px;
  border-radius:18px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#eff6ff;
  color:#2563eb;
  border:1px solid #dbeafe;
}

.hist-func-empty--danger .hist-func-empty__icon{
  background:#fff1f2;
  color:#dc2626;
  border-color:#fecdd3;
}

.hist-func-empty__icon svg{
  width:24px;
  height:24px;
  display:block;
}

.hist-func-empty__title{
  margin:0 0 6px 0;
  font-size:18px;
  font-weight:800;
  color:#0f172a;
}

.hist-func-empty__text{
  margin:0;
  font-size:14px;
  line-height:1.6;
  color:#64748b;
}

.hist-func-skeleton{
  height:58px;
  border-radius:16px;
  margin-bottom:12px;
  background:linear-gradient(90deg,#f3f7fd 0%, #eef4fb 50%, #f3f7fd 100%);
  background-size:200% 100%;
  animation:histFuncShimmer 1.1s linear infinite;
  border:1px solid #e8eef7;
}

.hist-func-skeleton--short{
  width:72%;
}

@keyframes histFuncShimmer{
  from{ background-position:200% 0; }
  to{ background-position:-200% 0; }
}

@media (max-width: 980px){
  #histFuncOverlay{
    padding:16px;
  }

  #histFuncModal{
    width:min(100%, 1000px);
    max-height:90vh;
    border-radius:22px;
  }

  .hist-func-modal__header{
    flex-direction:column;
    align-items:flex-start;
  }

  .hist-func-modal__header-actions{
    width:100%;
    justify-content:space-between;
  }

  .hist-func-toolbar{
    padding:14px 18px 16px;
  }

  .hist-func-content{
    padding:0 18px 18px;
  }

  .hist-func-table-wrap{
    overflow:auto;
  }

  .hist-func-table{
    min-width:980px;
  }
}

@media (max-width: 640px){
  .hist-func-modal__title{
    font-size:24px;
  }

  .hist-func-modal__subtitle{
    font-size:13px;
  }

  .hist-func-count{
    font-size:12px;
    padding:0 12px;
  }

  .hist-func-search input{
    height:44px;
  }
}
