/* ===========================================================================
   SClan (jonke): hoja de estilos
   Sistema de diseño Singular 2026 (manual de marca 01.2026, skill singular-design):
   Nunito Sans (UI) + Exo 2 (cifras), chrome negro, lienzo blanco/gris,
   Spectra como color de datos y un solo acento lima en la accion primaria.
   =========================================================================== */
@font-face {
  font-family: "Nunito Sans";
  src: url("/static/fonts/NunitoSans-VariableFont.ttf") format("truetype-variations");
  font-weight: 200 900; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Exo 2";
  src: url("/static/fonts/Exo2-VariableFont_wght.ttf") format("truetype-variations");
  font-weight: 100 900; font-style: normal; font-display: swap;
}
:root {
  /* Paleta Singular 2026. Los nombres --green/--accent se conservan por compatibilidad
     con las ~100 reglas que ya los usan: ambos apuntan hoy a Spectra (color de datos). */
  --green:        #38615F;   /* Spectra */
  --green-dark:   #152625;   /* Cardin Green */
  --green-soft:   #EEF3F1;   /* tinte palido de Spectra */
  --green-soft-2: #C6D8CF;   /* Jet Stream */
  --ink:          #080808;   /* Black */
  --ink-soft:     #676A6D;
  --muted:        #888B8D;   /* Dark Silver */
  --line:         rgba(8,8,8,.10);
  --line-strong:  rgba(8,8,8,.22);
  --bg:           #F6F7F8;   /* lienzo de app: gris muy claro */
  --white:        #FFFFFF;
  --crudo:        #F2F0E2;
  --chrome:       #080808;   /* barra principal (sidebar) */
  --lime:         #A9F900;   /* Spring Bud: unico acento, solo la accion primaria */
  --danger:       #D22D2D;
  --warn:         #FFBF00;
  --blue:         #006FFF;   /* ultimo recurso; solo semantico */
  --purple:       #8F87AD;   /* Deluge */
  --accent:       #38615F;   /* estados completado/activo/progreso = Spectra */
  --accent-dark:  #152625;
  --accent-soft:  rgba(56,97,95,.12);
  --nav-active:   rgba(241,240,226,.10);
  --focus-border: #7F9C97;
  --focus-ring:   0 0 0 3px rgba(163,186,179,.4);
  --shadow:       0 1px 2px 0 rgba(8,8,8,.06), 0 1px 1px 0 rgba(8,8,8,.04);
  --shadow-lg:    0 6px 16px -6px rgba(8,8,8,.12), 0 2px 4px -1px rgba(8,8,8,.05);
  --radius:       6px;
  --sidebar-w:    56px;
  --sidebar-w-exp: 240px;
  --topbar-h:     48px;
  --font-sans:    "Nunito Sans", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --font-display: "Exo 2", "Nunito Sans", system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: var(--font-sans);
  font-kerning: normal; font-feature-settings: "kern" 1, "liga" 1;
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 14px; }
h1, h2, h3 { font-weight: 600; }
.boot { display: grid; place-items: center; height: 100vh; color: var(--muted); }

/* ---------- utilidades ---------- */
.row { display: flex; align-items: center; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; }
.spacer { flex: 1; }
.muted { color: var(--muted); }
.center { text-align: center; }
.hidden { display: none !important; }
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600;
}
.pill.green  { background: var(--accent-soft); color: var(--accent-dark); }
.pill.gray   { background: #EDECEC; color: var(--ink-soft); }
.pill.warn   { background: rgba(255,191,0,.18); color: var(--green-dark); }
.pill.danger { background: rgba(210,45,45,.12); color: var(--danger); }
.pill.blue   { background: rgba(198,216,207,.55); color: var(--green-dark); }
.pill.purple { background: rgba(143,135,173,.18); color: var(--green-dark); }

/* ===========================================================================
   LOGIN
   =========================================================================== */
.login-wrap {
  min-height: 100vh; display: grid; place-items: center;
  background: var(--chrome);
  padding: 20px;
}
.login-card {
  background: var(--white); width: 100%; max-width: 400px;
  border-radius: 8px; padding: 40px 36px; box-shadow: var(--shadow-lg);
}
.login-logo { display: flex; align-items: center; gap: 10px; justify-content: center; margin-bottom: 6px; }
.login-card h1 { font-size: 26px; text-align: center; }
.login-card .sub { text-align: center; color: var(--muted); margin: 6px 0 28px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12px; font-weight: 600; color: var(--ink-soft); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 9px 12px; font-size: 13px; border: 1px solid var(--line);
  border-radius: 8px; background: #FBFCFD; transition: border .15s, box-shadow .15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--focus-border); box-shadow: var(--focus-ring);
  background: #fff;
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 14px; border-radius: 6px; font-weight: 600; font-size: 13px;
  background: var(--lime); color: var(--ink); transition: background .15s, transform .05s;
}
.btn:hover { background: #97E000; }
.btn:active { transform: scale(.985); }
.btn.full { width: 100%; }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line-strong); }
.btn.ghost:hover { background: #F4F5F6; }
.btn.danger { background: var(--danger); color: #fff; }
.btn.danger:hover { background: #B82626; }
.btn.sm { padding: 6px 10px; font-size: 12px; }
.btn.icon { padding: 7px; border-radius: 6px; }
.login-error { background: #FCE9EA; color: var(--danger); padding: 10px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 14px; }
.login-hint { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); text-align: center; line-height: 1.7; }
.btn.ms { background: #fff; color: #3B3B3B; border: 1px solid #D2D2D2; font-weight: 600; }
.btn.ms:hover { background: #F8F8F8; border-color: #B9B9B9; }
.login-sep { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: var(--muted); font-size: 12px; }
.login-sep::before, .login-sep::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.link-toggle { color: var(--green-dark); font-weight: 600; font-size: 13px; }
.link-toggle:hover { text-decoration: underline; }

/* ===========================================================================
   LAYOUT PRINCIPAL
   =========================================================================== */
.shell { display: flex; min-height: 100vh; }

/* ---- Sidebar: carril de iconos (como Kenjo), se despliega con el menú ☰ del topbar ---- */
.sidebar {
  width: var(--sidebar-w); background: var(--chrome); color: var(--crudo);
  display: flex; flex-direction: column; position: fixed; top: var(--topbar-h); bottom: 0; left: 0; z-index: 30;
  overflow: hidden; transition: width .22s ease-out;
}
.sidebar.expanded { width: var(--sidebar-w-exp); }
.nav { flex: 1; padding: 8px; overflow-y: auto; overflow-x: hidden; }
.nav a {
  display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 6px;
  font-size: 13px; color: rgba(241,240,226,.62); font-weight: 500; margin-bottom: 2px; white-space: nowrap;
  transition: background .12s, color .12s;
}
.nav a svg { flex: none; width: 20px; height: 20px; opacity: .8; }
.nav a span, .nav-foot span { opacity: 0; transition: opacity .15s; overflow: hidden; text-overflow: ellipsis; }
.sidebar.expanded .nav a span, .sidebar.expanded .nav-foot span { opacity: 1; }
.nav a:hover { background: rgba(241,240,226,.06); color: var(--crudo); }
.nav a.active { background: var(--nav-active); color: var(--crudo); font-weight: 600; }
.nav a.active svg { opacity: 1; }
.sidebar .side-foot { padding: 8px; border-top: 1px solid rgba(241,240,226,.14); }
.nav-foot {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 6px; border-radius: 6px; border: none; background: none;
  color: rgba(241,240,226,.75); font-size: 13px; font-family: inherit; text-align: left; white-space: nowrap; cursor: pointer;
}
.nav-foot .avatar, .nav-foot svg { flex: none; }
.nav-foot svg { width: 20px; height: 20px; margin: 0 4px; }
.nav-foot:hover { background: rgba(241,240,226,.08); color: var(--crudo); }

/* ---- Main ---- */
.main { flex: 1; margin-left: var(--sidebar-w); padding-top: var(--topbar-h); display: flex; flex-direction: column; min-width: 0; transition: margin-left .22s ease-out; }
.sidebar.expanded ~ .main { margin-left: var(--sidebar-w-exp); }

/* ---- Topbar ---- */
.topbar {
  background: var(--white); border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 4px; padding: 0 12px 0 8px; height: var(--topbar-h);
  position: fixed; top: 0; left: 0; right: 0; z-index: 40;
}
.brand { display: flex; align-items: center; gap: 8px; height: 100%; padding: 0 14px 0 6px; color: var(--ink); text-decoration: none; }
.brand .logo-mark { flex: none; display: block; }
.brand b { font-size: 15px; font-weight: 600; color: var(--ink); letter-spacing: 0; }
.tabs { margin-left: 6px; }
.tabs { display: flex; gap: 4px; height: 100%; }
.tabs a {
  display: flex; align-items: center; padding: 0 11px; height: 100%;
  font-size: 12.5px; color: var(--ink-soft); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px;
  white-space: nowrap;
}
.tabs a:hover { color: var(--ink); }
.tabs a.active { color: var(--ink); border-bottom-color: var(--ink); font-weight: 600; }
.search {
  display: flex; align-items: center; gap: 8px; background: #F4F6F8;
  border-radius: 6px; padding: 6px 10px; width: 240px; color: var(--muted); font-size: 13px;
}
.search input { border: none; background: none; width: 100%; color: var(--ink); }
.search input:focus { outline: none; }
.icon-btn { position: relative; width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: var(--ink-soft); }
.icon-btn:hover { background: #F4F6F8; }
.icon-btn .dot { position: absolute; top: 8px; right: 9px; width: 8px; height: 8px; background: var(--warn); border-radius: 50%; border: 2px solid #fff; }
.avatar {
  display: inline-grid; place-items: center; border-radius: 50%; color: #fff;
  font-weight: 600; flex: none; user-select: none;
}
.profile-btn { display: flex; align-items: center; gap: 8px; padding: 4px; border-radius: 999px; }
.profile-btn:hover { background: #F4F6F8; }

/* ---- Content ---- */
.content { padding: 18px 24px; max-width: 1240px; width: 100%; margin: 0 auto; }
.page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.page-head h1 { font-size: 20px; }
.page-head p { color: var(--muted); margin-top: 2px; }

/* ---- Cards ---- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card.pad { padding: 14px 16px; }
.card-title { font-size: 15px; font-weight: 600; margin-bottom: 12px; display: flex; align-items: center; justify-content: space-between; }
.grid { display: grid; gap: 12px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: 2fr 1fr; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ---- Métricas ---- */
.metric { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; box-shadow: var(--shadow); }
.metric .v { font-family: var(--font-display); font-variant-numeric: tabular-nums; font-size: 22px; font-weight: 600; line-height: 1; }
.metric .l { color: var(--muted); margin-top: 4px; font-size: 12px; }
.metric .ic { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; background: var(--green-soft); color: var(--green-dark); margin-bottom: 8px; }

/* ---- Reacciones (anuncios) ---- */
.react {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px;
  background: #F4F6F8; border: 1px solid transparent; font-weight: 600; font-size: 13px; transition: all .12s;
}
.react:hover { border-color: var(--green); }
.react.mine { background: var(--green-soft); border-color: var(--green); color: var(--green-dark); }
.react-add { width: 34px; height: 30px; border-radius: 999px; background: #F4F6F8; display: grid; place-items: center; }
.react-add:hover { background: var(--green-soft); }

/* ---- listas tipo aniversarios ---- */
.list-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.list-row:last-child { border-bottom: none; }
.list-row .who b { display: block; font-size: 14px; }
.list-row .who span { color: var(--muted); font-size: 12px; }
.month-label { font-size: 11px; font-weight: 700; letter-spacing: 0; color: var(--muted); text-transform: none; margin: 14px 0 4px; }
.month-label:first-child { margin-top: 0; }

/* ---- Tablas ---- */
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: 12px; text-transform: none; letter-spacing: 0; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); font-weight: 600; }
.table td { padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tr:hover td { background: #FAFBFC; }
.table .actions { display: flex; gap: 6px; justify-content: flex-end; }
.tbl-name { display: flex; align-items: center; gap: 10px; }

/* ---- Progress bar ---- */
.progress { height: 8px; background: #EDECEC; border-radius: 2px; overflow: hidden; min-width: 90px; }
.progress > span { display: block; height: 100%; background: var(--accent); border-radius: 2px; }

/* ---- Puntuación de desempeño (Evaluaciones) ---- */
.score-badge { display: inline-flex; align-items: baseline; gap: 1px; background: var(--accent-soft); color: var(--accent-dark);
  font-weight: 700; font-size: 14px; padding: 3px 9px; border-radius: 8px; line-height: 1; }
.score-badge small { font-size: 10px; font-weight: 600; opacity: .7; }
.score-badge.lg { font-size: 26px; padding: 6px 14px; font-family: var(--font-display); }
.score-badge.lg small { font-size: 13px; }

/* ---- Objetivos por colaborador ---- */
.goal-list { display: flex; flex-direction: column; gap: 14px; }
.goal-person .goal-row { padding: 11px 0; border-top: 1px solid var(--line); }
.goal-person .goal-row:first-of-type { border-top: none; padding-top: 2px; }

/* ---- Kanban tareas ---- */
.kanban { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: start; }
.kcol { background: #F4F6F8; border-radius: var(--radius); padding: 14px; }
.kcol h3 { font-size: 13px; text-transform: none; letter-spacing: 0; color: var(--ink-soft); margin-bottom: 12px; display: flex; justify-content: space-between; }
.kcard { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 13px 14px; margin-bottom: 10px; box-shadow: var(--shadow); cursor: pointer; }
.kcard:hover { box-shadow: var(--shadow-lg); }
.kcard b { display: block; margin-bottom: 6px; font-weight: 600; }
.kcard .meta { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; color: var(--muted); font-size: 12px; }

/* ---- Calendario ---- */
.cal-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-dow { text-align: center; font-size: 12px; font-weight: 600; color: var(--muted); padding-bottom: 6px; }
.cal-cell { background: #fff; border: 1px solid var(--line); border-radius: 8px; min-height: 92px; padding: 7px 8px; }
.cal-cell.out { background: #FAFBFC; opacity: .55; }
.cal-cell.today { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.cal-cell .d { font-size: 12px; font-weight: 600; color: var(--ink-soft); }
.cal-ev { font-size: 11px; padding: 2px 6px; border-radius: 6px; margin-top: 4px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* --- Calendario · Vista general (línea de tiempo por empleado) --- */
.tl-wrap { overflow-x: auto; }
.tl-table { border-collapse: collapse; width: 100%; min-width: 640px; }
.tl-table th { font-size: 11px; font-weight: 600; color: var(--muted); text-align: center; padding: 6px 4px; border-bottom: 1px solid var(--line); }
.tl-table th.tl-today { color: var(--green-dark); }
.tl-namehd { width: 200px; }
.tl-name { display: flex; align-items: center; gap: 8px; padding: 8px 10px; font-size: 13px; white-space: nowrap; border-bottom: 1px solid var(--line); }
.tl-cell { text-align: center; border-bottom: 1px solid var(--line); border-left: 1px solid var(--line); width: 60px; }
.tl-cell.tl-today { background: var(--green-soft); }
.tl-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; }

/* ===========================================================================
   MODAL
   =========================================================================== */
.modal-bg { position: fixed; inset: 0; background: rgba(16,24,40,.45); display: grid; place-items: center; z-index: 100; padding: 20px; }
.modal { background: #fff; border-radius: 8px; width: 100%; max-width: 520px; max-height: 90vh; overflow-y: auto; box-shadow: var(--shadow-lg); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.modal-head h2 { font-size: 18px; }
.modal-body { padding: 22px 24px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--line); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* ---- Toast ---- */
.toast-wrap { position: fixed; bottom: 24px; right: 24px; z-index: 200; display: flex; flex-direction: column; gap: 10px; }
.toast { background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 8px; box-shadow: var(--shadow-lg); font-weight: 500; animation: slidein .2s ease; }
.toast.ok { background: var(--green-dark); }
.toast.err { background: var(--danger); }
@keyframes slidein { from { transform: translateY(10px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---- empty state ---- */
.empty { text-align: center; padding: 50px 20px; color: var(--muted); }
.empty svg { opacity: .4; margin-bottom: 12px; }

/* ---- detalle empleado ---- */
.emp-hero { display: flex; align-items: center; gap: 18px; }
.emp-hero .avatar { width: 76px; height: 76px; font-size: 28px; }
.kv { display: flex; padding: 9px 0; border-bottom: 1px solid var(--line); }
.kv:last-child { border-bottom: none; }
.kv .k { width: 150px; color: var(--muted); flex: none; }

/* ---- responsive ---- */
@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); transition: transform .2s; width: var(--sidebar-w-exp); }
  .sidebar.expanded { transform: none; box-shadow: var(--shadow-lg); }
  .sidebar .nav a span, .sidebar .nav-foot span { opacity: 1; }
  .main, .sidebar.expanded ~ .main { margin-left: 0; }
  .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .kanban { grid-template-columns: 1fr; }
  .topbar-search { display: none; }
  .brand b, .section-title { display: none; }
  .tabs a { padding: 0 10px; }
}
.menu-btn { display: grid; }

/* ===========================================================================
   Componentes adicionales (paridad funcional)
   =========================================================================== */
.section-title { display: flex; align-items: center; height: var(--topbar-h); padding: 0 16px; font-size: 13px; font-weight: 500; color: var(--ink); border-left: 1px solid var(--line); border-right: 1px solid var(--line); white-space: nowrap; }
.section-title:empty { display: none; }

/* --- toolbar del directorio --- */
.dir-toolbar { display: flex; align-items: center; margin-bottom: 14px; gap: 12px; }
.vistas { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 8px 14px; font-size: 13px; font-weight: 600; color: var(--ink-soft); box-shadow: var(--shadow); }
.vistas b { color: var(--ink); }
.view-toggle { display: flex; gap: 4px; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 3px; box-shadow: var(--shadow); }
.vt { width: 36px; height: 32px; border-radius: 7px; display: grid; place-items: center; color: var(--muted); }
.vt.active { background: var(--green-soft); color: var(--green-dark); }
.dir-actions-wrap { position: relative; }
.dir-actions-menu { position: absolute; top: calc(100% + 6px); left: 0; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow-lg); min-width: 260px; z-index: 20; overflow: hidden; }
.dir-actions-menu button { display: block; width: 100%; text-align: left; padding: 10px 16px; font-size: 13px; background: none; border: none; cursor: pointer; color: var(--ink); }
.dir-actions-menu button:hover { background: var(--bg); }

/* --- filtros --- */
.dir-filters { display: flex; gap: 10px; align-items: center; padding: 14px 16px; margin-bottom: 14px; flex-wrap: wrap; }
.dir-filter { padding: 8px 11px; font-size: 13px; border: 1px solid var(--line); border-radius: 8px; background: #FBFCFD; color: var(--ink-soft); font-weight: 500; min-width: 130px; }
.dir-filter:focus { outline: none; border-color: var(--focus-border); box-shadow: var(--focus-ring); }

/* --- cuadrícula de empleados --- */
.emp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 16px; }
.emp-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 14px; text-align: center; display: flex; flex-direction: column; align-items: center; cursor: pointer; transition: box-shadow .12s, transform .05s; box-shadow: var(--shadow); }
.emp-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.emp-card b { margin-top: 12px; }
.emp-card span.muted { font-size: 12px; }

/* --- tarjetas de saldo de ausencias --- */
.bal-card { overflow: hidden; padding: 0; }
.bal-card .bal-top { height: 5px; }
.bal-card .pad { padding: 18px 20px; }
.bal-row { display: flex; justify-content: space-between; padding: 7px 0; color: var(--ink-soft); }
.bal-row.total { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 12px; font-weight: 700; color: var(--ink); }
.bal-row.total span { letter-spacing: 0; }

/* --- pestañas internas (Tareas/Histórico) --- */
.inner-tabs { display: flex; gap: 4px; padding: 0 18px; border-bottom: 1px solid var(--line); }
.itab { padding: 11px 11px 9px; font-size: 13px; color: var(--ink-soft); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.itab:hover { color: var(--ink); }
.itab.active { color: var(--ink); border-bottom-color: var(--ink); font-weight: 600; }

/* --- Documentos: carpetas --- */
.doc-layout { display: flex; gap: 18px; align-items: flex-start; }
.doc-folders { width: 250px; flex: none; display: flex; flex-direction: column; gap: 2px; padding: 10px; }
.doc-folder { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px; color: var(--ink-soft); font-weight: 500; text-align: left; width: 100%; }
.doc-folder:hover { background: #F4F6F8; color: var(--ink); }
.doc-folder.active { background: var(--green-soft); color: var(--green-dark); font-weight: 600; }
.doc-folder svg { flex: none; opacity: .75; }
.doc-count { background: #EEF1F4; color: var(--ink-soft); border-radius: 999px; padding: 1px 9px; font-size: 12px; font-weight: 600; }
.doc-folder.active .doc-count { background: #fff; color: var(--green-dark); }
@media (max-width: 900px) { .doc-layout { flex-direction: column; } .doc-folders { width: 100%; flex-direction: row; flex-wrap: wrap; } }

/* --- Calendario: toggles de leyenda --- */
.cal-leg { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); font-weight: 500; opacity: .55; }
.cal-leg.on { opacity: 1; color: var(--ink-soft); background: #F4F6F8; }
.cal-leg span { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* --- Control segmentado (Todas/Mías, estados de proyecto) --- */
.seg { display: inline-flex; background: #EEF0F3; border: none; border-radius: 8px; padding: 3px; gap: 2px; }
.seg-btn { padding: 7px 14px; border-radius: 8px; color: var(--ink-soft); font-weight: 500; transition: background .15s, box-shadow .15s, color .15s; }
.seg-btn .muted { font-size: 12px; }
.seg-btn.active { background: #fff; color: var(--ink); font-weight: 700; box-shadow: 0 1px 3px rgba(16,24,40,.12); }
.seg-btn.active .muted { color: var(--ink-soft); }

/* --- barra superior: popovers (búsqueda, notificaciones, perfil) --- */
.topbar-search { position: relative; display: flex; align-items: center; gap: 4px; }
.topbar-search .search { width: 220px; }
.topbar-pop { position: relative; }
.pop { position: absolute; top: calc(100% + 8px); right: 0; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow-lg); z-index: 40; overflow: hidden; }
.search-pop { left: 0; right: 0; width: 100%; min-width: 280px; padding: 6px; }
.notif-pop { width: 320px; padding: 6px; }
.profile-pop { width: 240px; padding: 6px; }
.pop-title { font-size: 12px; font-weight: 700; text-transform: none; letter-spacing: 0; color: var(--muted); padding: 8px 12px 6px; }
.pop-empty { padding: 16px 12px; color: var(--muted); font-size: 13px; text-align: center; }
.pop-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.pop-head b { display: block; font-size: 14px; }
.pop-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 8px; color: var(--ink-soft); font-weight: 500; text-align: left; }
.pop-item:hover { background: #F4F6F8; color: var(--ink); }
.pop-item svg { opacity: .7; }
.search-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border-radius: 8px; text-align: left; }
.search-item:hover { background: var(--green-soft); }
.search-item b { font-size: 13px; display: block; }
.notif-item { display: flex; align-items: flex-start; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 8px; text-align: left; color: var(--ink-soft); }
.notif-item:hover { background: #F4F6F8; }
.notif-item svg { flex: none; margin-top: 1px; opacity: .7; }
.notif-item span { font-size: 13px; line-height: 1.4; }

/* --- Mi grupo de trabajo (Inicio) --- */
.group-label { font-size: 11px; font-weight: 700; letter-spacing: 0; color: var(--muted); text-transform: none; margin-bottom: 10px; }
.team-photos { display: flex; flex-wrap: wrap; gap: 10px; }
.team-photo { display: inline-flex; cursor: pointer; border-radius: 50%; transition: transform .1s; }
.team-photo:hover { transform: translateY(-2px); }
.team-photo .avatar { border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); }
.team-photo.me .avatar { box-shadow: 0 0 0 2px var(--green); border-color: #fff; }

/* --- Tareas (lista estilo Kenjo) --- */
.task-toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.task-group { font-size: 13px; color: var(--ink-soft); display: flex; align-items: center; gap: 8px; }
.task-group select { padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); }
.task-filters { display: flex; gap: 10px; align-items: center; padding: 12px 14px; margin-bottom: 12px; }
.task-filters .dir-filter { cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.fbadge { background: var(--green); color: #fff; border-radius: 999px; padding: 0 7px; font-size: 11px; font-weight: 700; }
.pop-check { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 8px; font-size: 14px; cursor: pointer; }
.pop-check:hover { background: #F4F6F8; }
.task-chips { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.task-chip { display: inline-flex; align-items: center; gap: 6px; background: #EEF1F4; color: var(--ink-soft); border-radius: 999px; padding: 4px 6px 4px 12px; font-size: 12px; font-weight: 600; }
.task-chip button { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; color: var(--muted); }
.task-chip button:hover { background: #DDE3EA; color: var(--ink); }
.task-list { overflow: hidden; }
.task-row { display: flex; align-items: center; gap: 14px; padding: 13px 18px; border-bottom: 1px solid var(--line); cursor: pointer; }
.task-row:last-child { border-bottom: none; }
.task-row:hover { background: #FAFBFC; }
.task-check { width: 22px; height: 22px; border: 2px solid var(--line); border-radius: 50%; flex: none; display: grid; place-items: center; color: #fff; transition: background .12s, border-color .12s; }
.task-check:hover { border-color: var(--accent); }
.task-check.on { background: var(--accent); border-color: var(--accent); }
.task-check.on::after { content: '✓'; font-size: 13px; font-weight: 700; line-height: 1; }
.task-main { flex: 1; min-width: 0; }
.task-title { font-weight: 500; }
.task-row.done .task-title { text-decoration: line-through; color: var(--muted); }
.task-due { font-size: 12px; display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.task-group-hd { padding: 12px 18px 8px; font-size: 12px; font-weight: 700; text-transform: none; letter-spacing: 0; color: var(--muted); background: #FBFCFD; border-bottom: 1px solid var(--line); }

/* ===========================================================================
   Altas y bajas (JML) — stepper, definición de accesos, checklist, timeline
   =========================================================================== */
.back-link { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 13px; font-weight: 500; margin-bottom: 6px; }
.back-link:hover { color: var(--green); }

.stepper { display: flex; align-items: center; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }
.stepper .stp { display: flex; align-items: center; gap: 8px; }
.stepper .dot { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: #EEF1F4; color: var(--muted); font-size: 12px; font-weight: 700; border: 2px solid var(--line); }
.stepper .stp.done .dot { background: var(--accent-soft); color: var(--accent-dark); border-color: var(--accent-soft); }
.stepper .stp.active .dot { background: var(--accent); color: #fff; border-color: var(--accent); }
.stepper .stp span:last-child { font-size: 13px; color: var(--ink-soft); }
.stepper .stp.active span:last-child { font-weight: 600; color: var(--ink); }
.stepper .bar { width: 26px; height: 2px; background: var(--line); }

.info-row { display: flex; justify-content: space-between; gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.info-row:last-child { border-bottom: none; }
.info-row b { text-align: right; max-width: 60%; }

.acc-group { margin-bottom: 12px; }
.acc-group-h { font-size: 12px; text-transform: none; letter-spacing: 0; color: var(--muted); margin: 12px 0 6px; font-weight: 600; }
.acc-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; margin-bottom: 8px; cursor: pointer; flex-wrap: wrap; }
.acc-row:hover { background: #FAFBFC; }
.acc-row input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.acc-detail { display: none; padding: 7px 10px; border: 1px solid var(--line); border-radius: 8px; width: 100%; font-size: 13px; }
.acc-detail.show { display: block; }
.ex-name, .ex-detail, .ex-cat { padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: #FBFCFD; }
.ex-detail { width: 130px; }

.chk-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; margin-bottom: 8px; }
.chk-item.hecho { background: var(--accent-soft); border-color: var(--green-soft-2); }
.chk-item.na { opacity: .6; }

.timeline { list-style: none; }
.timeline li { position: relative; padding: 0 0 16px 20px; border-left: 2px solid var(--line); }
.timeline li:last-child { border-left-color: transparent; padding-bottom: 0; }
.timeline li::before { content: ''; position: absolute; left: -6px; top: 2px; width: 10px; height: 10px; border-radius: 50%; background: var(--green); }
.timeline .tl-text { font-size: 13px; line-height: 1.4; }
.timeline .tl-time { font-size: 11px; color: var(--muted); margin-top: 2px; }

.banner-ok { background: var(--accent-soft); color: var(--accent-dark); border-radius: 8px; padding: 10px 14px; font-weight: 600; font-size: 13px; text-align: center; }

.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* ---------- Altas y bajas · RUTA de seguimiento (tracking visual) ---------- */
.route-wrap { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px 26px 20px; margin-bottom: 20px; }
.route { position: relative; }
.route-track { position: absolute; top: 26px; left: calc(100% / (var(--n) * 2)); width: calc(100% - 100% / var(--n)); height: 5px; background: #EDECEC; border-radius: 2px; overflow: hidden; }
.route-fill { height: 100%; background: var(--accent); border-radius: 2px; transition: width .6s cubic-bezier(.4,0,.2,1); }
.route-stops { display: flex; position: relative; }
.route-stop { flex: 1; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 6px; }
.route-node { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; background: #fff; border: 3px solid var(--line); color: var(--muted); box-shadow: var(--shadow); z-index: 1; transition: transform .3s, box-shadow .3s, background .3s, color .3s; }
.route-stop.done .route-node { background: var(--accent); border-color: var(--accent); color: #fff; }
.route-stop.active .route-node { border-color: var(--accent); color: var(--accent-dark); background: #fff; box-shadow: 0 0 0 6px var(--accent-soft); animation: routePulse 2s infinite; }
.route-stop.pending .route-node { opacity: .85; }
.route-label { margin-top: 12px; font-weight: 600; font-size: 13.5px; color: var(--ink); }
.route-stop.pending .route-label { color: var(--muted); font-weight: 500; }
.route-sub { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.route-stop.active .route-sub { color: var(--accent-dark); font-weight: 600; }
.route-stop.done .route-sub { color: var(--ink-soft); }
@keyframes routePulse {
  0%   { box-shadow: 0 0 0 0 var(--accent-soft); }
  70%  { box-shadow: 0 0 0 10px rgba(29,158,117,0); }
  100% { box-shadow: 0 0 0 0 rgba(29,158,117,0); }
}
.route-wrap.cancelled .route-fill { background: var(--muted); }
.route-cancel { display: flex; align-items: center; justify-content: center; gap: 6px; color: var(--danger); font-weight: 600; font-size: 13px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
@media (max-width: 600px) {
  .route-label { font-size: 11.5px; }
  .route-sub { display: none; }
  .route-node { width: 44px; height: 44px; }
  .route-track { top: 21px; }
}

/* ---------- Fuera de oficina (en el modal de solicitar ausencia) ---------- */
.ooo-box { margin-top: 6px; padding: 14px; border: 1px solid var(--green-soft-2); background: var(--green-soft); border-radius: 8px; }
.ooo-check { display: flex; align-items: flex-start; gap: 10px; font-size: 13.5px; cursor: pointer; font-weight: 500; }
.ooo-check input { width: 18px; height: 18px; accent-color: var(--accent); margin-top: 1px; flex: none; }
.ooo-note { font-size: 12px; color: var(--ink-soft); margin: 10px 0 6px; }
.ooo-preview { font-size: 12.5px; color: var(--ink-soft); background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; line-height: 1.5; max-height: 140px; overflow: auto; }

/* ---------- Solicitudes de ausencia · ruta visual con fotos ---------- */
.abs-card { margin-bottom: 16px; }
.abs-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.abs-head b { font-size: 15px; display: block; }
.abs-reason { color: var(--ink-soft); font-style: italic; font-size: 13px; margin: 10px 0 2px; }
.aroute { position: relative; margin: 22px 0 6px; padding: 0 4px; }
.aroute-line { position: absolute; top: 23px; left: 16.66%; right: 16.66%; height: 4px; background: #EDECEC; border-radius: 2px; overflow: hidden; }
.aroute-fill { height: 100%; background: var(--accent); border-radius: 2px; transition: width .6s cubic-bezier(.4,0,.2,1); }
.aroute.is-rej .aroute-fill { background: var(--danger); }
.aroute-stops { display: flex; position: relative; }
.aroute-stop { flex: 1; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 2px; }
.aroute-av { position: relative; }
.aroute-av .avatar { border: 3px solid #fff; box-shadow: 0 0 0 2px var(--line); }
.aroute-stop.done .aroute-av .avatar { box-shadow: 0 0 0 3px var(--accent); }
.aroute-stop.active .aroute-av .avatar { box-shadow: 0 0 0 3px var(--accent); animation: routePulse 2s infinite; }
.aroute-stop.pending .aroute-av { opacity: .55; filter: grayscale(.4); }
.aroute-stop.rejected .aroute-av .avatar { box-shadow: 0 0 0 3px var(--danger); }
.aroute-badge { position: absolute; bottom: -2px; right: -2px; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; border: 2px solid #fff; }
.aroute-badge.done { background: var(--accent); color: #fff; }
.aroute-badge.rej { background: var(--danger); color: #fff; }
.aroute-badge.act { background: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.aroute-name { font-weight: 600; font-size: 13px; margin-top: 8px; }
.aroute-label { font-size: 11px; color: var(--muted); text-transform: none; letter-spacing: 0; }
.aroute-sub { font-size: 11.5px; color: var(--ink-soft); }
.aroute-stop.active .aroute-sub { color: var(--accent-dark); font-weight: 600; }
.aroute-stop.pending .aroute-name, .aroute-stop.pending .aroute-sub { color: var(--muted); }
.abs-actions { display: flex; gap: 8px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.abs-actions .del-abs { margin-left: auto; }

/* ---------- Solicitudes: maestro-detalle (como Kenjo) ---------- */
.sol-layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 900px) { .sol-layout { grid-template-columns: 1fr; } }
.sol-list { max-height: 74vh; overflow-y: auto; }
.sol-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--line); cursor: pointer; }
.sol-row:last-child { border-bottom: none; }
.sol-row:hover { background: var(--bg); }
.sol-row.on { background: var(--green-soft); border-left: 3px solid var(--green); padding-left: 13px; }
.sol-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 5px; }
.sol-quick { display: flex; gap: 6px; flex: none; }
.sol-x, .sol-ok { width: 28px; height: 28px; border-radius: 50%; border: none; display: grid; place-items: center; cursor: pointer; color: #fff; }
.sol-x { background: var(--danger); }
.sol-ok { background: var(--green); }
.sol-detail-wrap { min-height: 200px; }
.sol-caldate { flex: none; width: 78px; text-align: center; border: 1px solid var(--line); border-radius: 8px; padding: 8px 0; }
.scd-month { font-size: 11px; font-weight: 700; color: var(--ink-soft); letter-spacing: 0; }
.scd-day { font-size: 24px; font-weight: 600; font-family: var(--font-display); line-height: 1.2; }
.scd-dow { font-size: 11px; color: var(--muted); text-transform: none; }
.sol-kv { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); font-size: 13px; }
.sol-kv b { font-size: 11px; letter-spacing: 0; color: var(--ink-soft); flex: none; }
.sol-kv span { text-align: right; }

/* ---------- Ajustes · interruptores (switch) ---------- */
.cfg-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 2px; border-bottom: 1px solid var(--line); font-size: 14px; }
.cfg-row:last-child { border-bottom: none; }
.switch { position: relative; display: inline-block; width: 42px; height: 24px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch .slider { position: absolute; inset: 0; background: #cfd6df; border-radius: 999px; transition: .2s; cursor: pointer; }
.switch .slider::before { content: ''; position: absolute; height: 18px; width: 18px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .2s; box-shadow: 0 1px 2px rgba(0,0,0,.25); }
.switch input:checked + .slider { background: var(--accent); }
.switch input:checked + .slider::before { transform: translateX(18px); }

/* ---------- Mi empresa · pills de días laborables ---------- */
.day-pill { width: 42px; height: 38px; border: 1px solid var(--line); border-radius: 8px; background: #FBFCFD; color: var(--ink-soft); font-weight: 600; font-size: 13px; }
.day-pill.on { background: var(--green); color: #fff; border-color: var(--green); }
.hol-date { padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; }

/* ---------- Perfiles y permisos ---------- */
.perm-list { list-style: none; margin: 0; }
.perm-list li { font-size: 13px; color: var(--ink-soft); padding: 3px 0 3px 18px; position: relative; }
.perm-list li::before { content: '✓'; position: absolute; left: 0; color: var(--accent); font-weight: 700; }

/* ---- Evaluación de desempeño (estilo Kenjo) ---- */
.eval-layout { display: grid; grid-template-columns: 250px 1fr; gap: 18px; align-items: start; }
@media (max-width: 980px) { .eval-layout { grid-template-columns: 1fr; } }
.ev-side-title { font-size: 12px; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--ink-soft); margin-bottom: 10px; }
.ev-opt { display: flex; align-items: center; gap: 8px; font-size: 13.5px; padding: 5px 0; cursor: pointer; color: var(--ink); }
.ev-search { margin-bottom: 12px; }
.ev-search input { width: 100%; border: none; border-bottom: 1px solid var(--line); padding: 7px 2px; font-size: 13.5px; outline: none; background: transparent; }
.ev-search input:focus { border-color: var(--green); }
.ev-filter { border-top: 1px solid var(--line); padding: 4px 0; }
.ev-filter summary { list-style: none; cursor: pointer; display: flex; align-items: center; font-size: 13.5px; padding: 9px 0; color: var(--ink); }
.ev-filter summary::-webkit-details-marker { display: none; }
.ev-filter summary::after { content: '▾'; margin-left: auto; color: var(--ink-soft); font-size: 11px; transition: transform .15s; }
.ev-filter[open] summary::after { transform: rotate(180deg); }
.ev-scope { display: flex; gap: 18px; }
.ev-scope-btn { background: none; border: none; font-size: 12.5px; font-weight: 700; letter-spacing: 0; color: var(--ink-soft); cursor: pointer; padding: 4px 2px; border-bottom: 2px solid transparent; }
.ev-scope-btn.on { color: var(--ink); border-color: var(--ink); }
.ev-proc { border-bottom: 1px solid var(--line); }
.ev-proc:last-child { border-bottom: none; }
.ev-proc-row { display: flex; align-items: center; gap: 18px; padding: 18px 22px; }
.ev-proc-title { color: var(--green); font-weight: 600; font-size: 15px; cursor: pointer; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.ev-proc-title:hover { text-decoration: underline; }
.ev-proc-row .row.gap-8 { min-width: 0; }
.ev-proc-detail { padding: 0 10px 14px; }
.ev-gwrap { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 130px; }
.ev-g { position: relative; }
.ev-gpct { position: absolute; left: 0; right: 0; bottom: 2px; text-align: center; font-size: 15px; }
.ev-gcap { font-size: 10.5px; color: var(--ink-soft); }
.ev-link { color: var(--green); font-size: 12px; font-weight: 700; letter-spacing: 0; cursor: pointer; }
.ev-link:hover { text-decoration: underline; }
.sc-row { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-bottom: 1px dashed var(--line); }
.sc-cat { flex: 1; font-size: 13px; }
.sc-pct { width: 68px; border: 1px solid var(--line); border-radius: 8px; padding: 4px 8px; font-size: 13px; }

/* mapa de calor */
.hm-filters, .cmp-filters { display: flex; gap: 18px; align-items: flex-end; flex-wrap: wrap; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.cmp-filters { border-bottom: none; padding: 0 0 12px; }
.hm-f { display: flex; flex-direction: column; gap: 4px; font-size: 11.5px; color: var(--ink-soft); font-weight: 600; }
.hm { border-collapse: collapse; font-size: 12.5px; min-width: 720px; width: 100%; }
.hm th, .hm td { border: 1px solid #EDF0F4; padding: 8px 10px; text-align: center; }
.hm-name { text-align: left !important; white-space: nowrap; min-width: 190px; border-left: none !important; }
.hm-th { height: 130px; vertical-align: bottom; position: relative; min-width: 58px; border: none !important; }
.hm-th span { position: absolute; bottom: 12px; left: 50%; transform-origin: 0 50%; transform: rotate(-55deg); white-space: nowrap; font-size: 11.5px; font-weight: 600; color: var(--ink-soft); }
.hm-avgrow td { font-weight: 600; padding: 12px 10px; }
.hm-empavg { white-space: nowrap; }
.hm-cell { font-weight: 600; min-width: 58px; }
.hm-cell.hm-g2 { background: #38615F; color: #fff; }
.hm-cell.hm-g1 { background: #A3BAB3; color: var(--green-dark); }
.hm-cell.hm-r1 { background: rgba(210,45,45,.18); color: #8E1F1F; }
.hm-cell.hm-r2 { background: #D22D2D; color: #fff; }
.hm-cell.hm-na { background: #F7F9FA; color: #C3CBD5; font-weight: 400; }

/* comparar */
.cmp-chip { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); border-radius: 999px; padding: 5px 8px 5px 10px; font-size: 12.5px; background: #fff; }
.cmp-sw { width: 22px; height: 10px; border-radius: 4px; display: inline-block; }
.cmp-x { border: none; background: none; cursor: pointer; color: var(--ink-soft); display: flex; padding: 0; }
.cmp-x:hover { color: var(--danger); }

/* ---- Asistente Nueva evaluación (pantalla completa, estilo Kenjo) ---- */
.wiz-overlay { position: fixed; inset: 0; background: #F7F9FB; z-index: 3000; display: flex; flex-direction: column; overflow: auto; }
.wiz-top { display: flex; align-items: center; gap: 16px; padding: 0 22px; min-height: 54px; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 2; }
.wiz-top-title { font-weight: 600; min-width: 170px; font-size: 14px; }
.wiz-steps { flex: 1; display: flex; align-items: center; justify-content: center; }
.wiz-step { display: flex; align-items: center; gap: 8px; color: var(--ink-soft); font-size: 13px; }
.wiz-step .num { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #cfd6df; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 600; }
.wiz-step.active { color: var(--green); font-weight: 600; }
.wiz-step.active .num, .wiz-step.done .num { border-color: var(--green); background: var(--green); color: #fff; }
.wiz-conn { width: 64px; height: 2px; background: #dfe4ea; margin: 0 8px; }
.wiz-conn.done { background: var(--green); }
.wiz-top-actions { display: flex; gap: 18px; align-items: center; }
.wiz-link { background: none; border: none; color: var(--ink-soft); font-size: 12px; font-weight: 700; letter-spacing: 0; cursor: pointer; display: flex; align-items: center; gap: 6px; }
.wiz-link:hover { color: var(--ink); }
.wiz-link.danger { color: var(--danger); }
.wiz-body { flex: 1; display: grid; grid-template-columns: minmax(0,1fr) 330px; gap: 24px; padding: 26px 30px; max-width: 1240px; margin: 0 auto; width: 100%; box-sizing: border-box; }
@media (max-width: 900px) { .wiz-body { grid-template-columns: 1fr; } }
.wiz-sec-title { font-size: 17px; font-weight: 600; margin-bottom: 16px; }
.wiz-panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.wiz-panel.pad { padding: 20px; }
.wz-card { border: 1px solid var(--line); border-radius: 8px; padding: 15px; margin-bottom: 12px; transition: border-color .15s, background .15s; }
.wz-card.on { border-color: var(--green); background: var(--green-soft); }
.wz-card-hd { display: flex; gap: 13px; align-items: flex-start; }
.wz-ic { width: 30px; height: 30px; border-radius: 8px; background: var(--green-soft); color: var(--green-dark); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.wz-card.on .wz-ic { background: #fff; }
.wz-card-hd b { font-size: 13.5px; }
.wz-card-hd .muted { font-size: 12px; }
.wz-badge { display: inline-block; background: #E7EBF0; color: var(--ink-soft); font-size: 11px; padding: 3px 8px; border-radius: 6px; margin-top: 8px; }
.wz-anon { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--ink-soft); margin-top: 9px; cursor: pointer; }
.wiz-check-list { max-height: 46vh; overflow: auto; border: 1px solid var(--line); border-radius: 8px; }
.wiz-check { display: flex; align-items: center; gap: 10px; padding: 9px 13px; border-bottom: 1px solid var(--line); cursor: pointer; }
.wiz-check:last-child { border-bottom: none; }
.wiz-resumen { align-self: start; position: sticky; top: 80px; }
.wiz-rz-sec { border-bottom: 1px solid var(--line); padding: 12px 0; }
.wiz-rz-sec:last-child { border-bottom: none; }
.wiz-rz-hd { font-size: 13.5px; font-weight: 600; color: var(--ink-soft); }
.wiz-rz-sec.active .wiz-rz-hd { color: var(--green); }
.wiz-rz-k { font-size: 10.5px; letter-spacing: 0; color: var(--ink-soft); margin-top: 10px; }
.wiz-rz-v { font-size: 13px; margin-top: 2px; }
.wiz-foot { border-top: 1px solid var(--line); background: #fff; padding: 13px 30px; display: flex; justify-content: space-between; position: sticky; bottom: 0; }
.wiz-confirm-bg { position: fixed; inset: 0; background: rgba(20,30,50,.4); display: flex; align-items: center; justify-content: center; z-index: 10; }
.wiz-confirm { background: #fff; border-radius: var(--radius); padding: 22px 24px; width: 440px; max-width: 92vw; box-shadow: var(--shadow-lg); }
.btn.danger { background: var(--danger); color: #fff; }

/* ---- Wizard Kenjo completo: participantes ---- */
.wz-num-row { display: flex; align-items: center; gap: 10px; font-size: 12.5px; letter-spacing: 0; }
.wz-num { width: 24px; height: 24px; border-radius: 50%; background: #DFE4EA; color: var(--ink-soft); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex: none; }
.wz-num.on { background: var(--green); color: #fff; }
.wz-filters { display: flex; gap: 14px; align-items: flex-end; flex-wrap: wrap; }
.wz-filternote { background: #F4F6F8; border-radius: 8px; padding: 7px 12px; font-size: 12px; color: var(--ink-soft); margin: 12px 0; display: flex; align-items: center; justify-content: space-between; }
.wz-dual { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 860px) { .wz-dual { grid-template-columns: 1fr; } }
.wz-col { border: 1px solid var(--line); border-radius: 8px; display: flex; flex-direction: column; min-height: 300px; }
.wz-col-hd { padding: 10px 14px; border-bottom: 1px solid var(--line); font-size: 11.5px; font-weight: 700; letter-spacing: 0; color: var(--ink-soft); }
.wz-col-list { flex: 1; overflow: auto; max-height: 320px; }
.wz-emp { display: flex; align-items: center; gap: 10px; padding: 7px 12px; border-bottom: 1px solid #F1F3F6; font-size: 13px; }
.wz-add { width: 26px; height: 26px; border-radius: 50%; border: 1.5px solid var(--green); color: var(--green); background: #fff; font-size: 16px; line-height: 1; cursor: pointer; flex: none; }
.wz-add:hover { background: var(--green); color: #fff; }
.wz-col-ft { border-top: 1px solid var(--line); padding: 9px 14px; display: flex; justify-content: space-between; align-items: center; }
.wz-spinner span { width: 10px; height: 10px; border-radius: 50%; background: var(--green); display: inline-block; margin: 0 3px; animation: wzdot 1s infinite alternate; }
.wz-spinner span:nth-child(2) { animation-delay: .2s; } .wz-spinner span:nth-child(3) { animation-delay: .4s; }
@keyframes wzdot { from { opacity: .25; transform: translateY(0); } to { opacity: 1; transform: translateY(-5px); } }
.wz-thchip { width: 24px; height: 24px; border-radius: 6px; display: inline-flex; align-items: center; justify-content: center; vertical-align: middle; }
.wz-subpanel { background: #F4F6F8; border-radius: 8px; padding: 10px 12px; margin-top: 10px; }
.wz-radio { display: flex; align-items: center; gap: 8px; font-size: 13px; padding: 5px 0; cursor: pointer; flex-wrap: wrap; }

/* ---- Wizard: preguntas ---- */
.wz-banner { display: flex; gap: 8px; align-items: flex-start; background: var(--accent-soft); border-radius: 8px; padding: 10px 12px; font-size: 12.5px; margin-top: 12px; }
.wz-banner-ic { color: var(--green); font-weight: 700; }
.wq-row { display: flex; align-items: flex-start; gap: 10px; border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; margin-bottom: 10px; background: #fff; }
.wq-row.dragging { opacity: .4; }
.wq-handle { cursor: grab; color: var(--ink-soft); font-size: 15px; padding-top: 2px; }
.wq-chip { background: var(--accent-soft); color: var(--green-dark); font-size: 11px; font-weight: 600; border-radius: 6px; padding: 3px 8px; }
.wq-chip.gray { background: #EEF1F4; color: var(--ink-soft); }
.wz-menu { position: absolute; top: 36px; right: 0; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow-lg); z-index: 6; min-width: 240px; overflow: hidden; }
.wz-menu.hidden { display: none; }
.wz-menu-it { display: block; width: 100%; text-align: left; background: none; border: none; padding: 11px 14px; font-size: 13px; cursor: pointer; }
.wz-menu-it:hover { background: #F4F6F8; }
.aq-modal { width: 920px; max-width: 96vw; }
.aq-grid { display: grid; grid-template-columns: 220px 1fr 260px; gap: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
@media (max-width: 860px) { .aq-grid { grid-template-columns: 1fr; } }
.aq-col { border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 340px; }
.aq-col:last-child { border-right: none; }
.aq-hd { padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: 12px; font-weight: 700; color: var(--ink-soft); display: flex; justify-content: space-between; align-items: center; }
.aq-list { flex: 1; overflow: auto; max-height: 46vh; }
.aq-cat { display: block; width: 100%; text-align: left; background: none; border: none; border-bottom: 1px solid #F1F3F6; padding: 9px 12px; font-size: 12.5px; cursor: pointer; }
.aq-cat.on { background: var(--green-soft); font-weight: 600; }
.aq-q { padding: 8px 12px; border-bottom: 1px solid #F1F3F6; cursor: pointer; display: flex; }
.aq-q.on { background: var(--green-soft); }
.aq-scale { display: flex; gap: 6px; margin-top: 8px; }
.aq-scale span { width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--line); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; }
.wz-actions { display: flex; justify-content: center; gap: 34px; margin-top: 20px; }
.wz-circle-wrap { display: flex; flex-direction: column; align-items: center; gap: 5px; font-size: 11.5px; color: var(--ink-soft); }
.wz-circle { width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--ink-soft); background: #fff; font-size: 17px; cursor: pointer; color: var(--ink-soft); }
.wz-circle.ok { border-color: var(--green); color: var(--green); }
.wz-circle.ok:hover { background: var(--green); color: #fff; }
.wz-circle.sm { width: 24px; height: 24px; font-size: 14px; border-color: var(--green); color: var(--green); padding: 0; }
.wz-circle:disabled { opacity: .4; cursor: default; }
.tpl-row { display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 8px; padding: 11px 13px; margin-bottom: 8px; cursor: pointer; }
.tpl-row.on { border-color: var(--green); background: var(--green-soft); }
.tpl-ic { color: var(--green); display: flex; }

/* ---- Wizard: banco de preguntas (pantalla completa, 3 paneles) ---- */
.wzb-grid { flex: 1; display: grid; grid-template-columns: 280px minmax(0,1fr) 340px; gap: 18px; padding: 22px 26px; width: 100%; box-sizing: border-box; align-items: start; }
@media (max-width: 1020px) { .wzb-grid { grid-template-columns: 1fr; } }
.wzb-col { display: flex; flex-direction: column; max-height: calc(100vh - 150px); overflow: hidden; }
.wzb-hd { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.wzb-list { flex: 1; overflow: auto; }
.wzb-cat { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; text-align: left; background: none; border: none; border-bottom: 1px solid #F1F3F6; border-left: 3px solid transparent; padding: 14px 16px; font-size: 13.5px; cursor: pointer; color: var(--ink); }
.wzb-cat.on { border-left-color: var(--green); background: #FAFBFC; font-weight: 600; }
.wzb-cat-t { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wzb-info { color: var(--green); font-size: 13px; }
.wzb-q { display: flex; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: 8px; padding: 13px 15px; margin-bottom: 10px; cursor: pointer; background: #fff; }
.wzb-q:hover { border-color: var(--green); }
.wzb-q.on { border-color: var(--green); background: var(--green-soft); }
.wzb-added { width: 26px; height: 26px; border-radius: 50%; background: var(--green); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; flex: none; }
.wzb-ft { border-top: 1px solid var(--line); padding: 12px 20px; display: flex; justify-content: flex-end; gap: 10px; }
.wzb-inc { display: flex; align-items: flex-start; gap: 8px; padding: 8px 4px; border-bottom: 1px solid #F1F3F6; }
.wzb-empty { text-align: center; padding: 60px 14px; }
.wzb-catchip { display: inline-block; background: var(--accent-soft); color: var(--green-dark); font-size: 12px; font-weight: 600; border-radius: 999px; padding: 5px 14px; margin-top: 4px; }

/* ---- Wizard: cronología y notificaciones ---- */
.ag-item { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.ag-num { width: 26px; height: 26px; border-radius: 50%; background: #DFE4EA; color: var(--ink-soft); display: inline-flex; align-items: center; justify-content: center; font-size: 12.5px; font-weight: 700; flex: none; margin-top: 2px; }
.ag-num.on { background: var(--green); color: #fff; }
.ag-title { font-size: 12.5px; letter-spacing: 0; text-transform: none; }
.wz-notif { display: flex; align-items: center; gap: 8px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.wz-notif .icon-btn { color: var(--green); }
.wz-toolbar { display: flex; gap: 4px; border: 1px solid var(--line); border-bottom: none; border-radius: 8px 8px 0 0; padding: 6px 8px; background: #FAFBFC; }
.tb-btn { border: none; background: none; cursor: pointer; font-size: 13px; padding: 3px 8px; border-radius: 5px; color: var(--ink); }
.tb-btn:hover { background: #EEF1F4; }
.wz-mailbody { border: 1px solid var(--line); border-radius: 0 0 8px 8px; min-height: 170px; padding: 12px 14px; font-size: 13px; outline: none; overflow: auto; max-height: 40vh; }
.wz-mailbody:focus { border-color: var(--green); }
.wz-mailprev-box { border: 1px solid var(--line); border-radius: 8px; padding: 16px 18px; background: #FAFBFC; max-height: 52vh; overflow: auto; }

/* ---- Wizard: resumen acordeones ---- */
.wiz-rz-tg { display: flex; justify-content: space-between; align-items: center; width: 100%; background: none; border: none; padding: 0; font-size: 13.5px; font-weight: 600; color: var(--ink-soft); cursor: pointer; }
.wiz-rz-sec.active .wiz-rz-tg { color: var(--green); }
.wiz-rz-chev { font-size: 11px; }
.wiz-rz-type { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; margin-top: 6px; }
.wiz-rz-resp { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin-top: 8px; }
.wiz-rz-count { background: #F4F6F8; border-radius: 8px; padding: 8px 12px; font-size: 12.5px; font-weight: 600; margin-top: 10px; }

/* ---- Perfiles y permisos (estructura Kenjo) ---- */
.prof-layout { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 980px) { .prof-layout { grid-template-columns: 1fr; } }
.prof-side { padding: 18px 0; position: sticky; top: 86px; }
.prof-side-hd { display: flex; align-items: center; justify-content: space-between; padding: 0 20px 14px; }
.prof-side-hd b { font-size: 15px; letter-spacing: 0; }
.prof-item { display: flex; align-items: center; gap: 6px; width: 100%; text-align: left; background: none; border: none;
  padding: 11px 20px; font-size: 13.5px; color: var(--green-dark); cursor: pointer; }
.prof-item:hover { background: var(--bg); }
.prof-item.on { background: var(--green-soft); font-weight: 600; }
.prof-count { color: var(--ink-soft); font-weight: 400; }
.prof-main { min-height: 420px; }
.prof-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.prof-bc { font-size: 20px; font-weight: 400; color: var(--ink-soft); }
.prof-bc span { color: var(--ink); }
.prof-tabs { display: flex; gap: 26px; }
.prof-tab { display: flex; align-items: center; gap: 6px; background: none; border: none; cursor: pointer;
  font-size: 13px; font-weight: 500; letter-spacing: 0; color: var(--ink-soft); padding: 3px 2px; border-bottom: 2px solid transparent; }
.prof-tab.on { color: var(--ink); border-color: var(--ink); }
.pf-name { max-width: 340px; }
.pf-name input { border: none; border-bottom: 1px dotted var(--line); border-radius: 0; padding: 6px 2px; font-size: 14px; background: transparent; }
.pf-name input:focus { border-bottom: 1px solid var(--green); outline: none; }
.pf-h3 { font-size: 16px; font-weight: 500; margin: 22px 0 12px; }
.pf-restricted-notice { margin-top: 22px; padding: 16px 18px; border-radius: 8px; background: rgba(255,191,0,.14); border: 1px solid rgba(255,191,0,.45); color: var(--ink); font-size: 13.5px; line-height: 1.55; }

/* Expediente del empleado (ficha individual, edición inline por sección) */
.archive-layout { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 20px; align-items: start; }
@media (max-width: 900px) { .archive-layout { grid-template-columns: 1fr; } }
.archive-main { display: flex; flex-direction: column; gap: 14px; }
.archive-sec { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.archive-sec > summary { cursor: pointer; list-style: none; user-select: none; }
.archive-sec > summary::-webkit-details-marker { display: none; }
.archive-sec > summary::before { content: '▸'; display: inline-block; margin-right: 8px; transition: transform .15s; color: var(--ink-soft); }
.archive-sec[open] > summary::before { transform: rotate(90deg); }
.archive-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 20px; padding: 14px 18px 4px; }
@media (max-width: 700px) { .archive-grid { grid-template-columns: 1fr; } }
.archive-side { position: sticky; top: 12px; }
.archive-side .btn.full { width: 100%; justify-content: center; }
.day-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.day-chip { border: 1px solid var(--line); background: transparent; border-radius: 999px; padding: 5px 10px; font-size: 12px; cursor: pointer; color: var(--ink-soft); }
.day-chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.pf-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
@media (max-width: 1180px) { .pf-grid { grid-template-columns: 1fr; } }
.pf-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.pf-card-hd { padding: 12px 16px; border-bottom: 1px solid var(--line); font-size: 14px; font-weight: 600; }
.pf-card-bd { padding: 14px 18px 18px; }
.pf-row { display: flex; align-items: flex-start; gap: 10px; padding: 7px 0; font-size: 13px; cursor: pointer; }
.pf-row span { line-height: 1.45; }
.pf-chk { width: 17px; height: 17px; flex: none; margin-top: 1px; accent-color: var(--accent); cursor: pointer; }
.pf-plus { width: 19px; height: 19px; flex: none; margin-top: 1px; border-radius: 50%; border: none; cursor: pointer;
  background: #C9D1DA; color: #fff; font-size: 12px; line-height: 1; display: flex; align-items: center; justify-content: center; }
.pf-plus:hover { background: var(--ink-soft); }
.pf-plus.on { background: var(--accent); }
.pf-chip { display: inline-flex; align-items: center; gap: 5px; background: var(--accent-soft); color: var(--accent-dark);
  font-size: 11px; font-weight: 600; border-radius: 999px; padding: 2px 8px; white-space: nowrap; }
.pf-clear { border: none; background: none; cursor: pointer; color: var(--accent-dark); font-size: 10px; padding: 0; }
.pf-member { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.pf-member:last-child { border-bottom: none; }

/* ---------- Asistente de bienvenida ---------- */
.wel-ta { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; resize: vertical; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; background: #EEF1F4; border-radius: 999px; padding: 4px 10px 4px 4px; font-size: 13px; font-weight: 500; }
.chip-x { font-size: 16px; line-height: 1; color: var(--muted); padding: 0 2px; }
.chip-x:hover { color: var(--danger); }
.welcome-card { background: var(--green-soft); border: 1px solid var(--green-soft-2); }

/* ---------- Calendario visual de festivos (Mi empresa) ---------- */
.hol-cal-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.hcm-title { font-weight: 600; font-size: 13px; margin-bottom: 6px; }
.hcm-dows, .hcm-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.hcm-dows span { text-align: center; font-size: 10px; color: var(--muted); margin-bottom: 2px; }
.hcm-day { aspect-ratio: 1; border: none; background: none; border-radius: 6px; font-size: 11px; color: var(--ink-soft); cursor: pointer; padding: 0; }
.hcm-day:hover { background: var(--green-soft); }
.hcm-day.hol { background: var(--green); color: #fff; font-weight: 700; }
@media (max-width: 760px) { .hol-cal-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------------- Registro de horas (fichaje) ---------------- */
.punch-card { text-align: center; }
.punch-state { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; padding: 5px 12px; border-radius: 999px; }
.punch-state.in  { background: var(--accent-soft); color: var(--accent-dark); }
.punch-state.out { background: #EEF1F4; color: var(--ink-soft); }
.punch-dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.punch-state.in .punch-dot { animation: punchPulse 1.6s infinite; }
@keyframes punchPulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
.punch-total { font-family: var(--font-display); font-variant-numeric: tabular-nums; font-size: 46px; font-weight: 600; line-height: 1.1; margin-top: 14px; color: var(--ink); }
.punch-btn { justify-content: center; }
.punch-btn.punch-out { background: var(--danger); border-color: var(--danger); color: #fff; }
.punch-btn.punch-out:hover { filter: brightness(.94); }
.punch-sessions { margin-top: 18px; text-align: left; }
.punch-sess { display: flex; justify-content: space-between; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.punch-sess:last-child { border-bottom: none; }
.punch-live { color: var(--accent-dark); font-weight: 600; font-size: 12px; }
.hbar-row { display: flex; gap: 8px; align-items: flex-end; margin-top: 8px; }
.hbar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.hbar-track { width: 100%; height: 130px; background: #EDECEC; border-radius: 2px; display: flex; align-items: flex-end; overflow: hidden; }
.hbar-fill { width: 100%; background: var(--green); border-radius: 2px 2px 0 0; min-height: 3px; transition: height .3s; }
.hbar-lbl { font-size: 11px; color: var(--muted); font-weight: 600; }
.hbar-val { font-size: 11px; color: var(--ink-soft); }

/* ---- Fuera de oficina centralizado ---- */
.ooo-tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.ooo-tpl { border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.ooo-tpl.gen { border-color: var(--green); background: var(--green-soft); }
.ooo-tpl.has { border-color: var(--green); }
.ooo-tpl-prev { font-size: 11.5px; color: var(--ink-soft); margin: 0; flex: 1; line-height: 1.45; }
.ooo-prev { border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; margin-top: 10px; background: #FAFBFC; color: var(--ink); }

/* ---- Perfiles: + azul relleno (Kenjo) y buscador ---- */
.prof-plus { width: 24px; height: 24px; border-radius: 50%; border: none; background: var(--ink); color: #fff; font-size: 15px; line-height: 1; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.prof-plus:hover { filter: brightness(1.1); }
.prof-search { margin: 0 20px 8px; }

/* ---- Perfiles y permisos: catálogo Kenjo (subtítulos, tríos, criterios) ---- */
.prof-plus { width: 26px; height: 26px; border-radius: 50%; border: none; background: var(--ink); color: #fff;
  font-size: 17px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; flex: none; }
.prof-plus:hover { filter: brightness(.92); }
.prof-row { display: flex; align-items: center; }
.prof-row.on { background: var(--green-soft); }
.prof-row .prof-item { flex: 1; background: none; }
.prof-row.on .prof-item { font-weight: 600; }
.prof-trash { color: var(--danger); margin-right: 10px; flex: none; }
.pf-sub { font-size: 12.5px; font-weight: 600; color: var(--ink); margin: 14px 0 4px; }
.pf-card-bd .pf-sub:first-child { margin-top: 0; }
.pf-row.pf-trio { padding-left: 16px; }
.pf-chip { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.pf-rules { width: 640px; max-width: 94vw; }
.pf-rule { border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; margin-top: 12px; }
.pf-rule-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 12px; }
@media (max-width: 700px) { .pf-rule-grid { grid-template-columns: 1fr; } }
.pf-rule-grid .dir-filter { width: 100%; }
.pf-rule-grid input.dir-filter { border: 1px solid var(--line); border-radius: 8px; padding: 6px 9px; font-size: 12.5px; }
.pf-search-wrap { position: relative; margin-bottom: 16px; }
.pf-sugg { position: absolute; z-index: 5; top: 40px; left: 0; width: 340px; max-width: 100%; background: #fff;
  border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow-lg); overflow: hidden; }
.pf-sugg-it { display: flex; align-items: center; gap: 9px; width: 100%; text-align: left; background: none;
  border: none; border-bottom: 1px solid #F1F3F6; padding: 8px 12px; font-size: 13px; cursor: pointer; }
.pf-sugg-it:last-child { border-bottom: none; }
.pf-sugg-it:hover { background: var(--green-soft); }
.pf-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.pf-mchip { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 999px;
  padding: 5px 10px 5px 5px; font-size: 13px; background: #fff; }
.pf-mchip .icon-btn { width: 20px; height: 20px; font-size: 11px; color: var(--ink-soft); }
.pf-mchip .icon-btn:hover { color: var(--danger); }

/* ===========================================================================
   Inicio · Vista general (misma estructura que el home de Kenjo, marca Singular)
   =========================================================================== */
.home { max-width: 980px; margin: 0 auto; }
.home-top { display: flex; justify-content: flex-end; margin: -4px 0 2px; }
.ann { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); max-width: 560px; margin: 0 auto 20px; padding: 14px 16px 12px; }
.ann-empty { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; }
.ann-hd { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.ann-hd .who { flex: 1; min-width: 0; }
.ann-hd .who b { display: block; font-size: 13.5px; }
.ann-hd .who span { color: var(--muted); font-size: 12px; }
.ann-actions { display: flex; gap: 2px; }
.ann-actions .icon-btn { width: 28px; height: 28px; color: var(--green); }
.ann-actions .icon-btn.danger { color: var(--danger); }
.ann-body { border: 1px solid var(--line); border-radius: 6px; padding: 18px 16px 24px; min-height: 96px; text-align: center; }
.ann-body h2 { font-size: 16px; font-weight: 700; color: var(--green-dark); margin-bottom: 8px; }
.ann-body p { color: var(--ink-soft); line-height: 1.55; font-size: 13.5px; }
.ann-foot { display: flex; justify-content: flex-end; align-items: center; gap: 6px; margin-top: 12px; }
.ann-foot .react { padding: 2px 8px; font-size: 12.5px; background: #fff; border: 1px solid var(--line-strong); border-radius: 4px; font-weight: 500; }
.ann-foot .react.mine { border-color: var(--green); background: var(--green-soft); color: var(--green-dark); }
.ann-foot .react-add { width: 30px; height: 26px; border-radius: 4px; background: #fff; border: 1px solid var(--line-strong); color: var(--ink-soft); }
.ann-foot .react-add:hover { background: var(--green-soft); }
.emoji-pop { position: absolute; bottom: 34px; right: 0; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 6px; box-shadow: var(--shadow-lg); display: flex; gap: 2px; z-index: 5; }
.emoji-pop .react-pick { font-size: 18px; padding: 4px 6px; border-radius: 6px; }
.emoji-pop .react-pick:hover { background: var(--bg); }
.home-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: start; }
@media (max-width: 1100px) { .home-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 700px) { .home-grid { grid-template-columns: 1fr; } }
.wg { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); display: flex; flex-direction: column; }
.wg-hd { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--line); font-size: 13.5px; font-weight: 600; }
.wg-hd .icon-btn { width: 26px; height: 26px; color: var(--ink-soft); }
.wg-link { background: none; border: none; color: var(--green); font-size: 12px; font-weight: 600; cursor: pointer; padding: 0; }
.wg-link:hover { text-decoration: underline; }
.wg-new { background: none; border: 1px solid var(--green); color: var(--green); font-size: 10.5px; font-weight: 600; padding: 1px 8px; border-radius: 999px; margin-left: 6px; vertical-align: middle; }
.wg-bd { padding: 12px 14px; max-height: 214px; overflow-y: auto; }
.wg-bd p { color: var(--ink-soft); font-size: 13px; line-height: 1.5; margin: 0; }
.wg-lbl { font-size: 11px; font-weight: 600; color: var(--muted); margin: 8px 0 8px; }
.wg-lbl:first-child { margin-top: 0; }
.wg-avs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 6px; }
.wg-av { position: relative; display: inline-flex; cursor: pointer; border-radius: 50%; }
.wg-av .avatar { border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); }
.wg-av--today .avatar, .wg-av--me .avatar { box-shadow: 0 0 0 2px var(--green); }
.wg-badge { position: absolute; right: -3px; bottom: -3px; width: 16px; height: 16px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; border: 2px solid #fff; }
.wg-foot { border-top: 1px solid var(--line); background: var(--bg); padding: 10px 14px; font-size: 12px; color: var(--ink-soft); min-height: 54px; line-height: 1.45; border-radius: 0 0 var(--radius) var(--radius); }
.wg-foot b { display: block; font-size: 13px; color: var(--ink); margin-bottom: 2px; }
.wg-chart { margin-top: 10px; }
.wg-chart svg { width: 100%; height: auto; display: block; }
.usage-svg text { font-size: 8.5px; fill: var(--muted); font-family: var(--font-sans); }
.usage-svg line { stroke: var(--line-strong); }
.wg-foot:has(.wg-foot-btn) { background: #fff; display: flex; align-items: center; justify-content: center; }
.wg-chart-t { font-size: 12.5px; font-weight: 600; margin-bottom: 6px; text-align: center; }

/* ===========================================================================
   Organigrama: árbol jerárquico (misma estructura que Kenjo)
   =========================================================================== */
.oc-toolbar { display: flex; align-items: center; gap: 18px; padding: 4px 2px 12px; }
.oc-toolbar .wg-link { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; }
.oc-wrap { position: relative; height: calc(100vh - 130px); min-height: 480px; overflow: hidden; display: flex; }
.oc-views { width: 220px; flex: none; border-right: 1px solid var(--line); background: #fff; z-index: 2; overflow-y: auto; }
.oc-views-hd { padding: 12px 14px 8px; font-size: 12px; font-weight: 600; color: var(--muted); }
.oc-view { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 9px 14px; font-size: 13px; cursor: pointer; }
.oc-view:hover { background: var(--bg); }
.oc-view.on { background: var(--green-soft); font-weight: 600; }
.oc-view .icon-btn { width: 22px; height: 22px; color: var(--muted); }
.oc-canvas { flex: 1; position: relative; overflow: hidden; cursor: grab; background: #fff; }
.oc-canvas.dragging { cursor: grabbing; }
.oc-tree { position: absolute; top: 0; left: 0; transform-origin: 0 0; will-change: transform; padding: 0 20px 40px; white-space: nowrap; }
.oc-tree ul { display: flex; justify-content: center; padding: 22px 0 0; margin: 0; list-style: none; position: relative; }
.oc-tree ul ul::before { content: ''; position: absolute; top: 0; left: 50%; border-left: 1px solid var(--line-strong); height: 22px; }
.oc-tree li { position: relative; padding: 22px 5px 0; text-align: center; list-style: none; }
.oc-tree li::before, .oc-tree li::after { content: ''; position: absolute; top: 0; right: 50%; border-top: 1px solid var(--line-strong); width: 50%; height: 22px; }
.oc-tree li::after { right: auto; left: 50%; border-left: 1px solid var(--line-strong); }
.oc-tree li:only-child::after, .oc-tree li:only-child::before { display: none; }
.oc-tree li:only-child { padding-top: 22px; }
.oc-tree li:first-child::before, .oc-tree li:last-child::after { border: 0 none; }
.oc-tree li:last-child::before { border-right: 1px solid var(--line-strong); border-radius: 0 3px 0 0; }
.oc-tree li:first-child::after { border-radius: 3px 0 0 0; }
.oc-tree > ul { padding-top: 0; }
.oc-tree > ul > li { padding-top: 0; }
.oc-tree > ul > li::before, .oc-tree > ul > li::after { display: none; }
.oc-node { display: inline-flex; flex-direction: column; align-items: center; position: relative; }
.oc-card { width: 108px; background: #fff; border: 1px solid var(--line); border-top: 2px solid var(--green); border-radius: 4px; padding: 8px 6px 7px; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 3px; box-shadow: var(--shadow); transition: box-shadow .15s; }
.oc-card:hover { box-shadow: var(--shadow-lg); }
.oc-card .avatar { flex: none; }
.oc-card b { font-size: 10.5px; line-height: 1.2; max-width: 94px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.oc-card span { font-size: 9px; line-height: 1.2; color: var(--muted); max-width: 94px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.oc-count { width: 18px; height: 18px; border-radius: 50%; border: 1px solid var(--line-strong); background: #fff; font-size: 9.5px; font-weight: 600; color: var(--ink-soft); margin-top: 3px; cursor: pointer; display: grid; place-items: center; position: relative; z-index: 1; line-height: 1; padding: 0; }
.oc-count:hover { border-color: var(--green); color: var(--green-dark); }
.oc-count.closed { background: var(--green); border-color: var(--green); color: #fff; }
.oc-ctrls { position: absolute; right: 14px; bottom: 14px; display: flex; flex-direction: column; gap: 4px; z-index: 3; }
.oc-ctrls button { width: 32px; height: 32px; border: 1px solid var(--line); border-radius: 6px; background: #fff; color: var(--ink-soft); display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow); }
.oc-ctrls button:hover { color: var(--ink); border-color: var(--line-strong); }

/* ---- Paridad Kenjo: barra de herramientas, tarjeta de filtros, paginador, tabla compacta ---- */
.page-head--acts { justify-content: flex-end; margin-bottom: 12px; }
.ktb { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.ktb .spacer { flex: 1; }
.kviews { display: inline-flex; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 7px 12px; font-size: 13px; color: var(--ink-soft); cursor: pointer; font-family: inherit; }
.kviews b { color: var(--ink); font-weight: 600; }
.btn.link { background: none; color: var(--green); border: none; padding: 6px 8px; font-weight: 600; font-size: 13px; box-shadow: none; }
.btn.link:hover { background: var(--green-soft); color: var(--green-dark); }
.kfilters { padding: 0; margin-bottom: 12px; overflow: hidden; }
.kfilters.inset { margin: 0; border: none; border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: none; }
.kfilters-row { display: flex; flex-wrap: wrap; align-items: stretch; }
.kfilters-row .dir-filter { border: none; border-right: 1px solid var(--line); border-radius: 0; background: #fff; min-width: 160px; padding: 12px 14px; font-size: 13px; color: var(--ink); }
.kfilters-row .dir-filter:focus { outline: none; box-shadow: inset 0 -2px 0 var(--green); }
.kfilters-search { flex: 1; min-width: 200px; border: none; border-radius: 0; background: #fff; padding: 8px 14px; }
.kfilters-status { display: flex; align-items: center; justify-content: space-between; padding: 6px 8px 6px 14px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--ink-soft); }
.kpager { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--ink-soft); }
.kpager-size { border: 1px solid var(--line); border-radius: 4px; padding: 3px 6px; font-size: 12.5px; background: #fff; font-family: inherit; }
.kpager .icon-btn[disabled] { opacity: .35; cursor: default; }
.table.compact th { font-size: 12px; padding: 10px 12px; }
.table.compact td { padding: 6px 12px; font-size: 13px; }
.table.compact .tbl-name { gap: 8px; }
.tbl-link { text-decoration: none; color: inherit; }
.tbl-link span:last-child { font-weight: 500; color: var(--green-dark); }
.ellipsis { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: inline-block; vertical-align: bottom; }
.doc-ext { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 20px; padding: 0 4px; border-radius: 3px; background: var(--green-soft); color: var(--green); font-size: 10px; font-weight: 700; }
.doc-ext.lg { min-width: 44px; height: 30px; font-size: 12px; margin-bottom: 8px; }
.doc-card { text-decoration: none; color: inherit; }

/* ---- Ausencias · Personal ---- */
.bal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin-bottom: 14px; }
.bal-card .center { text-align: center; }
.aus-grid { display: grid; grid-template-columns: 300px 1fr; gap: 14px; align-items: start; }
.hist-card { overflow: hidden; }
.hist-card .wg-hd { padding: 12px 16px; }
.hist-detail td { background: var(--bg); }
@media (max-width: 1000px) { .aus-grid { grid-template-columns: 1fr; } }

/* ---- Calendario · cronología anual ---- */
.tlk { display: flex; overflow: hidden; }
.tlk-side { width: 260px; flex: none; border-right: 1px solid var(--line); }
.tlk-head { display: flex; align-items: center; justify-content: space-between; padding: 0 10px 0 6px; border-bottom: 1px solid var(--line); height: 55px; box-sizing: border-box; }
.tlk-year { display: flex; align-items: center; gap: 2px; font-size: 14px; }
.tlk-person { display: flex; align-items: center; gap: 8px; height: 35px; box-sizing: border-box; padding: 0 10px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); font-size: 13px; }
.tlk-person .tlk-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tlk-person svg { color: var(--muted); }
.tlk-scroll { flex: 1; overflow-x: auto; overflow-y: hidden; }
.tlk-table { border-collapse: collapse; table-layout: fixed; }
.tlk-table th, .tlk-table td { width: 26px; min-width: 26px; padding: 0; text-align: center; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.tlk-months th { height: 22px; font-size: 12px; font-weight: 600; color: var(--ink-soft); text-align: left; padding-left: 8px; border-right: 1px solid var(--line-strong); }
.tlk-days th { height: 32px; font-weight: 400; }
.tlk-days th span { display: block; font-size: 9px; color: var(--muted); line-height: 1; }
.tlk-days th b { display: block; font-size: 11px; font-weight: 500; line-height: 1.3; }
.tlk-table td { height: 34px; }
.tlk-table .we { background: var(--bg); }
.tlk-table .today { background: var(--green-soft); }
.tlk-days th.today b { color: var(--green); font-weight: 700; }
.tlk-legend { display: flex; gap: 20px; padding: 12px 4px; font-size: 12.5px; color: var(--ink-soft); }
.tlk-legend > span { display: inline-flex; align-items: center; gap: 6px; }
.task-page { max-width: 880px; margin: 0 auto; }
