/* ════════════════════════════════════════════════════════════════════════════
   parte_mensual.css
   ════════════════════════════════════════════════════════════════════════════ */

/* ── Tab pane layout ─────────────────────────────────────────────────────── */

#pills-parte-mensual {
  flex-direction: column;
  height: calc(100vh - 110px);
  overflow: hidden;
}
#pills-parte-mensual.show.active {
  display: flex !important;
  height: calc(100vh - 110px) !important;
  min-height: 0;
  overflow: hidden;
}
#pills-parte-mensual > .tab-section-header {
  position: static;
  top: unset;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════════════
   KPI STRIP (dentro del admin view, antes del buscador)
   ═══════════════════════════════════════════════════════════════════════════ */

.pm-kpi-strip {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 0 4px;
  font-size: .76rem;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(148,163,184,.07);
}
.pm-kpi-sep  { color: rgba(148,163,184,.25); }
.pm-kpi-item { color: #64748b; }
.pm-kpi-item span { font-weight: 700; font-size: .82rem; color: #94a3b8; }
.pm-kpi-item--danger span { color: #f87171; }
.pm-kpi-item--warn   span { color: #fbbf24; }
.pm-kpi-item--info   span { color: #38bdf8; }

/* Fix fv2-create-icon size */
#pmIncModal .fv2-create-icon,
#pmExportModal .fv2-create-icon { font-size: 1rem; margin-top: 0; }

/* ═══════════════════════════════════════════════════════════════════════════
   OFFCANVAS: Incidencia (pm-inc-offcanvas)
   ═══════════════════════════════════════════════════════════════════════════ */

#pmIncModal.offcanvas-bottom {
  height: 88vh;
  max-height: 88vh;
  border-radius: 1rem 1rem 0 0;
  border: 1px solid rgba(148,163,184,.15);
  border-bottom: none;
  background: #0f172a;
  overflow: hidden;
}

.pm-inc-drag-handle {
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: rgba(148,163,184,.22);
  margin: 8px auto 2px;
  flex-shrink: 0;
}

.pm-inc-offcanvas .offcanvas-header {
  flex-shrink: 0;
  padding: .55rem 1.25rem .5rem;
}

.pm-inc-offcanvas .offcanvas-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: .9rem 1.25rem 1rem;
}

.pm-inc-offcanvas-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .5rem;
  padding: .6rem 1.25rem;
  border-top: 1px solid rgba(148,163,184,.08);
  flex-shrink: 0;
  background: #0f172a;
}

/* Responsable upick placeholder */
.pm-resp-placeholder {
  pointer-events: none;
  flex: 1;
  font-size: .8rem;
  color: rgba(148,163,184,.42);
}

/* ═══════════════════════════════════════════════════════════════════════════
   MODALES DE GESTIÓN — Oficinas y Tipos
   ═══════════════════════════════════════════════════════════════════════════ */

.pm-mgr-list {
  max-height: 440px;
  overflow-y: auto;
}
.pm-mgr-empty {
  padding: 22px 16px;
  font-size: .81rem;
  color: #334155;
  text-align: center;
}

/* Row base */
.pm-mgr-row {
  border-bottom: 1px solid rgba(148,163,184,.06);
}
.pm-mgr-row-main {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px;
}
.pm-mgr-row--editing {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  background: rgba(255,255,255,.02);
}
.pm-mgr-row--editing .form-control {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.12);
  color: #f1f5f9;
  flex: 1;
}
.pm-mgr-row--editing .form-control::placeholder { color: rgba(148,163,184,.38); }

.pm-mgr-name {
  font-size: .82rem;
  color: #e2e8f0;
  font-weight: 500;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pm-mgr-meta {
  font-size: .7rem;
  color: #2d3f56;
  flex-shrink: 0;
}
.pm-mgr-btns {
  display: flex;
  gap: 1px;
  flex-shrink: 0;
  opacity: 0;
  transition: opacity .1s;
}
.pm-mgr-row:hover .pm-mgr-btns { opacity: 1; }

.pm-mgr-btn--active { color: #60a5fa !important; }

/* Add row (footer del modal) */
.pm-mgr-add-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid rgba(148,163,184,.08);
  background: rgba(0,0,0,.08);
}
.pm-mgr-add-row .form-control {
  background: rgba(255,255,255,.05);
  border-color: rgba(255,255,255,.1);
  color: #f1f5f9;
  flex: 1;
  min-width: 0;
}
.pm-mgr-add-row .form-control::placeholder { color: rgba(148,163,184,.35); }

/* Members panel */
.pm-mgr-members {
  background: rgba(0,0,0,.1);
  border-top: 1px solid rgba(148,163,184,.05);
  padding: 8px 16px 8px 34px;
}
.pm-mgr-members-list { margin-bottom: 6px; }
.pm-mgr-member {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 3px 0;
  font-size: .77rem;
  color: #94a3b8;
}
.pm-mgr-member span { flex: 1; }
.pm-mgr-member i { font-size: .68rem; color: #334155; }
.pm-mgr-empty-members {
  font-size: .74rem;
  color: #2d3f56;
  padding: 2px 0 6px;
  font-style: italic;
}
.pm-mgr-add-member .form-select {
  background: rgba(255,255,255,.05);
  border-color: rgba(255,255,255,.1);
  color: #94a3b8;
  font-size: .78rem;
}
.pm-mgr-add-member .form-select option { background: #1e293b; }
.pm-mgr-loading {
  display: flex;
  align-items: center;
  font-size: .74rem;
  color: #475569;
  padding: 4px 0;
}

/* ── Responsable readonly (usuario no-admin) ──────────────────────────────── */
.pm-upick-readonly {
  opacity: .6;
  pointer-events: none;
  cursor: default;
}

/* ── Botón Asignarme ─────────────────────────────────────────────────────── */
.pm-asignarme-btn {
  background: none;
  border: 1px solid rgba(148,163,184,.2);
  border-radius: .32rem;
  color: #64748b;
  font-size: .73rem;
  padding: .12rem .45rem;
  cursor: pointer;
  transition: color .1s, border-color .1s, background .1s;
  white-space: nowrap;
}
.pm-asignarme-btn:hover {
  color: #93c5fd;
  border-color: rgba(96,165,250,.4);
  background: rgba(96,165,250,.06);
}

/* ── Planilla toggle button ──────────────────────────────────────────────── */
.pm-planilla-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: #334155;
  font-size: .95rem;
  padding: 1px 4px;
  border-radius: 4px;
  line-height: 1;
  transition: color .1s;
}
.pm-planilla-btn:hover   { color: #94a3b8; }
.pm-planilla-btn.is-on   { color: #4ade80; }
.pm-planilla-btn:disabled { opacity: .35; cursor: default; }

/* ── Planilla badge (user view cards) ───────────────────────────────────── */
.pm-planilla-badge {
  font-size: .66rem;
  font-weight: 600;
  background: rgba(74,222,128,.1);
  border: 1px solid rgba(74,222,128,.25);
  border-radius: 4px;
  color: #4ade80;
  padding: 2px 7px;
}

/* ── Oficina members panel (dentro del upick) ───────────────────────────── */
.pm-ofi-members-panel {
  background: rgba(255,255,255,.03);
  border-top: 1px solid rgba(148,163,184,.1);
  border-bottom: 1px solid rgba(148,163,184,.1);
  padding: 5px 8px;
  margin: 2px 0;
}
.pm-ofi-members-head {
  font-size: .68rem;
  font-weight: 600;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 4px;
}
.pm-ofi-members-list { margin-bottom: 5px; }
.pm-ofi-member-row {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 2px 0;
  font-size: .78rem;
  color: #94a3b8;
}
.pm-ofi-member-name { flex: 1; }
.pm-ofi-members-add .form-select {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.12);
  color: #f1f5f9;
  font-size: .78rem;
}
.pm-ofi-members-add .form-select option { background: #1e293b; }
.pm-ofi-members-loading {
  padding: 5px 8px;
  font-size: .75rem;
  color: #64748b;
}

/* ═══════════════════════════════════════════════════════════════════════════
   HEADER UPICK PILLS (filtros del admin en el header)
   Misma altura y look que calls-hdr-select, con estado activo coloreado
   ═══════════════════════════════════════════════════════════════════════════ */

.pm-hdr-upick {
  position: relative;
  display: inline-flex;
}

.pm-hdr-upick-row {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(15,23,42,.7);
  border: 1px solid rgba(148,163,184,.18);
  border-radius: .38rem;
  padding: .2rem .55rem;
  min-height: 1.72rem;
  cursor: pointer;
  font-size: .78rem;
  color: #94a3b8;
  white-space: nowrap;
  user-select: none;
  transition: border-color .12s, background .12s;
}
.pm-hdr-upick-row:hover {
  border-color: rgba(148,163,184,.35);
  color: #cbd5e1;
}
.pm-hdr-upick-row.is-open {
  border-color: rgba(96,165,250,.55);
  color: #e2e8f0;
}
.pm-hdr-upick-row.is-active {
  border-color: rgba(99,102,241,.45);
  background: rgba(99,102,241,.08);
  color: #a5b4fc;
}
.pm-hdr-upick-row.is-active.is-open {
  border-color: rgba(99,102,241,.7);
}

.pm-hdr-upick-label    { line-height: 1; }
.pm-hdr-upick-placeholder { color: rgba(148,163,184,.55); }

.pm-hdr-upick-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.pm-hdr-upick-chev {
  font-size: .6rem;
  color: rgba(148,163,184,.38);
  transition: transform .15s;
  pointer-events: none;
  flex-shrink: 0;
}
.pm-hdr-upick-row.is-open .pm-hdr-upick-chev { transform: rotate(180deg); }

.pm-hdr-upick-clear {
  background: none;
  border: none;
  padding: 0;
  color: rgba(165,180,252,.45);
  cursor: pointer;
  font-size: .72rem;
  line-height: 1;
  margin-left: 1px;
  transition: color .1s;
}
.pm-hdr-upick-clear:hover { color: #f87171; }

/* ── Checkbox "Eliminadas" ── */
.pm-hdr-check-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  font-size: .78rem;
  color: #94a3b8;
  padding: .2rem .45rem;
  border: 1px solid rgba(148,163,184,.18);
  border-radius: .38rem;
  background: rgba(15,23,42,.7);
  transition: border-color .12s, color .12s;
  user-select: none;
  white-space: nowrap;
}
.pm-hdr-check-label:hover { border-color: rgba(148,163,184,.35); color: #cbd5e1; }
.pm-hdr-check-label:has(.pm-hdr-check:checked),
.pm-hdr-check-label.is-checked {
  border-color: rgba(251,191,36,.45);
  background: rgba(251,191,36,.06);
  color: #fbbf24;
}
.pm-hdr-check {
  accent-color: #f59e0b;
  width: 12px;
  height: 12px;
  cursor: pointer;
}

/* ═══════════════════════════════════════════════════════════════════════════
   PM-TIP — Tooltip system (mismo patrón que .ca-tip de llamadas)
   ═══════════════════════════════════════════════════════════════════════════ */

.pm-tip {
  position: fixed;
  z-index: 9999;
  background: #1e293b;
  color: #e2e8f0;
  font-size: .72rem;
  line-height: 1.35;
  padding: .28rem .6rem;
  border-radius: .32rem;
  border: 1px solid rgba(148,163,184,.18);
  box-shadow: 0 4px 14px rgba(0,0,0,.55);
  pointer-events: none;
  white-space: normal;
  max-width: 280px;
  text-align: center;
  opacity: 0;
  transition: opacity .12s;
}
.pm-tip.is-visible { opacity: 1; }

/* ═══════════════════════════════════════════════════════════════════════════
   ADMIN VIEW
   ═══════════════════════════════════════════════════════════════════════════ */

#pmAdminView {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

/* Admin layout: sidebar oficinas + tabla */
.pm-adm-layout {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.pm-adm-sidebar {
  width: 175px;
  min-width: 130px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(148,163,184,.08);
  overflow: hidden;
}
.pm-adm-sidebar-head {
  padding: 7px 10px 5px;
  font-size: .65rem;
  font-weight: 700;
  color: #334155;
  text-transform: uppercase;
  letter-spacing: .07em;
  border-bottom: 1px solid rgba(148,163,184,.07);
  flex-shrink: 0;
}
.pm-adm-sidebar-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 4px 0;
}

.pm-oficina-li {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px 5px 10px;
  cursor: pointer;
  font-size: .79rem;
  color: #475569;
  border-radius: 5px;
  margin: 1px 4px;
  transition: background .1s, color .1s;
  list-style: none;
}
.pm-oficina-li:hover     { background: rgba(255,255,255,.04); color: #94a3b8; }
.pm-oficina-li.is-active { background: rgba(99,102,241,.12); color: #a5b4fc; }
.pm-oficina-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }
.pm-ofi-count {
  font-size: .65rem;
  font-weight: 600;
  color: #334155;
  flex-shrink: 0;
}

/* Botón auditoría por oficina */
.pm-ofi-aud-btn {
  background: none;
  border: none;
  color: #1d3461;
  font-size: .72rem;
  padding: 2px 4px;
  border-radius: 4px;
  cursor: pointer;
  flex-shrink: 0;
  line-height: 1;
  transition: color .12s, background .12s;
  opacity: 0;
}
.pm-oficina-li:hover .pm-ofi-aud-btn { opacity: 1; }
.pm-ofi-aud-btn:hover { color: #60a5fa; background: rgba(59,130,246,.12); }

/* ─── Table area ─────────────────────────────────────────────────────────── */
.pm-adm-main {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}
.pm-adm-table-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

/* ─── Responsive column visibility ──────────────────────────────────────── */
@media (max-width: 1199.98px) { .pm-col-periodo { display: none !important; } }
@media (max-width:  991.98px) { .pm-col-resp    { display: none !important; } }
@media (max-width:  767.98px) { .pm-col-tipo    { display: none !important; } }
@media (max-width:  575.98px) { .pm-col-fecha   { display: none !important; } }

/* ─── Table base ─────────────────────────────────────────────────────────── */
.pm-adm-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;
}

/* ─── Headers ────────────────────────────────────────────────────────────── */
.pm-adm-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #060c18;
  white-space: nowrap;
  font-size: .62rem;
  font-weight: 700;
  color: #2d3f56;
  text-transform: uppercase;
  letter-spacing: .07em;
  padding: 7px 10px;
  border-bottom: 1px solid rgba(148,163,184,.1);
  user-select: none;
}
.pm-adm-table thead th.pm-tbl-planilla { text-align: center; font-size: .82rem; color: #334155; }
.pm-adm-table thead th.pm-tbl-actions  { width: 1%; }

/* ─── Rows ───────────────────────────────────────────────────────────────── */
.pm-adm-row td {
  padding: 7px 10px;
  vertical-align: middle;
  border-bottom: 1px solid rgba(148,163,184,.05);
}
.pm-adm-row { transition: background .08s; }
.pm-adm-row:hover td { background: rgba(255,255,255,.03); }
.pm-adm-row.pm-row-deleted td          { opacity: .38; }
.pm-adm-row.pm-row-deleted .pm-tbl-actions { opacity: 1 !important; }

/* ─── Fecha ──────────────────────────────────────────────────────────────── */
.pm-tbl-fecha { white-space: nowrap; }
.pm-tbl-fecha-val {
  font-size: .71rem;
  color: #64748b;
  font-variant-numeric: tabular-nums;
  cursor: default;
  letter-spacing: .01em;
}

/* ─── Período chip ───────────────────────────────────────────────────────── */
.pm-period-chip {
  display: inline-block;
  background: rgba(148,163,184,.07);
  border: 1px solid rgba(148,163,184,.1);
  border-radius: .28rem;
  padding: .1rem .42rem;
  font-size: .68rem;
  color: #475569;
  white-space: nowrap;
  letter-spacing: .01em;
}

/* ─── Oficina ────────────────────────────────────────────────────────────── */
.pm-tbl-ofi { max-width: 160px; }
.pm-tbl-ofi-inner {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  max-width: 100%;
  cursor: default;
  min-width: 0;
}
.pm-tbl-ofi-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #e2e8f0;
  font-size: .77rem;
}

/* ─── Tipo tag ───────────────────────────────────────────────────────────── */
.pm-tipo-tag {
  display: inline-block;
  background: rgba(99,102,241,.09);
  border: 1px solid rgba(99,102,241,.18);
  color: #818cf8;
  border-radius: .26rem;
  padding: .1rem .4rem;
  font-size: .64rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  white-space: nowrap;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: default;
}

/* ─── Descripción ────────────────────────────────────────────────────────── */
.pm-tbl-desc { max-width: 0; width: 38%; }
.pm-desc-text {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #f1f5f9;
  font-size: .79rem;
  cursor: default;
  max-width: 340px;
}
.pm-desc-empty { color: #334155; }

/* ─── Responsable chip ───────────────────────────────────────────────────── */
.pm-col-resp { white-space: nowrap; max-width: 140px; }
.pm-resp-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 130px;
  cursor: default;
}
.pm-resp-chip i   { font-size: .7rem; color: #475569; flex-shrink: 0; }
.pm-resp-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: .74rem;
  color: #94a3b8;
}
.pm-tbl-none { color: #2d3f56; font-size: .75rem; }

/* ─── Planilla cell ──────────────────────────────────────────────────────── */
.pm-tbl-planilla { width: 40px; text-align: center; }

/* ─── Actions cell ───────────────────────────────────────────────────────── */
.pm-tbl-actions { width: 1%; white-space: nowrap; text-align: right; }

/* ─── Icon buttons — color-coded ────────────────────────────────────────── */
.pm-ib-edit    { color: #134e26; }
.pm-ib-del     { color: #4d1f1f; }
.pm-ib-restore { color: #3d320e; }

.pm-ib-edit:hover    { color: #4ade80; border-color: rgba(74,222,128,.28);  background: rgba(74,222,128,.07);  }
.pm-ib-del:hover     { color: #f87171; border-color: rgba(248,113,113,.28); background: rgba(248,113,113,.07); }
.pm-ib-restore:hover { color: #fbbf24; border-color: rgba(251,191,36,.28);  background: rgba(251,191,36,.07);  }

/* ─── Empty state ────────────────────────────────────────────────────────── */
.pm-adm-empty {
  text-align: center;
  padding: 52px 20px;
}
.pm-adm-empty > i  { font-size: 2rem; display: block; margin-bottom: 10px; color: #1e293b; }
.pm-adm-empty > div   { font-size: .82rem; color: #334155; margin-bottom: 4px; }
.pm-adm-empty > small { font-size: .74rem; color: #1e293b; }

/* ═══════════════════════════════════════════════════════════════════════════
   USER VIEW
   ═══════════════════════════════════════════════════════════════════════════ */

#pmUserView {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

/* ─── Period nav ─────────────────────────────────────────────────────────── */
.pm-my-period-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 10px 0 9px;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(148,163,184,.07);
}
.pm-my-period-label {
  font-size: 1rem;
  font-weight: 700;
  color: #e2e8f0;
  min-width: 150px;
  text-align: center;
  letter-spacing: -.01em;
}
.pm-my-period-btn {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(148,163,184,.14);
  border-radius: 7px;
  color: #475569;
  padding: 5px 14px;
  cursor: pointer;
  font-size: .8rem;
  line-height: 1;
  transition: background .1s, color .1s, border-color .1s;
}
.pm-my-period-btn:hover {
  background: rgba(255,255,255,.08);
  border-color: rgba(148,163,184,.28);
  color: #e2e8f0;
}

/* ─── List scroll ────────────────────────────────────────────────────────── */
.pm-my-list-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 10px 2px 20px;
}

/* ─── Empty state ────────────────────────────────────────────────────────── */
.pm-my-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 56px 20px;
  gap: 5px;
}
.pm-my-empty i     { font-size: 1.9rem; color: #1e293b; margin-bottom: 5px; }
.pm-my-empty div   { font-size: .83rem; color: #334155; }
.pm-my-empty small { font-size: .74rem; color: #1e293b; }

/* ─── Card base ──────────────────────────────────────────────────────────── */
.pm-my-card {
  background: rgba(255,255,255,.022);
  border: 1px solid rgba(148,163,184,.08);
  border-radius: 10px;
  padding: 11px 14px 9px;
  margin-bottom: 7px;
  transition: border-color .12s, background .12s;
}
.pm-my-card:hover {
  border-color: rgba(148,163,184,.18);
  background: rgba(255,255,255,.03);
}

/* ─── Card head ──────────────────────────────────────────────────────────── */
.pm-my-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
  min-width: 0;
}
.pm-my-head-left {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  min-width: 0;
  flex: 1;
}
.pm-my-head-right {
  display: flex;
  align-items: center;
  gap: 1px;
  flex-shrink: 0;
  opacity: 0;
  transition: opacity .12s;
}
.pm-my-card:hover .pm-my-head-right { opacity: 1; }

/* ─── Description ────────────────────────────────────────────────────────── */
.pm-my-desc {
  font-size: .83rem;
  color: #e2e8f0;
  line-height: 1.55;
  margin-bottom: 9px;
  word-break: break-word;
  white-space: pre-wrap;
}
.pm-my-desc--empty {
  color: #2d3f56;
  font-size: .78rem;
  font-style: italic;
  margin-bottom: 9px;
}

/* ─── Meta chips row ─────────────────────────────────────────────────────── */
.pm-my-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 9px;
}
.pm-my-meta-sep { color: rgba(148,163,184,.18); user-select: none; }
.pm-my-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .73rem;
  color: #64748b;
  cursor: default;
  min-width: 0;
}
.pm-my-meta-chip i { font-size: .68rem; flex-shrink: 0; color: #334155; }
.pm-my-meta-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 180px;
}

/* ─── Card footer ────────────────────────────────────────────────────────── */
.pm-my-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px solid rgba(148,163,184,.05);
  padding-top: 7px;
}
.pm-my-foot-ts {
  font-size: .7rem;
  color: #2d3f56;
  cursor: default;
  font-variant-numeric: tabular-nums;
}

/* ── legacy classes – placeholder so old selectors don't break ─────────── */
.pm-my-tipo-badge {
  font-size: .68rem;
  font-weight: 600;
  background: rgba(148,163,184,.1);
  border: 1px solid rgba(148,163,184,.18);
  border-radius: 4px;
  color: #94a3b8;
  padding: 2px 7px;
  text-transform: uppercase;
  letter-spacing: .03em;
}
/* legacy – kept for safety */
.pm-my-card-desc { font-size: .83rem; color: #e2e8f0; line-height: 1.5; margin-bottom: 8px; word-break: break-word; white-space: pre-wrap; }
.pm-my-card-meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: .74rem; color: #64748b; margin-bottom: 7px; }
.pm-my-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 4px; }

/* ═══════════════════════════════════════════════════════════════════════════
   SHARED SMALL ELEMENTS
   ═══════════════════════════════════════════════════════════════════════════ */

.pm-oficina-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
  vertical-align: middle;
}
.pm-estado-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 3px;
  vertical-align: middle;
}

/* Icon buttons */
.pm-icon-btn {
  background: none;
  border: 1px solid transparent;
  border-radius: 5px;
  color: #475569;
  padding: 3px 5px;
  cursor: pointer;
  font-size: .8rem;
  line-height: 1;
  transition: color .1s, background .1s, border-color .1s;
}
.pm-icon-btn:hover {
  background: rgba(255,255,255,.07);
  border-color: rgba(148,163,184,.2);
  color: #e2e8f0;
}
.pm-icon-btn--danger:hover  { color: #f87171; border-color: rgba(248,113,113,.3); background: rgba(248,113,113,.08); }
.pm-icon-btn--warning:hover { color: #fbbf24; border-color: rgba(251,191,36,.3);  background: rgba(251,191,36,.08);  }
.pm-icon-btn--success:hover { color: #4ade80; border-color: rgba(74,222,128,.3);  background: rgba(74,222,128,.08);  }
.pm-icon-btn--info:hover    { color: #38bdf8; border-color: rgba(56,189,248,.3);  background: rgba(56,189,248,.08);  }
.pm-icon-btn--sm { padding: 1px 4px; font-size: .72rem; }

/* ═══════════════════════════════════════════════════════════════════════════
   PM-UPICK header pills — dot indicator
   ═══════════════════════════════════════════════════════════════════════════ */

.pm-upick-dot {
  width: .55rem;
  height: .55rem;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════════════
   MODAL pmIncModal — form controls dark (fv2-create-modal context)
   ═══════════════════════════════════════════════════════════════════════════ */

#pmIncModal .form-control,
#pmIncModal .form-select {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.12);
  color: #f1f5f9;
}
#pmIncModal .form-control:focus,
#pmIncModal .form-select:focus {
  background: rgba(255,255,255,.09);
  border-color: rgba(96,165,250,.5);
  box-shadow: 0 0 0 3px rgba(59,130,246,.15);
  color: #f1f5f9;
}
#pmIncModal .form-control::placeholder { color: rgba(148,163,184,.38); }
#pmIncModal .form-select option { background: #1e293b; color: #f1f5f9; }
#pmIncModal .form-label { font-size: .8rem; color: rgba(203,213,225,.78); font-weight: 500; }
#pmIncModal textarea.form-control { resize: vertical; min-height: 80px; }

/* ═══════════════════════════════════════════════════════════════════════════
   OFICINA UPICK — opciones, edición inline y footer de creación
   ═══════════════════════════════════════════════════════════════════════════ */

/* Opción normal */
.pm-ofi-opt {
  display: flex;
  align-items: center;
  gap: .38rem;
  padding: .36rem .65rem;
  cursor: pointer;
  font-size: .83rem;
  color: rgba(203,213,225,.78);
  transition: background .1s;
  position: relative;
}
.pm-ofi-opt:hover { background: rgba(255,255,255,.07); color: #e2e8f0; }
.pm-ofi-opt.is-selected { background: rgba(59,130,246,.12); color: #93c5fd; font-weight: 600; }

.pm-ofi-opt-left {
  display: flex;
  align-items: center;
  gap: .35rem;
  flex: 1;
  min-width: 0;
}
.pm-ofi-opt-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}
.pm-ofi-opt-check {
  font-size: .78rem;
  color: #4ade80;
  flex-shrink: 0;
}

/* Botones editar/eliminar — aparecen al hacer hover */
.pm-ofi-opt-actions {
  display: none;
  gap: 1px;
  flex-shrink: 0;
}
.pm-ofi-opt:hover .pm-ofi-opt-actions { display: flex; }
.pm-ofi-opt.is-selected:hover .pm-ofi-opt-actions { display: flex; }

/* Fila de edición inline */
.pm-ofi-opt-edit-row {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: .3rem .65rem;
  background: rgba(255,255,255,.04);
  border-top: 1px solid rgba(148,163,184,.08);
  border-bottom: 1px solid rgba(148,163,184,.08);
}
.pm-ofi-opt-edit-row .form-control { font-size: .8rem; flex: 1; min-width: 0; }
#pmIncModal .pm-ofi-opt-edit-row .form-control {
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.15);
  color: #f1f5f9;
}

/* Mensaje empty en lista */
.pm-ofi-empty {
  padding: .5rem .65rem;
  font-size: .78rem;
  color: #475569;
  text-align: center;
}

/* Footer de creación (dentro del panel, solo admin) */
.pm-ofi-upick-footer {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: .45rem .65rem;
  border-top: 1px solid rgba(148,163,184,.1);
  background: rgba(255,255,255,.02);
}
.pm-ofi-upick-footer .pm-ofi-add-nombre {
  flex: 1;
  min-width: 0;
  font-size: .8rem;
}
#pmIncModal .pm-ofi-upick-footer .pm-ofi-add-nombre {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.12);
  color: #f1f5f9;
}
#pmIncModal .pm-ofi-upick-footer .pm-ofi-add-nombre::placeholder { color: rgba(148,163,184,.38); }

/* Color picker input */
.pm-color-input {
  width: 26px;
  height: 26px;
  border: none;
  border-radius: 5px;
  padding: 0;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════════════
   AUDIT MODAL
   ═══════════════════════════════════════════════════════════════════════════ */

.pm-aud-inc-ref {
  display: inline-block;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: .74rem;
  color: #475569;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(148,163,184,.1);
  border-radius: .22rem;
  padding: .05rem .35rem;
  margin-left: 6px;
  vertical-align: middle;
  cursor: default;
}

.pm-aud-entry {
  border-bottom: 1px solid rgba(148,163,184,.08);
  padding: 10px 0;
}
.pm-aud-entry:last-child { border-bottom: none; }
.pm-aud-entry-head {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: .82rem;
  flex-wrap: wrap;
}
.pm-aud-diff {
  margin-top: 6px;
  padding-left: 10px;
  border-left: 2px solid rgba(148,163,184,.12);
}
.pm-aud-diff-line {
  display: flex;
  align-items: baseline;
  gap: 4px;
  font-size: .75rem;
  padding: 1px 0;
  flex-wrap: wrap;
}
.pm-aud-diff-key  { color: #475569; min-width: 80px; font-weight: 500; }
.pm-aud-diff-old  { color: #f87171; text-decoration: line-through; }
.pm-aud-diff-new  { color: #4ade80; }

/* ═══════════════════════════════════════════════════════════════════════════
   MODAL EXPORT — form controls
   ═══════════════════════════════════════════════════════════════════════════ */

#pmExportModal .form-control {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.12);
  color: #f1f5f9;
}
#pmExportModal .form-control:focus {
  background: rgba(255,255,255,.09);
  border-color: rgba(96,165,250,.5);
  box-shadow: 0 0 0 3px rgba(59,130,246,.15);
  color: #f1f5f9;
}
#pmExportModal .form-control::placeholder { color: rgba(148,163,184,.38); }
#pmExportModal .form-check-label { color: #cbd5e1; font-size: .82rem; }
#pmExportModal .form-check-input { accent-color: #6366f1; }

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 767.98px) {
  .pm-adm-sidebar   { display: none; }
  .pm-kpi-strip     { gap: 4px; font-size: .7rem; }
  .pm-hdr-upick-row { font-size: .72rem; padding: .15rem .4rem; }
  .pm-desc-text     { max-width: 180px; }
}
