/* CRM 6.0.19 – Klienci / Archiwum: pełny pasek nagłówka i jeden rząd akcji. */
@media (min-width:701px) {
  body[data-crm-view="customers"] #content .customer-list-card .tablewrap {
    width:100%!important;max-width:100%!important;min-width:0!important;
    scrollbar-gutter:auto!important; /* poprzednio stable rezerwował ok. 15 px po prawej */
    overflow-x:auto!important;
    box-sizing:border-box!important;
    background:#fff;
  }
  body[data-crm-view="customers"] #content .customer-list-card .tablewrap>.table {
    width:100%!important;min-width:800px!important;table-layout:fixed!important;
  }
  body[data-crm-view="customers"] #content .customer-list-card .table thead,
  body[data-crm-view="customers"] #content .customer-list-card .table thead tr,
  body[data-crm-view="customers"] #content .customer-list-card .table thead th {
    background:#f8fafc!important;
  }
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table th:nth-child(1),
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table td:nth-child(1){width:23%!important}
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table th:nth-child(2),
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table td:nth-child(2){width:25%!important}
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table th:nth-child(3),
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table td:nth-child(3){width:13%!important}
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table th:nth-child(4),
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table td:nth-child(4){width:14%!important}
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table th:nth-child(5),
  body[data-crm-view="customers"] #content .customer-list-card.archive-mode .table td:nth-child(5){width:25%!important}
}
/* Zawsze JEDNA LINIA – nie zmieniamy szerokości po kliknięciu menu. */
body[data-crm-view="customers"] .customer-list-card.archive-mode .archive-actions.crm-archive-actions-inline {
  display:flex!important;flex-direction:row!important;flex-wrap:nowrap!important;
  align-items:center!important;justify-content:flex-end!important;
  width:100%!important;min-width:0!important;gap:6px!important;
}
body[data-crm-view="customers"] .customer-list-card.archive-mode .crm-archive-actions-inline .btn{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;
  flex:0 0 auto!important;width:auto!important;min-width:0!important;
  min-height:38px!important;height:38px!important;padding:7px 10px!important;
  margin:0!important;white-space:nowrap!important;gap:6px!important;
}
body[data-crm-view="customers"] .customer-list-card.archive-mode .crm-archive-actions-inline svg{flex:0 0 auto}
@media (min-width:701px) and (max-width:1280px) {
  body[data-crm-view="customers"] .customer-list-card.archive-mode .crm-archive-actions-inline .crm-archive-inline-btn{
    width:38px!important;max-width:38px!important;padding:8px!important;
  }
  body[data-crm-view="customers"] .customer-list-card.archive-mode .crm-archive-actions-inline .crm-archive-inline-btn>span{display:none!important}
}
@media (max-width:700px) {
  body[data-crm-view="customers"] .customer-list-card.archive-mode .archive-actions.crm-archive-actions-inline{
    display:flex!important;grid-template-columns:none!important;flex-wrap:nowrap!important;justify-content:flex-end!important;
  }
  body[data-crm-view="customers"] .customer-list-card.archive-mode .crm-archive-actions-inline .btn{
    width:auto!important;min-width:0!important;padding:7px 9px!important;
  }
  body[data-crm-view="customers"] .customer-list-card.archive-mode .crm-archive-actions-inline .crm-archive-inline-btn>span{display:none!important}
}
.crm-archive-floating-menu{
  position:fixed;z-index:2147483200;box-sizing:border-box;width:245px;max-width:calc(100vw - 16px);
  padding:7px;background:#fff;border:1px solid #dfe6ef;border-radius:14px;
  box-shadow:0 16px 44px rgba(18,32,51,.19);display:grid;gap:3px;
}
.crm-archive-floating-menu[hidden]{display:none!important}
.crm-archive-floating-menu button{
  border:0;border-radius:9px;background:transparent;color:#17263e;text-align:left;
  cursor:pointer;font-weight:650;font:inherit;min-height:39px;padding:8px 10px;
}
.crm-archive-floating-menu button:hover,.crm-archive-floating-menu button:focus-visible{background:#f2f5f9}
.crm-archive-floating-menu .crm-archive-danger{color:#bd2525}
.crm-archive-floating-menu .crm-archive-danger:hover{background:#fff1f1}
.crm-archive-floating-menu .crm-archive-divider{border-top:1px solid #e7ebf1;margin:3px 0}
.crm-archive-history-summary{display:flex;align-items:start;gap:7px;margin:8px 0 12px;padding:10px 12px;border:1px solid #dfe6ef;background:#f8fafc;border-radius:10px;font-size:12px}
.crm-archive-history-summary strong{font-weight:800}
.crm-archive-history-summary .crm-archive-history-unknown{color:#6a7789}
