/* PROYECOM V4.9.124 · Editor de empleado responsivo + scroll vertical seguro */

/* Solo afecta la ventana EDITAR / NUEVO EMPLEADO. */
.drawer.employeeFull{
  position:fixed!important;
  top:8px!important;
  right:8px!important;
  bottom:8px!important;
  left:8px!important;
  width:auto!important;
  max-width:none!important;
  height:auto!important;
  max-height:calc(100dvh - 16px)!important;
  min-height:0!important;
  border-radius:14px!important;
  overflow:hidden!important;
  display:flex!important;
  flex-direction:column!important;
}
.drawer.employeeFull.open{right:8px!important}

.drawer.employeeFull .drawerHead{
  flex:0 0 auto!important;
  min-height:44px!important;
  position:relative!important;
  z-index:80!important;
  background:#fff!important;
}

.drawer.employeeFull .drawerBody{
  flex:1 1 auto!important;
  min-height:0!important;
  height:0!important;
  max-height:none!important;
  overflow:hidden!important;
  padding:8px 18px 0!important;
  display:block!important;
}

.drawer.employeeFull #empForm{
  width:100%!important;
  height:100%!important;
  min-height:0!important;
  max-height:100%!important;
  margin:0!important;
  padding:0!important;
  display:grid!important;
  grid-template-columns:minmax(0,1fr)!important;
  grid-template-rows:auto auto minmax(0,1fr) auto!important;
  overflow:hidden!important;
}

.drawer.employeeFull #empForm > .employeeHero{
  grid-row:1!important;
  min-height:0!important;
  margin:0!important;
  padding:4px 0 8px!important;
  flex:0 0 auto!important;
}

.drawer.employeeFull #empForm > .formTabs{
  grid-row:2!important;
  min-height:0!important;
  margin:0 0 6px!important;
  padding:2px 0 5px!important;
  display:flex!important;
  flex-wrap:nowrap!important;
  gap:4px!important;
  overflow-x:auto!important;
  overflow-y:hidden!important;
  scrollbar-width:thin!important;
  overscroll-behavior-x:contain!important;
  -webkit-overflow-scrolling:touch!important;
  background:#fff!important;
  z-index:30!important;
}
.drawer.employeeFull #empForm > .formTabs button{
  flex:0 0 auto!important;
  white-space:nowrap!important;
}

.drawer.employeeFull #empForm > .formPane:not([hidden]){
  grid-row:3!important;
  min-height:0!important;
  height:100%!important;
  max-height:100%!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  overscroll-behavior:contain!important;
  scrollbar-gutter:stable!important;
  scrollbar-width:thin!important;
  -webkit-overflow-scrolling:touch!important;
  padding:6px 8px 18px 0!important;
}
.drawer.employeeFull #empForm > .formPane[hidden]{display:none!important}

.drawer.employeeFull #empForm > .drawerFoot{
  grid-row:4!important;
  position:relative!important;
  bottom:auto!important;
  left:auto!important;
  right:auto!important;
  flex:0 0 auto!important;
  min-height:50px!important;
  margin:0!important;
  padding:8px 2px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-end!important;
  flex-wrap:wrap!important;
  gap:7px!important;
  background:#fff!important;
  border-top:1px solid #dce6f2!important;
  box-shadow:0 -5px 14px rgba(20,45,75,.07)!important;
  z-index:60!important;
}
.drawer.employeeFull #empForm > .drawerFoot button{
  min-height:34px!important;
  margin:0!important;
}

/* Permisos: aprovecha ancho disponible y nunca obliga a reducir zoom. */
.drawer.employeeFull .permissionExpanded{
  width:100%!important;
  max-width:none!important;
  min-width:0!important;
  min-height:0!important;
}
.drawer.employeeFull .permissionExpanded .portalAccessHead{
  position:static!important;
  padding:4px 0 6px!important;
}
.drawer.employeeFull .permissionToolbar{
  margin:5px 0!important;
  padding:5px 7px!important;
  gap:5px!important;
  flex-wrap:wrap!important;
}
.drawer.employeeFull .permissionToolbar button{
  min-height:28px!important;
  padding:4px 8px!important;
  font-size:11px!important;
}
.drawer.employeeFull .permissionExpanded .setupNotice{
  margin:5px 0!important;
  padding:7px 9px!important;
}
.drawer.employeeFull .permissionExpanded .field.wide{margin:5px 0 7px!important}
.drawer.employeeFull .permissionExpanded #permissionGroups{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:7px!important;
  align-items:start!important;
}
.drawer.employeeFull .permissionExpanded .permGroup{
  min-width:0!important;
  margin:0!important;
  padding:7px!important;
  border-radius:9px!important;
  box-shadow:none!important;
}
.drawer.employeeFull .permissionExpanded .permGroup h4{
  margin:0 0 5px!important;
  font-size:11.5px!important;
  line-height:1.15!important;
}
.drawer.employeeFull .permissionExpanded .permGrid{
  display:grid!important;
  grid-template-columns:1fr!important;
  gap:3px!important;
}
.drawer.employeeFull .permissionExpanded .permItem{
  min-height:0!important;
  padding:5px 6px!important;
  gap:5px!important;
  border-radius:6px!important;
  align-items:center!important;
}
.drawer.employeeFull .permissionExpanded .permItem input{
  width:15px!important;
  height:15px!important;
  min-height:15px!important;
  margin:0!important;
  flex:0 0 auto!important;
}
.drawer.employeeFull .permissionExpanded .permItem span{min-width:0!important}
.drawer.employeeFull .permissionExpanded .permItem b{
  font-size:10px!important;
  line-height:1.15!important;
}
.drawer.employeeFull .permissionExpanded .permItem small{display:none!important}
.drawer.employeeFull .permissionExpanded .portalActions{
  position:static!important;
  margin-top:7px!important;
  padding:8px 0 3px!important;
  background:#fff!important;
}

@media (max-width:1400px){
  .drawer.employeeFull .permissionExpanded #permissionGroups{grid-template-columns:repeat(3,minmax(0,1fr))!important}
}
@media (max-width:1050px){
  .drawer.employeeFull{top:5px!important;right:5px!important;bottom:5px!important;left:5px!important;max-height:calc(100dvh - 10px)!important}
  .drawer.employeeFull.open{right:5px!important}
  .drawer.employeeFull .drawerBody{padding:6px 12px 0!important}
  .drawer.employeeFull .permissionExpanded #permissionGroups{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@media (max-width:700px){
  .drawer.employeeFull{
    inset:0!important;
    width:100vw!important;
    height:100svh!important;
    max-height:100svh!important;
    border-radius:0!important;
  }
  .drawer.employeeFull.open{right:0!important}
  .drawer.employeeFull .drawerHead{min-height:42px!important}
  .drawer.employeeFull .drawerBody{padding:4px 10px 0!important}
  .drawer.employeeFull #empForm > .employeeHero{padding:3px 0 6px!important}
  .drawer.employeeFull #empForm > .formPane:not([hidden]){padding:4px 0 12px!important}
  .drawer.employeeFull #empForm > .drawerFoot{
    min-height:0!important;
    padding:6px 0!important;
    gap:5px!important;
  }
  .drawer.employeeFull #empForm > .drawerFoot button{
    flex:1 1 calc(50% - 5px)!important;
    min-width:128px!important;
    min-height:40px!important;
  }
  .drawer.employeeFull .permissionExpanded #permissionGroups{grid-template-columns:1fr!important}
  .drawer.employeeFull .permissionToolbar span{width:100%!important;margin-left:0!important}
  .drawer.employeeFull .permissionExpanded .permItem{padding:7px 8px!important}
  .drawer.employeeFull .permissionExpanded .permItem b{font-size:11px!important}
}
