/* Buttons, inputs */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.35rem;
  padding:.62rem .96rem;
  border-radius:999px;
  border:1px solid color-mix(in srgb,var(--color-primary) 28%, var(--color-border));
  background:linear-gradient(180deg,color-mix(in srgb,var(--color-primary) 9%, var(--color-surface)),color-mix(in srgb,var(--color-primary) 6%, var(--color-surface-alt)));
  color:var(--color-primary-600);
  cursor:pointer;
  box-shadow:var(--shadow-soft);
  transition:transform .16s ease,box-shadow .16s ease,border-color .16s ease,background .16s ease
}
.btn:hover{
  transform:translateY(-1px);
  border-color:color-mix(in srgb,var(--color-primary) 24%, var(--color-border));
  box-shadow:0 14px 26px rgba(13,44,77,.1)
}
.btn--primary{
  background:linear-gradient(135deg,var(--color-primary) 0%,color-mix(in srgb,var(--color-primary) 72%, #ffffff) 100%);
  color:#fff;
  border-color:transparent
}
.btn--primary:hover{background:linear-gradient(135deg,var(--color-primary-600) 0%,var(--color-primary) 100%)}
.btn--danger{background:linear-gradient(135deg,#dc2626,#b91c1c);color:#fff;border-color:transparent}
.btn--icon{width:34px;height:34px;padding:0;font-size:.95rem;line-height:1}
.btn:disabled,
.btn[aria-disabled="true"]{
  border-color:#cfd8e3;
  background:linear-gradient(180deg,#f1f4f7,#e4e9ef);
  color:#7a8793;
  cursor:not-allowed;
  box-shadow:none;
  filter:grayscale(1);
  opacity:1
}
.btn:disabled:hover,
.btn[aria-disabled="true"]:hover{
  transform:none;
  border-color:#cfd8e3;
  background:linear-gradient(180deg,#f1f4f7,#e4e9ef);
  box-shadow:none
}
.btn:disabled .app-inline-icon,
.btn[aria-disabled="true"] .app-inline-icon{
  color:#7a8793
}
.app-inline-icon{
  display:inline-grid;
  place-items:center;
  width:18px;
  height:18px;
  line-height:1
}
.app-inline-icon__fallback{
  display:inline-grid;
  place-items:center;
  width:18px;
  height:18px;
  font-size:.95rem;
  font-weight:800;
  line-height:1
}
.app-inline-icon__svg{
  display:none
}
.app-inline-icon.has-lucide-svg .app-inline-icon__fallback{
  display:none
}
.app-inline-icon:has(svg) .app-inline-icon__fallback{
  display:none
}
.app-inline-icon.has-lucide-svg svg{
  display:block;
  width:18px;
  height:18px
}
.app-inline-icon:has(svg) svg{
  display:block;
  width:18px;
  height:18px
}
.input,.select{
  display:block;
  width:100%;
  max-width:420px;
  padding:.68rem .82rem;
  border:1px solid var(--color-border);
  border-radius:14px;
  background:rgba(255,255,255,.82);
  color:var(--color-fg);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.62)
}
.select{max-width:260px}

/* Select with a search box (utils/searchSelect.js) */
.search-select{position:relative;width:100%;max-width:260px;min-width:0}
.search-select::after{content:'';position:absolute;right:.95rem;top:1.15rem;width:.42rem;height:.42rem;border-right:2px solid var(--color-muted);border-bottom:2px solid var(--color-muted);transform:rotate(45deg);pointer-events:none}
.search-select__native{display:none!important}
/* The input fills its box: the arrow (::after) is drawn at the box's right edge, so a wider box keeps it inside the field. */
.search-select__input{padding-right:2.2rem;text-overflow:ellipsis;max-width:none}
.search-select__list{position:absolute;z-index:40;left:0;right:0;top:calc(100% + 4px);max-height:240px;overflow:auto;margin:0;padding:.3rem;list-style:none;background:var(--color-surface);border:1px solid var(--color-border);border-radius:12px;box-shadow:var(--shadow-soft)}
.search-select__option{padding:.5rem .65rem;border-radius:8px;cursor:pointer;color:var(--color-fg);overflow-wrap:anywhere}
.search-select__option:hover,.search-select__option.is-active{background:var(--color-primary-soft)}
.search-select__option[aria-selected="true"]{font-weight:700}
.search-select__empty{padding:.5rem .65rem;color:var(--color-muted)}
/* In a modal the list opens inline: the modal body scrolls and would cut a floating list. */
.action-modal .search-select,.action-modal .search-select__input{max-width:none}
.action-modal .search-select__list{position:static;margin-top:.3rem}
.label{font-size:.9rem;color:var(--color-muted)}
.role-badge{
  display:inline-flex;
  align-items:center;
  padding:.34rem .72rem;
  border-radius:999px;
  border:1px solid color-mix(in srgb,var(--color-primary) 24%, var(--color-border));
  font-size:.74rem;
  color:var(--color-primary-600);
  background:linear-gradient(180deg,rgba(255,255,255,.9),rgba(237,244,250,.92))
}
.header .role-badge{
  border-color:color-mix(in srgb,var(--color-primary) 22%, var(--header-border));
  color:var(--header-fg);
  background:color-mix(in srgb,var(--color-primary) 12%, rgba(255,255,255,.74))
}

/* Table */
.table-wrap{overflow-x:auto;border-radius:18px}
.table{
  width:100%;
  border-collapse:separate;
  border-spacing:0;
  min-width:860px;
  overflow:hidden;
  background:rgba(255,255,255,.7);
  border:1px solid rgba(255,255,255,.65);
  border-radius:18px
}
.table th,.table td{border-bottom:1px solid var(--color-border);padding:.76rem .65rem;text-align:left}
.table th{
  font-size:.78rem;
  color:var(--color-muted);
  text-transform:uppercase;
  letter-spacing:.08em
}
.table thead th{
  background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(233,241,248,.95));
  border-top:0;
  box-shadow:inset 0 -1px 0 rgba(47,154,71,.22), inset 0 1px 0 rgba(47,154,71,.08);
  text-shadow:0 1px 10px rgba(47,154,71,.12)
}
.table thead th:first-child{border-top-left-radius:18px}
.table thead th:last-child{border-top-right-radius:18px}
.table tbody tr:last-child td{border-bottom:none}
.table tr:hover{background:color-mix(in srgb,var(--color-primary) 7%, rgba(255,255,255,.28))}

/* App notifications */
.app-notices{
  position:fixed;
  top:1rem;
  right:1rem;
  z-index:11000;
  display:grid;
  gap:.62rem;
  width:min(420px,calc(100vw - 2rem));
  pointer-events:none
}
.app-notice{
  display:grid;
  grid-template-columns:auto 1fr auto;
  align-items:flex-start;
  gap:.7rem;
  padding:.82rem .88rem;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.75);
  background:linear-gradient(180deg,rgba(255,255,255,.98),rgba(238,245,250,.96));
  box-shadow:0 18px 34px rgba(13,44,77,.18);
  color:var(--color-fg);
  pointer-events:auto;
  animation:notice-in .16s ease-out both
}
.app-notice.is-leaving{animation:notice-out .16s ease-in both}
.app-notice__marker{
  width:.72rem;
  height:.72rem;
  margin-top:.24rem;
  border-radius:999px;
  background:var(--color-primary)
}
.app-notice--success .app-notice__marker{background:#16a34a}
.app-notice--warning .app-notice__marker{background:#f59e0b}
.app-notice--error .app-notice__marker{background:#dc2626}
.app-notice__body{display:grid;gap:.15rem;min-width:0}
.app-notice__title{font-size:.82rem;color:var(--color-fg)}
.app-notice__message{font-size:.88rem;line-height:1.35;color:var(--color-muted);overflow-wrap:anywhere}
.app-notice__close{
  width:28px;
  height:28px;
  border:0;
  border-radius:999px;
  background:transparent;
  color:var(--color-muted);
  cursor:pointer;
  font-size:.95rem;
  line-height:1
}
.app-notice__close:hover{
  background:color-mix(in srgb,var(--color-primary) 9%, transparent);
  color:var(--color-fg)
}
@keyframes notice-in{
  from{opacity:0;transform:translateY(-8px) scale(.98)}
  to{opacity:1;transform:translateY(0) scale(1)}
}
@keyframes notice-out{
  from{opacity:1;transform:translateY(0) scale(1)}
  to{opacity:0;transform:translateY(-6px) scale(.98)}
}
/* "Cargando informacion…" (utils/loadingIndicator.js): a bar on the top edge and a small label. It never takes clicks
   nor covers the page: pointer-events none, only the top edge and a label under it. */
.app-loading{
  position:fixed;
  inset:0 0 auto 0;
  z-index:10990;
  pointer-events:none;
  display:flex;
  justify-content:center
}
.app-loading[hidden]{display:none}
.app-loading__bar{
  position:absolute;
  inset:0 0 auto 0;
  height:3px;
  background:linear-gradient(90deg,transparent 0%,var(--color-primary) 35%,var(--color-primary) 65%,transparent 100%);
  background-size:40% 100%;
  background-repeat:no-repeat;
  animation:app-loading-slide 1.1s ease-in-out infinite
}
.app-loading__text{
  margin-top:8px;
  padding:.28rem .75rem;
  border-radius:999px;
  background:color-mix(in srgb,var(--color-primary) 10%, #ffffff);
  border:1px solid color-mix(in srgb,var(--color-primary) 22%, transparent);
  box-shadow:0 6px 16px rgba(13,44,77,.12);
  color:var(--color-fg);
  font-size:.8rem;
  line-height:1.2
}
@keyframes app-loading-slide{
  from{background-position:-40% 0}
  to{background-position:140% 0}
}
@media (prefers-reduced-motion: reduce){
  .app-loading__bar{animation:none;background:var(--color-primary);opacity:.6}
}

/* Sidebar */
.sidebar__shell{
  height:100vh;
  min-height:0;
  display:grid;
  grid-template-columns:76px minmax(0,1fr);
  background:var(--sidebar-bg);
  color:var(--sidebar-fg)
}
.sidebar__rail{
  height:100vh;
  min-height:0;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:.8rem;
  padding:.85rem .55rem;
  background:linear-gradient(180deg,#082846 0%,#062036 52%,#041827 100%);
  color:#eaf7ff;
  border-right:1px solid rgba(255,255,255,.1);
  box-shadow:inset -1px 0 0 rgba(255,255,255,.08)
}
.sidebar__rail-contracts{
  min-height:0;
  width:100%;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:.58rem;
  padding:.42rem 0;
  overflow-y:auto
}
.sidebar__rail-bottom{
  width:100%;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:.58rem;
  margin-top:auto;
  padding-top:.8rem;
  border-top:1px solid rgba(255,255,255,.16)
}
.sidebar__rail-btn{
  width:48px;
  height:48px;
  display:inline-grid;
  place-items:center;
  border:1px solid rgba(255,255,255,.1);
  border-radius:14px;
  background:rgba(255,255,255,.08);
  color:#dceffc;
  cursor:pointer;
  position:relative;
  transition:background .16s ease,border-color .16s ease,box-shadow .16s ease,transform .16s ease
}
.sidebar__rail-btn:hover{
  background:rgba(255,255,255,.14);
  border-color:rgba(255,255,255,.22);
  transform:translateY(-1px)
}
.sidebar__rail-btn.is-active{
  background:linear-gradient(135deg,#18a4b8,#2f9a70);
  color:#fff;
  border-color:rgba(255,255,255,.34);
  box-shadow:0 12px 28px rgba(0,0,0,.24)
}
.sidebar__rail-btn.is-active::before{
  content:"";
  position:absolute;
  left:-.55rem;
  top:50%;
  width:3px;
  height:28px;
  border-radius:999px;
  background:#fff;
  transform:translateY(-50%)
}
.sidebar__rail-logo{
  margin-bottom:.2rem;
  background:rgba(255,255,255,.14);
  border-color:rgba(255,255,255,.2)
}
.sidebar__rail-icon,
.sidebar__rail-avatar{
  width:28px;
  height:28px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:10px;
  font-size:.68rem;
  font-weight:800;
  letter-spacing:.04em
}
.sidebar__rail-avatar{
  background:rgba(255,255,255,.14);
  color:#fff
}
.sidebar__panel{
  min-width:0;
  height:100vh;
  min-height:0;
  overflow-y:auto;
  overscroll-behavior:contain;
  padding:1.05rem .95rem 1rem;
  background:linear-gradient(180deg,rgba(255,255,255,.92),rgba(246,250,253,.9));
  backdrop-filter:blur(18px)
}
.sidebar__panel>.sidebar__nav-link{
  margin-bottom:.26rem
}
.sidebar__panel>.sidebar__subsection{
  margin-top:.55rem
}
.sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__shell{
  grid-template-columns:78px 0
}
.sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__panel{
  display:none
}
.sidebar__project-head{
  display:grid;
  gap:.28rem;
  padding:.25rem .18rem 1rem;
  border-bottom:1px solid var(--sidebar-border);
  margin-bottom:.95rem
}
.sidebar__project-kicker{
  color:var(--sidebar-muted);
  font-size:.72rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.12em
}
.sidebar__project-title{
  color:var(--sidebar-fg);
  font-size:1.04rem;
  line-height:1.2;
  overflow-wrap:anywhere
}
.sidebar__project-title-link{
  color:var(--sidebar-fg);
  text-decoration:none;
  border-radius:4px
}
.sidebar__project-title-link:hover{
  text-decoration:underline;
  text-underline-offset:3px
}
.sidebar__project-title-link:focus-visible{
  outline:2px solid currentColor;
  outline-offset:4px
}
.sidebar__project-meta{
  color:var(--sidebar-muted);
  font-size:.82rem;
  line-height:1.25;
  overflow-wrap:anywhere
}
.sidebar__project-head--settings .sidebar__project-title{
  color:var(--color-primary-600)
}

.sidebar__section{margin-top:1rem}
.sidebar__section-title{
  font-family:inherit;
  font-size:.76rem;
  color:var(--sidebar-muted);
  text-transform:uppercase;
  letter-spacing:.12em;
  margin-bottom:.28rem;
  font-weight:700
}
.sidebar__section-heading{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.5rem;
  padding:.25rem .1rem;
  margin-bottom:.32rem
}
.sidebar__section-link{
  font-family:inherit;
  min-width:0;
  display:flex;
  align-items:center;
  gap:.42rem;
  background:transparent;
  border:0;
  padding:0;
  color:inherit;
  cursor:pointer;
  text-align:left;
  text-transform:inherit;
  letter-spacing:inherit;
  font-size:inherit;
  font-weight:inherit
}
.sidebar__section-link:hover,
.sidebar__section-link.is-active{
  color:var(--color-primary-600)
}
.sidebar__section-toggle{
  width:2.25rem;
  height:2.25rem;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 2.25rem;
  border:0;
  border-radius:10px;
  background:transparent;
  color:var(--sidebar-muted);
  cursor:pointer;
  padding:0
}
.sidebar__section-toggle:hover{
  background:var(--sidebar-hover);
  color:var(--sidebar-fg)
}
.sidebar__section-title-content,
.sidebar__subsection-title-content{
  display:inline-flex;
  align-items:center;
  gap:.42rem;
  min-width:0
}
.sidebar__section-icon,
.sidebar__subsection-icon{
  width:1.35rem;
  height:1.35rem;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:8px;
  background:color-mix(in srgb,var(--color-primary) 9%, transparent);
  color:var(--color-primary-600);
  flex:0 0 1.35rem
}
.sidebar__section-toggle-glyph{font-size:.9rem;line-height:1;transition:transform .15s ease}
.sidebar__section.is-collapsed .sidebar__section-toggle-glyph{transform:rotate(-90deg)}
.sidebar__section.is-collapsed .sidebar__nav{display:none}
.sidebar__nav{display:flex;flex-direction:column;gap:.32rem}
.sidebar__subsection{
  display:grid;
  gap:.24rem;
  padding:.2rem 0 .1rem
}
.sidebar__subsection-title{
  font-family:inherit;
  width:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.45rem;
  padding:.36rem .74rem .28rem .74rem;
  border:0;
  background:transparent;
  color:var(--sidebar-muted);
  cursor:pointer;
  font-size:.95rem;
  font-weight:500;
  line-height:1.15;
  text-align:left
}
.sidebar__subsection-title:hover,
.sidebar__subsection-title.is-active{
  color:var(--color-primary-600)
}
.sidebar__subsection-toggle::after{content:'▾';font-size:.78rem;color:var(--sidebar-muted);transition:transform .15s ease}
.sidebar__subsection.is-collapsed .sidebar__subsection-toggle::after{transform:rotate(-90deg)}
.sidebar__subsection.is-collapsed .sidebar__subnav{display:none}
.sidebar__subnav{
  display:flex;
  flex-direction:column;
  gap:.24rem;
  padding-left:0
}
.sidebar__subnav .sidebar__nav-link{
  font-size:.9rem;
  padding-top:.54rem;
  padding-bottom:.54rem;
  margin-left:.42rem
}
.sidebar__nav-link{
  font-family:inherit;
  display:flex;
  align-items:center;
  gap:.7rem;
  position:relative;
  padding:.62rem .74rem;
  border-radius:16px;
  color:var(--sidebar-fg);
  transition:background .15s ease,transform .15s ease,color .15s ease
}
.sidebar__nav-link:hover{
  background:var(--sidebar-hover);
  transform:translateX(2px)
}
.sidebar__nav-link.is-active{
  background:linear-gradient(90deg,rgba(11,99,188,.14),rgba(47,154,71,.12));
  color:var(--color-primary-600);
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.55)
}
.sidebar__item-icon{
  width:30px;
  height:30px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:12px;
  background:linear-gradient(180deg,#ffffff,#eaf2f8);
  border:1px solid color-mix(in srgb,var(--color-primary) 18%, var(--color-border));
  font-size:.66rem;
  font-weight:800;
  letter-spacing:.04em;
  color:var(--color-primary-600);
  flex:0 0 30px
}
.sidebar__icon-fallback{
  font-size:.66rem;
  font-weight:800;
  letter-spacing:.04em
}
.sidebar__icon-svg{
  display:none;
  width:18px;
  height:18px
}
.has-lucide-icons .has-lucide-svg .sidebar__icon-fallback{display:none}
.has-lucide-icons .has-lucide-svg .sidebar__icon-svg,
.has-lucide-icons .has-lucide-svg svg{
  display:block;
  width:18px;
  height:18px
}
.sidebar__item-content{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.45rem;
  min-width:0;
  flex:1 1 auto
}
.sidebar__nav-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:1.35rem;
  height:1.35rem;
  padding:0 .38rem;
  border-radius:999px;
  background:#dc2626;
  color:#fff;
  font-size:.68rem;
  font-weight:800;
  line-height:1;
  box-shadow:0 8px 16px rgba(220,38,38,.24)
}
.sidebar__nav-badge--ok{
  background:#16a34a;
  box-shadow:0 8px 16px rgba(22,163,74,.24)
}
.sidebar__nav-badge[hidden]{display:none}
.sidebar[data-collapsed="true"] .sidebar__section-title{display:none}
.sidebar[data-collapsed="true"] .sidebar__section{margin-top:.55rem}
.sidebar[data-collapsed="true"] .sidebar__nav{gap:.38rem}
.sidebar[data-collapsed="true"] .sidebar__section.is-collapsed .sidebar__nav{display:flex}
.sidebar[data-collapsed="true"] .sidebar__subsection{padding:0;gap:.38rem}
.sidebar[data-collapsed="true"] .sidebar__subsection-title{display:none}
.sidebar[data-collapsed="true"] .sidebar__subsection.is-collapsed .sidebar__subnav{display:flex}
.sidebar[data-collapsed="true"] .sidebar__subnav{padding-left:0;gap:.38rem}
.sidebar[data-collapsed="true"] .sidebar__subnav .sidebar__nav-link{margin-left:0}

.sidebar[data-collapsed="true"] .sidebar__item-text{display:none}
.sidebar[data-collapsed="true"] .sidebar__nav-link{justify-content:center;padding:.55rem .3rem}
.sidebar[data-collapsed="true"] .sidebar__item-content{position:absolute;inset:0;display:block;pointer-events:none}
.sidebar[data-collapsed="true"] .sidebar__nav-badge{
  position:absolute;
  top:.12rem;
  right:.18rem;
  min-width:1.08rem;
  height:1.08rem;
  padding:0 .24rem;
  font-size:.58rem
}
@media (max-width:900px){
  .sidebar[data-collapsed="true"] .sidebar__section-heading{display:flex}
  .sidebar[data-collapsed="true"] .sidebar__subsection{
    padding:.2rem 0 .1rem;
    gap:.24rem
  }
  .sidebar[data-collapsed="true"] .sidebar__subsection-title{display:flex}
  .sidebar[data-collapsed="true"] .sidebar__subsection.is-collapsed .sidebar__subnav{display:none}
  .sidebar[data-collapsed="true"] .sidebar__subnav{
    padding-left:0;
    gap:.24rem
  }
  .sidebar[data-collapsed="true"] .sidebar__subnav .sidebar__nav-link{margin-left:.42rem}
  .sidebar[data-collapsed="true"] .sidebar__item-content{
    position:static;
    display:flex;
    pointer-events:auto
  }
  .sidebar[data-collapsed="true"] .sidebar__nav-badge{
    position:static;
    min-width:1.35rem;
    height:1.35rem;
    padding:0 .38rem;
    font-size:.68rem
  }
}

/* Header navigation */
.header-nav{
  display:flex;
  align-items:center;
  gap:1rem;
  padding:.82rem 0;
  position:relative
}

.header .header-btn{
  border-color:color-mix(in srgb,var(--color-primary) 18%, var(--header-border));
  background:rgba(255,255,255,.7);
  color:var(--header-fg)
}
.header .header-btn:hover{background:color-mix(in srgb,var(--color-primary) 8%, rgba(255,255,255,.86))}
.header .btn--primary.header-btn{
  border-color:transparent;
  background:linear-gradient(135deg,var(--color-accent) 0%,color-mix(in srgb,var(--color-accent) 72%, #ffffff) 100%);
  color:#fff
}
.header .btn--primary.header-btn:hover{background:linear-gradient(135deg,var(--color-accent-600),var(--color-accent))}

.header-mobile-toggle{display:none}
/* Home */

.metric-tile__value{font-size:1.95rem;line-height:1;font-weight:800}

.module-dashboard{display:grid;gap:1rem}
.module-dashboard__header{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:1rem;
  flex-wrap:wrap
}
.module-dashboard__header h2{margin:.12rem 0 .25rem}
.module-dashboard__eyebrow{
  margin:0;
  color:var(--color-primary-600);
  font-size:.76rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.08em
}

.module-dashboard__insight-list{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:.7rem
}
.module-dashboard__insight{
  margin:0;
  padding:.82rem .9rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:color-mix(in srgb,var(--color-primary) 5%, var(--color-surface));
  color:var(--color-fg);
  line-height:1.4
}
.module-dashboard__actions{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:.72rem
}

.module-dashboard__charts{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(280px,1fr));
  gap:.8rem;
  align-items:start
}
.gov-role-chart{
  display:grid;
  gap:.85rem;
  padding:.9rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt))
}
.gov-role-chart__head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:1rem;
  flex-wrap:wrap
}
.gov-role-chart__title{
  display:block;
  color:var(--color-fg);
  font-size:1rem;
  line-height:1.25
}
.gov-role-chart__subtitle{
  display:block;
  margin-top:.15rem;
  color:var(--color-muted);
  font-size:.86rem;
  line-height:1.35
}
.gov-role-chart__body{
  display:grid;
  gap:.7rem
}
.gov-role-chart__row{
  display:grid;
  gap:.34rem;
  min-width:0
}
.gov-role-chart__meta{
  display:flex;
  justify-content:space-between;
  gap:.8rem;
  align-items:center;
  min-width:0
}
.gov-role-chart__role{
  font-weight:700;
  color:var(--color-fg);
  overflow-wrap:anywhere
}
.gov-role-chart__count{
  flex:0 0 auto;
  color:var(--color-muted);
  font-size:.86rem;
  font-variant-numeric:tabular-nums
}
.gov-role-chart__track{
  height:14px;
  overflow:hidden;
  border-radius:999px;
  background:color-mix(in srgb,var(--color-primary) 10%, var(--color-border));
  border:1px solid color-mix(in srgb,var(--color-primary) 12%, var(--color-border))
}
.gov-role-chart__bar{
  height:100%;
  min-width:4px;
  border-radius:999px;
  background:linear-gradient(90deg,#0b63bc,#2f9a47)
}
.employee-incapacity-chart__split{
  display:grid;
  grid-template-columns:minmax(0,1.2fr) minmax(180px,.8fr);
  gap:.9rem;
  align-items:start
}
.employee-incapacity-chart__panel{
  display:grid;
  gap:.65rem;
  min-width:0
}
.employee-incapacity-chart__label{
  color:var(--color-fg);
  font-size:.92rem
}
.employee-incapacity-chart__bars{
  display:grid;
  gap:.7rem
}
.employee-incapacity-chart__top{
  display:grid;
  gap:.45rem;
  margin:0;
  padding-left:1.2rem
}
.employee-incapacity-chart__top li{
  color:var(--color-muted);
  padding-left:.15rem
}
.employee-incapacity-chart__top li::marker{
  color:var(--color-primary-600);
  font-weight:800
}
.employee-incapacity-chart__top span{
  color:var(--color-fg);
  font-weight:700;
  overflow-wrap:anywhere
}
.employee-incapacity-chart__top strong{
  display:inline-block;
  margin-left:.35rem;
  color:var(--color-primary-600)
}
.gov-closure-chart__body{
  display:grid;
  gap:.85rem
}
.gov-closure-chart__summary{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:.65rem
}
.gov-closure-chart__summary-item{
  display:grid;
  gap:.15rem;
  padding:.65rem .75rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:var(--color-surface)
}
.gov-closure-chart__summary-item span{
  color:var(--color-muted);
  font-size:.82rem
}
.gov-closure-chart__summary-item strong{
  color:var(--color-fg);
  font-size:1.3rem;
  line-height:1
}
.gov-closure-chart__summary-item--closed strong{color:#187a46}
.gov-closure-chart__summary-item--pending strong{color:#c43d34}
.gov-closure-chart__grid{
  display:grid;
  grid-template-columns:repeat(7,minmax(0,1fr));
  gap:.35rem
}
.gov-closure-chart__day{
  display:grid;
  place-items:center;
  aspect-ratio:1;
  min-height:34px;
  border:1px solid var(--color-border);
  border-radius:8px;
  font-size:.86rem;
  font-weight:800;
  font-variant-numeric:tabular-nums
}
.gov-closure-chart__day.is-closed{
  color:#146c3f;
  border-color:color-mix(in srgb,#187a46 32%, var(--color-border));
  background:color-mix(in srgb,#187a46 11%, var(--color-surface))
}
.gov-closure-chart__day.is-pending{
  color:#a2352e;
  border-color:color-mix(in srgb,#c43d34 32%, var(--color-border));
  background:color-mix(in srgb,#c43d34 10%, var(--color-surface))
}
.audit-columns{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:1rem;
  align-items:start
}
.audit-column{
  display:grid;
  gap:.75rem;
  min-width:0
}
.audit-column__header{
  display:grid;
  gap:.18rem;
  padding:.75rem .85rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:var(--color-surface-alt)
}
.audit-column__header strong{
  color:var(--color-fg);
  font-size:1rem
}
.audit-column__list{
  display:grid;
  gap:.65rem;
  min-width:0
}
.audit-item-card{
  min-width:0
}
.module-dashboard--gobierno .module-dashboard__insight{background:color-mix(in srgb,#0b63bc 6%, var(--color-surface))}
.module-dashboard--empleados .module-dashboard__insight{background:color-mix(in srgb,#2952b8 6%, var(--color-surface))}
.module-dashboard--operacion .module-dashboard__insight{background:color-mix(in srgb,#187a46 7%, var(--color-surface))}
.module-dashboard--reportes .module-dashboard__insight{background:color-mix(in srgb,#7c3aed 6%, var(--color-surface))}
.module-dashboard--cargue .module-dashboard__insight{background:color-mix(in srgb,#b7791f 7%, var(--color-surface))}

/* Grid of permissions */

.permission-pairs{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(280px,1fr));
  gap:.65rem
}
.permission-pair{
  display:grid;
  gap:.55rem;
  min-width:0;
  padding:.72rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt))
}
.permission-pair__title{
  font-weight:700;
  color:var(--color-fg);
  line-height:1.25;
  overflow-wrap:anywhere
}
.permission-pair__checks{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  align-items:center;
  gap:.45rem
}
.permissions-center__modules{
  display:grid;
  gap:1rem;
  margin-top:1rem
}
.permissions-center__module{
  margin-top:0;
  border:1px solid var(--color-border);
  border-radius:8px;
  padding:.85rem;
  background:var(--color-surface)
}
.permissions-center__module-head{
  display:flex;
  justify-content:space-between;
  gap:1rem;
  align-items:flex-start;
  margin-bottom:.75rem
}
.permissions-center__module-title{
  margin:0;
  font-size:1rem;
  line-height:1.2
}
.permissions-center__module-description{
  margin:.2rem 0 0;
  color:var(--color-muted);
  font-size:.86rem;
  line-height:1.35
}
.permissions-center__module-count{
  flex:0 0 auto
}
.perm-item{
  display:flex;
  align-items:center;
  gap:.5rem;
  border:1px solid var(--color-border);
  border-radius:16px;
  padding:.68rem .78rem;
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt))
}

.badge{display:inline-block;padding:.18rem .58rem;border-radius:999px;border:1px solid var(--color-border);font-size:.75rem}
.badge--ok{color:#187a46;border-color:#187a4633;background:#187a4612}
.badge--busy{color:#1d4ed8;border-color:#1d4ed833;background:#1d4ed812}
.badge--warn{color:#b7791f;border-color:#b7791f33;background:#b7791f14}
.badge--off{color:#c43d34;border-color:#c43d3433;background:#c43d3412}

.text-success{color:#187a46}
.text-danger{color:#c43d34}

.table-row-warning{background:#c43d3408}
.qr-scanner-frame{position:relative;width:100%;background:#111;border-radius:8px;overflow:hidden;min-height:280px}
.qr-scanner-video{display:block;width:100%;max-height:56vh;min-height:280px;background:#111;object-fit:cover}
.qr-scanner-pause{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.5rem;border:0;background:rgba(5,23,36,.9);color:#fff;font:inherit;cursor:pointer;text-align:center;padding:1rem}
.qr-scanner-pause strong{font-size:1.4rem}
.qr-scanner-pause span{color:rgba(255,255,255,.78)}
.qr-support-panel{padding:.72rem;border:1px dashed color-mix(in srgb,var(--color-muted) 34%,var(--color-border));border-radius:8px;background:color-mix(in srgb,var(--color-surface-alt) 72%,#fff)}
.qr-support-panel__unlock{min-height:38px;font-size:.85rem}
.qr-support-panel__hint{margin:.45rem 0 0;font-size:.82rem}
.qr-support-panel__controls{margin-top:.72rem;padding-top:.72rem;border-top:1px solid var(--color-border)}
.qr-support-panel__controls.hidden{display:none}
.row-actions{display:inline-flex;gap:.36rem;flex-wrap:nowrap;align-items:center;white-space:nowrap}
.row-actions .btn{padding:.4rem .62rem;font-size:.82rem;line-height:1}
.row-actions .btn--icon{padding:0}

.users-card-list{display:none}
.user-card{
  display:grid;
  gap:.72rem;
  padding:.82rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt));
  box-shadow:var(--shadow-soft)
}
@media (max-width:560px){
  .permission-pairs{grid-template-columns:1fr}
  .permission-pair__checks{grid-template-columns:1fr}
}
.user-card__header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:.75rem
}
.user-card__identity{display:grid;gap:.16rem;min-width:0}
.user-card__name{color:var(--color-fg);line-height:1.2;overflow-wrap:anywhere}
.user-card__email{color:var(--color-muted);font-size:.88rem;line-height:1.25;overflow-wrap:anywhere}
.user-card__meta{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:.5rem;
  margin:0
}
.user-card__meta-item{
  display:grid;
  gap:.12rem;
  min-width:0
}
.user-card__meta dt{
  color:var(--color-muted);
  font-size:.72rem;
  margin:0
}
.user-card__meta dd{
  color:var(--color-fg);
  font-size:.88rem;
  line-height:1.25;
  margin:0;
  overflow-wrap:anywhere
}
.user-card__actions{display:flex;justify-content:flex-end}
.user-card__empty{margin:.25rem 0}
.record-card-list{display:none}
.record-card{
  display:grid;
  gap:.72rem;
  padding:.82rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt));
  box-shadow:var(--shadow-soft)
}
.record-card__header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:.75rem
}
.record-card__identity{display:grid;gap:.16rem;min-width:0}
.record-card__title{color:var(--color-fg);line-height:1.2;overflow-wrap:anywhere}
.record-card__subtitle{color:var(--color-muted);font-size:.88rem;line-height:1.25;overflow-wrap:anywhere}
.record-card__meta{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:.5rem;
  margin:0
}
.record-card__meta-item{
  display:grid;
  gap:.12rem;
  min-width:0
}
.record-card__meta dt{
  color:var(--color-muted);
  font-size:.72rem;
  margin:0
}
.record-card__meta dd{
  color:var(--color-fg);
  font-size:.88rem;
  line-height:1.25;
  margin:0;
  overflow-wrap:anywhere
}
.record-card__actions{display:flex;justify-content:flex-end}
.record-card__empty{margin:.25rem 0}
.sede-location-page{
  --sede-map-height:clamp(360px,56vh,640px)
}
.sede-location-toolbar{
  align-items:end
}

.sede-location-map-panel{
  display:grid;
  gap:.35rem;
  min-width:0
}
.sede-location-map{
  width:100%;
  height:var(--sede-map-height);
  min-height:360px;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:var(--color-surface-alt);
  overflow:hidden
}
.sede-location-map__fallback{
  width:100%;
  height:100%;
  min-height:360px;
  border:0
}
.sede-location-map-msg{
  min-height:1.25rem;
  margin:0
}
.sede-location-list.record-card-list,
.sede-location-missing-list.record-card-list{gap:.7rem}
.sede-location-card .record-card__actions{
  gap:.4rem;
  flex-wrap:wrap
}
.sede-location-name{
  display:grid;
  gap:.08rem;
  min-width:0
}
.sede-location-name strong,
.sede-location-name span{
  overflow-wrap:anywhere
}
.sede-location-missing{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:.65rem;
  align-items:center;
  padding:.72rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:var(--color-surface-alt)
}
.sede-location-missing>div{
  display:grid;
  gap:.12rem;
  min-width:0
}
.sede-location-missing__actions{
  display:flex;
  justify-content:flex-end;
  gap:.35rem
}
.sede-location-missing strong,
.sede-location-missing span{
  overflow-wrap:anywhere
}
.sede-location-popup{
  display:grid;
  gap:.18rem;
  min-width:190px;
  color:#172033
}
.sede-location-popup span{
  color:#647184;
  font-size:.82rem
}
.sede-location-popup__actions{
  display:flex;
  gap:.35rem;
  margin-top:.4rem
}
.sede-location-popup__actions .btn{
  color:var(--color-primary-600);
  border-color:color-mix(in srgb,var(--color-primary) 28%, #dfe7ef);
  background:linear-gradient(180deg,color-mix(in srgb,var(--color-primary) 9%, #ffffff),#eef6fb)
}
.qr-scanner-controls{display:flex;justify-content:center;width:100%}
.form-row{display:flex;flex-wrap:wrap;gap:.6rem;align-items:end}

.divider{height:1px;background:var(--color-border);margin:.8rem 0}
.link{color:var(--color-primary);cursor:pointer}
.right{margin-left:auto}
.login-card{
  width:min(100%,390px);
  margin:clamp(.6rem,4vh,2rem) auto 0;
  padding:1.05rem;
}
.login-card>h2{
  text-align:center;
  margin-bottom:.45rem;
}
.login-brands{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:1rem;
  padding:0 0 .75rem;
  margin-bottom:1rem;
  border-bottom:1px solid var(--color-border);
}
.login-brands img{
  display:block;
  height:auto;
  object-fit:contain;
}
html .main-card.login-card.login-card--branded{
  margin-bottom:0;
}
html[data-ui] .main-card.login-card.login-card--branded{
  margin-bottom:0;
}
.login-signature{
  display:flex;
  justify-content:center;
  padding:1rem 0;
}
.login-brands__rocky{
  display:block;
  width:110px;
  max-width:50%;
  height:auto;
  object-fit:contain;
  margin:0;
}
.login-brands__partner{
  width:100%;
  max-width:360px;
  max-height:110px;
}
.login-form{
  width:100%;
  margin:0 auto;
}
.login-form .input{
  max-width:none;
}
.login-actions{
  justify-content:center;
  gap:.45rem;
}
.auth-copy{
  margin:.25rem 0 .55rem;
  color:var(--color-muted);
  text-align:center;
  line-height:1.45;
}
.auth-hint{
  margin:.52rem 0 0;
  color:var(--color-muted);
  font-size:.86rem;
}
.auth-state{
  display:grid;
  gap:.35rem;
  padding:.82rem .9rem;
  border:1px solid var(--color-border);
  border-radius:8px;
  background:var(--color-surface-alt);
}
.auth-state strong{
  color:var(--color-fg);
}
.auth-state p{
  margin:0;
  color:var(--color-muted);
  line-height:1.45;
}
.auth-state--success{
  border-color:#187a4633;
  background:#187a4612;
}
.login-link{
  justify-self:start;
  display:inline-flex;
  width:auto;
  margin:.5rem 0 .1rem;
  padding:0;
  border:0;
  background:transparent;
  color:var(--color-primary);
  font:inherit;
  font-size:.9rem;
  cursor:pointer;
}
.login-link:hover{
  text-decoration:underline;
}
.bulk-progress{
  display:grid;
  gap:.45rem;
  margin-top:.75rem;
  padding:.85rem .92rem;
  border:1px solid var(--color-border);
  border-radius:16px;
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt))
}
.bulk-progress__meta{display:flex;align-items:center;justify-content:space-between;gap:.75rem;flex-wrap:wrap}
.bulk-progress__label{font-weight:700;color:var(--color-fg)}
.bulk-progress__numbers{font-variant-numeric:tabular-nums}
.bulk-progress__track{
  position:relative;
  width:100%;
  height:12px;
  border-radius:999px;
  overflow:hidden;
  background:color-mix(in srgb,var(--color-primary) 14%, var(--color-border));
  border:1px solid color-mix(in srgb,var(--color-primary) 10%, var(--color-border))
}
.bulk-progress__fill{
  height:100%;
  width:0%;
  border-radius:999px;
  background:linear-gradient(90deg,var(--color-primary),color-mix(in srgb,var(--color-accent) 56%, #ffffff));
  transition:width .22s ease
}

/* WhatsApp live toolbar */

.wa-header{display:grid;grid-template-columns:minmax(0,420px) minmax(0,1fr);gap:.8rem;align-items:start;width:100%;min-width:0}
.wa-header__left{display:grid;gap:.75rem;min-width:0}
.wa-header__right{display:grid;min-width:0}
.wa-header__left h2{margin:0}
.wa-header__top{display:flex;align-items:center;justify-content:flex-start;gap:1.1rem;flex-wrap:wrap;min-width:0}
.wa-date-pill{display:inline-flex;align-items:center;gap:.45rem;padding:0;border:none;background:transparent;white-space:nowrap}
.wa-date-pill__label{color:var(--color-muted);font-size:.72rem}
.wa-date-pill__value{font-size:.9rem;line-height:1}
.wa-filters{display:grid;grid-template-columns:minmax(150px,190px) minmax(260px,1fr);gap:.6rem;align-items:end;min-width:0}
.wa-filters--wide{grid-template-columns:minmax(0,1fr) minmax(180px,.95fr)}
.wa-field{display:grid;gap:.25rem}
.wa-input{max-width:none;width:100%}
.wa-field--search{min-width:0}
.wa-field--search .wa-input{max-width:none}
.wa-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:.45rem;min-width:0}
.wa-stats--summary{grid-template-columns:1fr;align-content:start}
.wa-stats--summary-full{width:100%}
.wa-stat{padding:.56rem .68rem;display:grid;gap:.08rem;border-radius:16px;background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt));border:1px solid var(--color-border)}
.wa-stat__label{color:var(--color-muted);font-size:.72rem}
.wa-stat__label--title{
  text-align:center;
  font-weight:700;
  font-size:.82rem;
  text-transform:uppercase;
  letter-spacing:.04em;
  color:var(--color-muted);
  background:color-mix(in srgb,var(--color-primary) 9%, var(--color-surface));
  border:1px solid var(--color-border);
  border-radius:10px;
  padding:.36rem .5rem
}
.wa-stat__value{font-size:1rem;line-height:1.05}
.wa-stat--wide{padding:.25rem .65rem .55rem}
.wa-stat--summary-compact{padding:.28rem .7rem .46rem;gap:.28rem;min-height:100%}
.wa-kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(76px,1fr));gap:.35rem .55rem;align-items:start}
.wa-kpis--compact{gap:.18rem .55rem}
.wa-kpis--three{grid-template-columns:repeat(auto-fit,minmax(76px,1fr))}
.wa-kpi{display:grid;gap:.08rem}
.wa-kpi__label{color:var(--color-muted);font-size:.68rem;line-height:1.1}
.wa-kpi__value{font-size:.95rem;line-height:1.05;white-space:nowrap}
.wa-summary-groups{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:.4rem .8rem;align-items:start}
.wa-summary-group{display:grid;gap:.18rem}
.wa-summary-group__title{font-weight:600;line-height:1}
.wa-stats--nov{grid-template-columns:repeat(auto-fit,minmax(130px,1fr))}
.wa-stats--qr-registry{grid-template-columns:repeat(auto-fit,minmax(110px,1fr))}
.wa-live-table{table-layout:fixed;min-width:980px}
.wa-live-table th,.wa-live-table td{vertical-align:top}

/* Import sections */
.section-block{
  margin-top:.9rem;
  padding:1rem;
  border:1px solid rgba(255,255,255,.74);
  border-radius:22px;
  background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(244,248,252,.94));
  box-shadow:var(--shadow-soft)
}
.section-title{
  margin:0 0 .55rem 0;
  font-size:1rem;
  color:var(--color-primary-600);
  position:relative;
  padding:.58rem .88rem .58rem 1.1rem;
  border-radius:16px;
  background:linear-gradient(90deg,rgba(11,99,188,.09),rgba(255,255,255,.64));
  border:1px solid color-mix(in srgb,var(--color-primary) 16%, rgba(255,255,255,.78));
  box-shadow:0 6px 16px rgba(11,99,188,.05), inset 0 1px 0 rgba(255,255,255,.58)
}
.section-title::before{
  content:"";
  position:absolute;
  left:.48rem;
  top:50%;
  width:4px;
  height:62%;
  border-radius:999px;
  transform:translateY(-50%);
  background:linear-gradient(180deg,var(--color-primary),color-mix(in srgb,var(--color-primary) 55%, var(--color-accent)))
}
.section-title--toggle{display:flex;align-items:center;justify-content:space-between;gap:.5rem;cursor:pointer;user-select:none}
.section-title--toggle::after{content:'▾';font-size:.9rem;color:var(--color-muted);transition:transform .15s ease}
.section-title--toggle:focus{outline:2px solid var(--color-primary);outline-offset:2px;border-radius:6px}

.section-content{display:block}
.section-block.is-collapsed .section-content{display:none}
.section-block.is-collapsed .section-title--toggle::after{transform:rotate(-90deg)}

/* Footer */
.footer-shell{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  flex-wrap:wrap;
  width:100%;
  max-width:none;
  margin-inline:0;
  padding:.95rem 1.1rem 1.1rem;
  border-radius:20px;
  background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(241,246,250,.94));
  border:1px solid rgba(255,255,255,.72);
  box-shadow:var(--shadow-soft);
  color:var(--color-fg)
}

.footer-meta{
  display:grid;
  justify-items:end;
  gap:.38rem;
}
.footer-role-badge{
  justify-self:end;
  font-size:.68rem;
  padding:.24rem .58rem;
  background:linear-gradient(180deg,rgba(255,255,255,.94),rgba(237,244,250,.92))
}
.footer-copy{margin:0;max-width:620px;text-align:right}

/* Info modal */
.info-modal__overlay{position:fixed;inset:0;background:rgba(5,23,36,.46);display:flex;align-items:center;justify-content:center;padding:1rem;z-index:9999}
.info-modal{
  width:min(100%,640px);
  max-height:calc(100vh - 2rem);
  max-height:calc(100dvh - 2rem);
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt));
  border:1px solid var(--color-border);
  border-radius:18px;
  box-shadow:var(--shadow);
  overflow:hidden;
  display:flex;
  flex-direction:column
}
.info-modal__header{display:flex;align-items:center;justify-content:space-between;gap:.75rem;padding:.9rem 1rem;border-bottom:1px solid var(--color-border);flex:0 0 auto}
.info-modal__title{margin:0;font-size:1rem}
.info-modal__close{padding:.3rem .55rem;min-width:34px}
.info-modal__body{padding:.95rem 1rem;overflow:auto;min-height:0}
.info-modal__line{margin:.15rem 0;color:var(--color-fg)}
.employee-detail{display:grid;gap:.9rem}
.employee-detail__section{
  border:1px solid var(--color-border);
  border-radius:12px;
  background:color-mix(in srgb,var(--color-primary) 3%, var(--color-surface));
  padding:.8rem
}
.employee-detail__heading{
  margin:0 0 .65rem;
  color:var(--color-primary-600);
  font-size:.95rem;
  font-weight:800
}
.employee-detail__grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(160px,1fr));
  gap:.65rem;
  margin:0
}
.employee-detail__item{
  display:grid;
  gap:.18rem;
  min-width:0
}
.employee-detail__item dt{
  color:var(--color-muted);
  font-size:.76rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.04em
}
.employee-detail__item dd{
  margin:0;
  color:var(--color-fg);
  font-weight:700;
  overflow-wrap:anywhere
}

/* Action modal */
.action-modal__overlay{position:fixed;inset:0;background:rgba(5,23,36,.5);display:flex;align-items:center;justify-content:center;padding:1rem;z-index:10000}
.action-modal{
  width:min(100%,560px);
  max-height:calc(100vh - 2rem);
  max-height:calc(100dvh - 2rem);
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt));
  border:1px solid var(--color-border);
  border-radius:18px;
  box-shadow:var(--shadow);
  overflow:hidden;
  display:flex;
  flex-direction:column
}
.action-modal__header{display:flex;align-items:center;justify-content:space-between;gap:.75rem;padding:.9rem 1rem;border-bottom:1px solid var(--color-border);flex:0 0 auto}
.action-modal__title{margin:0;font-size:1rem}
.action-modal__close{padding:.3rem .55rem;min-width:34px}
.action-modal__body{padding:.95rem 1rem;overflow:auto;min-height:0}
.action-modal__message{margin:0 0 .8rem 0;color:var(--color-fg)}
.action-modal__field{display:flex;flex-direction:column;gap:.35rem;margin-bottom:.7rem}
.action-modal__field:last-child{margin-bottom:0}
.action-modal__order{margin-left:auto;font-weight:700;color:#1d4ed8;border-color:#1d4ed833;background:#1d4ed812}
.action-modal__order[hidden]{display:none}
.action-modal__preview:not(:empty){margin-top:.7rem;padding:.6rem .7rem;border:1px solid var(--color-border);border-radius:10px;background:var(--color-surface-alt);font-size:.86rem;overflow:auto}
.action-modal__footer{display:flex;justify-content:flex-end;gap:.5rem;padding:.85rem 1rem;border-top:1px solid var(--color-border);flex:0 0 auto;background:inherit}

/* Draggable modals (utils/draggableModal.js): drag by the header; once moved the backdrop clears to show the data behind */
.info-modal__overlay,.action-modal__overlay{transition:background-color .2s ease}
.info-modal__overlay.is-moved,.action-modal__overlay.is-moved{background:rgba(5,23,36,.08)}
.info-modal__overlay.is-dragging,.action-modal__overlay.is-dragging{user-select:none}
.is-dragging .modal-drag-handle{cursor:grabbing}
@media (min-width:561px){
  .modal-drag-handle{cursor:grab;touch-action:none}
}

@media (max-width:560px){
  .info-modal__overlay,.action-modal__overlay{padding:.5rem;align-items:stretch}
  .info-modal,.action-modal{max-height:calc(100vh - 1rem);max-height:calc(100dvh - 1rem)}
  .action-modal__footer{flex-wrap:wrap}
  .action-modal__footer .btn{flex:1 1 140px}
}

/* Contact cards */
.contact-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:1rem}
.contact-card{
  background:linear-gradient(180deg,var(--color-surface),var(--color-surface-alt));
  border:1px solid rgba(255,255,255,.7);
  border-radius:22px;
  padding:1.1rem;
  box-shadow:var(--shadow-soft)
}
.contact-card__title{margin:0 0 .78rem 0;font-size:1.05rem;color:var(--color-primary-600)}
.contact-card__row{margin:.38rem 0;color:var(--color-fg);line-height:1.45}

/* Policy / legal content */
.policy-doc{
  display:grid;
  gap:.55rem
}
.policy-doc__lead,
.policy-doc__text{
  margin:0;
  line-height:1.6;
  color:var(--color-fg)
}
.policy-doc__lead{
  margin-top:.1rem
}
.policy-doc__section-title{
  margin:.9rem 0 0;
  font-size:1.02rem;
  line-height:1.3;
  color:var(--color-primary-600)
}
.policy-doc a{
  color:var(--color-primary);
  text-decoration:underline;
  text-underline-offset:2px
}

/* Reports cards */

.table tr.is-selected{background:color-mix(in srgb,var(--color-primary) 12%, rgba(255,255,255,.32))}

html[data-theme="dark"] .input,
html[data-theme="dark"] .select{
  background:rgba(10,26,38,.88);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.04)
}
html[data-theme="dark"] .role-badge{
  color:var(--color-primary-600);
  background:linear-gradient(180deg,rgba(12,30,44,.96),rgba(16,37,53,.94))
}
html[data-theme="dark"] .table{
  background:rgba(8,21,31,.9);
  border-color:rgba(255,255,255,.06)
}
html[data-theme="dark"] .table thead th{
  background:linear-gradient(180deg,rgba(13,31,45,.98),rgba(17,39,56,.95));
  box-shadow:inset 0 -1px 0 rgba(110,210,138,.24), inset 0 1px 0 rgba(110,210,138,.1);
  text-shadow:0 1px 12px rgba(110,210,138,.14)
}
html[data-theme="dark"] .table tr:hover{
  background:color-mix(in srgb,var(--color-primary) 10%, rgba(10,24,36,.78))
}
html[data-theme="dark"] .app-notice{
  background:linear-gradient(180deg,rgba(10,25,38,.98),rgba(15,34,49,.96));
  border-color:rgba(255,255,255,.08);
  box-shadow:0 18px 34px rgba(0,0,0,.28)
}
html[data-theme="dark"] .app-notice__close:hover{
  background:rgba(255,255,255,.06)
}
html[data-theme="dark"] .app-loading__text{
  background:rgba(15,34,49,.96);
  border-color:rgba(255,255,255,.1);
  box-shadow:0 6px 16px rgba(0,0,0,.3)
}
html[data-theme="dark"] .table tr.is-selected{
  background:color-mix(in srgb,var(--color-primary) 16%, rgba(10,24,36,.82))
}
html[data-theme="dark"] .sidebar__item-icon {
  background:linear-gradient(180deg,rgba(12,30,44,.96),rgba(16,37,53,.94));
  border-color:rgba(255,255,255,.08)
}

html[data-theme="dark"] .sidebar__panel{
  background:linear-gradient(180deg,rgba(7,22,34,.94),rgba(10,28,42,.92))
}
html[data-theme="dark"] .sidebar__rail{
  background:linear-gradient(180deg,#071622 0%,#06131d 58%,#040d14 100%)
}

html[data-theme="dark"] .header .header-btn{
  background:rgba(10,26,38,.88)
}
html[data-theme="dark"] .header .header-btn:hover{
  background:color-mix(in srgb,var(--color-primary) 14%, rgba(10,26,38,.92))
}

html[data-theme="dark"] .section-block,
html[data-theme="dark"] .bulk-progress,
html[data-theme="dark"] .wa-stat,
html[data-theme="dark"] .contact-card,
html[data-theme="dark"] .info-modal,
html[data-theme="dark"] .action-modal {
  background:linear-gradient(180deg,rgba(10,25,38,.96),rgba(15,34,49,.94));
  border-color:rgba(255,255,255,.08)
}
html[data-theme="dark"] .section-title{
  color:var(--color-primary-600);
  background:linear-gradient(90deg,rgba(99,176,255,.12),rgba(12,29,43,.92));
  border-color:rgba(99,176,255,.16);
  box-shadow:0 8px 18px rgba(0,0,0,.14), inset 0 1px 0 rgba(255,255,255,.04)
}

html[data-theme="dark"] .footer-shell{
  background:linear-gradient(180deg,rgba(10,25,38,.96),rgba(14,33,49,.94));
  border:1px solid rgba(255,255,255,.08);
  box-shadow:var(--shadow-soft);
  color:var(--color-fg)
}
html[data-theme="dark"] .footer-copy {
  color:var(--color-muted)
}

html[data-theme="dark"] .footer-role-badge{
  background:linear-gradient(180deg,rgba(12,30,44,.96),rgba(16,37,53,.94));
  border-color:rgba(255,255,255,.08)
}

html[data-theme="dark"] .btn:disabled,
html[data-theme="dark"] .btn[aria-disabled="true"]{
  border-color:#2b3f4f;
  background:linear-gradient(180deg,#243746,#1b2d3a);
  color:#8298a8;
  box-shadow:none;
  filter:grayscale(1);
  opacity:1
}
html[data-theme="dark"] .btn:disabled:hover,
html[data-theme="dark"] .btn[aria-disabled="true"]:hover{
  transform:none;
  border-color:#2b3f4f;
  background:linear-gradient(180deg,#243746,#1b2d3a);
  box-shadow:none
}
html[data-theme="color"] .btn{
  border-color:color-mix(in srgb,var(--color-accent) 42%, var(--color-border));
  background:linear-gradient(135deg,#2fa77c 0%,#1f835f 100%);
  color:#ffffff;
  box-shadow:0 12px 24px rgba(20,85,200,.14)
}
html[data-theme="color"] .btn:hover{
  border-color:transparent;
  background:linear-gradient(135deg,#38b186 0%,#278f69 100%);
  box-shadow:0 16px 28px rgba(20,85,200,.18)
}
html[data-theme="color"] .btn--primary{
  background:linear-gradient(135deg,#2a67c8 0%,#1d4f9f 100%);
  color:#fff;
  box-shadow:0 14px 28px rgba(20,85,200,.18)
}
html[data-theme="color"] .btn--primary:hover{
  background:linear-gradient(135deg,#3474d7 0%,#2a67c8 100%);
  box-shadow:0 18px 32px rgba(20,85,200,.22)
}
html[data-theme="color"] .btn--danger{
  background:linear-gradient(135deg,#dc2626,#b91c1c);
  color:#fff
}
html[data-theme="color"] .btn--icon:not(.btn--danger):not(.btn--primary){
  background:linear-gradient(180deg,#ffffff,#e8f5ed);
  color:var(--color-primary-600)
}
html[data-theme="color"] .btn:disabled,
html[data-theme="color"] .btn[aria-disabled="true"],
html[data-theme="color"] .btn--icon:disabled,
html[data-theme="color"] .btn--icon[aria-disabled="true"],
html[data-theme="color"] .btn--primary:disabled,
html[data-theme="color"] .btn--primary[aria-disabled="true"],
html[data-theme="color"] .btn--danger:disabled,
html[data-theme="color"] .btn--danger[aria-disabled="true"]{
  border-color:#cfd8e3;
  background:linear-gradient(180deg,#f1f4f7,#e4e9ef);
  color:#7a8793;
  box-shadow:none;
  filter:grayscale(1);
  opacity:1
}
html[data-theme="color"] .btn:disabled:hover,
html[data-theme="color"] .btn[aria-disabled="true"]:hover{
  transform:none;
  border-color:#cfd8e3;
  background:linear-gradient(180deg,#f1f4f7,#e4e9ef);
  box-shadow:none
}
html[data-theme="color"] .input,
html[data-theme="color"] .select{
  background:rgba(255,255,255,.9);
  border-color:color-mix(in srgb,var(--color-primary) 15%, var(--color-border))
}
html[data-theme="color"] .role-badge{
  color:var(--color-primary-600);
  background:linear-gradient(90deg,rgba(20,85,200,.1),rgba(29,154,108,.1));
  border-color:color-mix(in srgb,var(--color-primary) 24%, var(--color-border))
}
html[data-theme="color"] .table{
  background:linear-gradient(180deg,rgba(255,255,255,.9),rgba(235,247,240,.72));
  border-color:rgba(143,183,211,.58)
}
html[data-theme="color"] .table thead th{
  background:#d2e5f6;
  color:#0d3f97;
  box-shadow:inset 0 -2px 0 rgba(29,154,108,.3), inset 0 1px 0 rgba(255,255,255,.76);
  text-shadow:none
}
html[data-theme="color"] .table tr:hover{
  background:linear-gradient(90deg,rgba(20,85,200,.09),rgba(29,154,108,.1))
}
html[data-theme="color"] .app-notice{
  border-color:rgba(255,255,255,.78);
  background:linear-gradient(180deg,rgba(255,255,255,.98),rgba(238,248,241,.96));
  box-shadow:0 18px 36px rgba(14,60,112,.18)
}

html[data-theme="color"] .sidebar__rail{
  background:linear-gradient(180deg,rgba(5,31,64,.98),rgba(8,58,74,.98))
}
html[data-theme="color"] .sidebar__panel{
  background:linear-gradient(180deg,rgba(12,55,118,.9),rgba(15,82,92,.82))
}
html[data-theme="color"] .sidebar__project-head{
  border-bottom-color:rgba(255,255,255,.16)
}

html[data-theme="color"] .sidebar__section-link:hover,
html[data-theme="color"] .sidebar__section-link.is-active,
html[data-theme="color"] .sidebar__subsection-title:hover,
html[data-theme="color"] .sidebar__subsection-title.is-active {
  color:#ffffff
}
html[data-theme="color"] .sidebar__section-icon,
html[data-theme="color"] .sidebar__subsection-icon{
  color:#ffffff;
  background:rgba(255,255,255,.12)
}
html[data-theme="color"] .sidebar__nav-link:hover{
  background:rgba(255,255,255,.1)
}
html[data-theme="color"] .sidebar__nav-link.is-active{
  color:#ffffff;
  background:linear-gradient(90deg,rgba(255,255,255,.18),rgba(29,154,108,.18));
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.16)
}
html[data-theme="color"] .sidebar__item-icon{
  color:#0d3f97;
  background:linear-gradient(180deg,#ffffff,#e9f6ef);
  border-color:rgba(255,255,255,.52)
}

html[data-theme="color"] .header .header-btn{
  background:linear-gradient(135deg,#2fa77c,#1f835f);
  border-color:transparent;
  color:#ffffff
}
html[data-theme="color"] .header .header-btn:hover{
  background:linear-gradient(135deg,#38b186,#278f69)
}
html[data-theme="color"] .header .btn--primary.header-btn{
  background:linear-gradient(135deg,#2a67c8,#1d4f9f);
  color:#ffffff
}

html[data-theme="color"] .section-block,
html[data-theme="color"] .bulk-progress,
html[data-theme="color"] .wa-stat,
html[data-theme="color"] .contact-card,
html[data-theme="color"] .info-modal,
html[data-theme="color"] .action-modal,
html[data-theme="color"] .permission-pair,
html[data-theme="color"] .permissions-center__module,
html[data-theme="color"] .user-card,
html[data-theme="color"] .record-card {
  background:
    linear-gradient(180deg,rgba(255,255,255,.94),rgba(241,250,245,.9)),
    linear-gradient(135deg,rgba(20,85,200,.06),rgba(29,154,108,.06));
  border-color:rgba(143,183,211,.58);
  box-shadow:0 12px 28px rgba(14,60,112,.09)
}

html[data-theme="color"] .module-dashboard{
  background:
    linear-gradient(180deg,rgba(255,255,255,.9),rgba(242,250,246,.86)),
    linear-gradient(135deg,rgba(20,85,200,.06),rgba(29,154,108,.07))
}
html[data-theme="color"] .module-dashboard__header{
  margin:-.2rem -.2rem .2rem;
  padding:.85rem 1rem;
  border-radius:16px;
  background:linear-gradient(90deg,rgba(20,85,200,.07),rgba(29,154,108,.07),rgba(212,151,31,.05));
  border:1px solid rgba(143,183,211,.46)
}
html[data-theme="color"] .main-card>h2,
html[data-theme="color"] .module-dashboard__header h2{
  color:#0d3f97
}

html[data-theme="color"] .gov-role-chart{
  background:
    linear-gradient(180deg,rgba(255,255,255,.92),rgba(235,247,240,.88)),
    linear-gradient(135deg,rgba(20,85,200,.06),rgba(29,154,108,.06));
  border-color:rgba(143,183,211,.58)
}
html[data-theme="color"] .gov-role-chart__head{
  padding:.7rem .8rem;
  margin:-.25rem -.25rem .05rem;
  border-radius:8px;
  background:linear-gradient(90deg,rgba(20,85,200,.06),rgba(29,154,108,.06))
}
html[data-theme="color"] .gov-role-chart__track{
  background:rgba(20,85,200,.12);
  border-color:rgba(20,85,200,.16)
}
html[data-theme="color"] .section-title{
  color:#0d3f97;
  background:linear-gradient(90deg,rgba(20,85,200,.14),rgba(29,154,108,.12),rgba(212,151,31,.08));
  border-color:rgba(20,85,200,.16);
  box-shadow:0 8px 18px rgba(14,60,112,.07), inset 0 1px 0 rgba(255,255,255,.72)
}
html[data-theme="color"] .section-title::before{
  background:#1d9a6c
}
html[data-theme="color"] .footer-shell{
  background:linear-gradient(90deg,rgba(20,85,200,.06),rgba(29,154,108,.06)),linear-gradient(180deg,rgba(255,255,255,.92),rgba(237,248,241,.88));
  border-color:rgba(143,183,211,.58)
}

@media (max-width:1200px){
  
  .wa-header{grid-template-columns:1fr}
}

@media (max-width:1100px){
  .header-nav{align-items:flex-start;flex-wrap:wrap}
  
  
  
  
}

@media (max-width:900px){
  .sidebar__shell{
    height:100dvh;
    grid-template-columns:68px minmax(0,1fr)
  }
  .sidebar__rail{
    height:100dvh;
    padding:.7rem .42rem
  }
  .sidebar__rail-btn{
    width:44px;
    height:44px;
    border-radius:13px
  }
  .sidebar__panel{
    height:100dvh;
    padding:1rem .85rem
  }
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__shell{
    grid-template-columns:68px minmax(0,1fr)
  }
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__panel{
    display:block
  }
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__section-title{
    display:block
  }
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__subsection-title{
    display:flex
  }
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__item-text{
    display:inline
  }
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__subsection.is-collapsed .sidebar__subnav,
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__section.is-collapsed .sidebar__nav{
    display:none
  }
  .sidebar[data-sidebar-kind="double"][data-collapsed="true"] .sidebar__nav-link{
    justify-content:flex-start;
    padding:.62rem .74rem
  }
  .audit-columns{grid-template-columns:1fr}
  .header-mobile-toggle{display:inline-flex}
  
  .footer-meta{justify-items:start}
  .footer-role-badge{justify-self:start}
  .footer-copy{text-align:left}
  .users-table-view{display:none}
  .users-card-list{
    display:grid;
    gap:.7rem
  }
  .responsive-table-view{display:none}
  .record-card-list{
    display:grid;
    gap:.7rem
  }
  
  
  
  
  
  
  
  
  
  
}

@media (max-width:780px){
  .gov-closure-chart__summary{grid-template-columns:1fr}
  .wa-filters{grid-template-columns:1fr}
  
  
  
  
  
  .user-card__header{
    align-items:stretch;
    flex-direction:column
  }
  .user-card__meta{grid-template-columns:1fr}
  .user-card__actions{justify-content:flex-start}
  .record-card__header{
    align-items:stretch;
    flex-direction:column
  }
  .record-card__meta{grid-template-columns:1fr}
  .record-card__actions{justify-content:flex-start}
  .sede-location-page{
    --sede-map-height:360px
  }
  
  .employee-incapacity-chart__split{grid-template-columns:1fr}
  
  
  
  
  
}

.wa-attendance-tracking-table{min-width:1290px}
.marking-time{
  border:0;
  border-radius:5px;
  padding:3px 5px;
  font:inherit;
  font-weight:600;
  text-align:left;
  cursor:help;
}
.marking-time--comment{color:#9a3412;background:#ffedd5}
.marking-time--control{color:#b91c1c;background:#fee2e2}
.marking-time:focus-visible{outline:2px solid currentColor;outline-offset:2px}
/* The state of a live screen, as in the supervisor app: a dot (green live, amber interrupted) and the last update. */
.live-state{display:flex;align-items:center;gap:.4rem;margin:.75rem 0 0;color:var(--color-muted);font-size:.82rem}
.live-state::before{content:"";flex:0 0 auto;width:.55rem;height:.55rem;border-radius:50%;background:var(--color-border-strong)}
.live-state--live::before{background:#187a46}
.live-state--polling::before{background:#b7791f}
