﻿/* GED-WEB-4C2 — Rapports Courriers */

.reports-content {
  max-width: 1500px;
  margin: 0 auto;
}

.reports-head,
.reports-filter-card,
.reports-section {
  border: 1px solid #dfe6ef;
  border-radius: 12px;
  background: #fff;
}

.reports-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 14px 16px;
  margin-bottom: 10px;
}

.reports-head h1 {
  margin: 2px 0 3px;
  font-size: 20px;
}

.reports-head p {
  max-width: 760px;
  margin: 0;
  color: #758297;
  font-size: 10px;
}

.reports-head-actions {
  display: flex;
  justify-content: flex-end;
  gap: 5px;
  flex-wrap: wrap;
}

.reports-head-actions .btn,
.reports-head-actions .btn-secondary {
  min-height: 32px;
  padding: 6px 9px;
  font-size: 9px;
}

.reports-filter-card {
  margin-bottom: 10px;
  overflow: hidden;
}

.reports-period {
  display: flex;
  gap: 8px;
  align-items: end;
  padding: 10px 12px 8px;
}

.reports-period label {
  width: 150px;
}

.reports-filter-card label > span {
  display: block;
  margin-bottom: 3px;
  color: #68768a;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.reports-filter-card input,
.reports-filter-card select {
  width: 100%;
  height: 32px;
  border: 1px solid #d2dbe7;
  border-radius: 7px;
  background: #fff;
  padding: 5px 7px;
  color: #34445b;
  font: inherit;
  font-size: 10px;
}

.reports-presets {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.reports-presets button,
.reports-dimension-tabs button {
  border: 1px solid #d9e1eb;
  border-radius: 7px;
  background: #f9fbfd;
  padding: 6px 8px;
  color: #526078;
  font-size: 9px;
  font-weight: 700;
  cursor: pointer;
}

.reports-presets button:hover,
.reports-dimension-tabs button:hover {
  border-color: #aebfd8;
  background: #f3f7fc;
}

.reports-export-filters {
  border-top: 1px solid #edf1f5;
}

.reports-export-filters summary {
  padding: 8px 12px;
  color: #526078;
  font-size: 9px;
  font-weight: 800;
  cursor: pointer;
}

.reports-export-filter-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(7, minmax(100px, .7fr));
  gap: 7px;
  padding: 2px 12px 10px;
}

.reports-export-filter-grid .is-wide {
  min-width: 200px;
}

.reports-form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  align-items: center;
  padding: 8px 12px;
  border-top: 1px solid #edf1f5;
  background: #fbfcfe;
}

.reports-filter-note {
  margin-right: auto;
  color: #8994a5;
  font-size: 8px;
}

.reports-form-actions .btn,
.reports-form-actions .btn-secondary {
  min-height: 30px;
  padding: 5px 9px;
  font-size: 9px;
}

.reports-loading {
  height: 2px;
  margin-bottom: 8px;
  overflow: hidden;
}

.reports-loading.is-visible::before {
  content: "";
  display: block;
  width: 30%;
  height: 100%;
  background: #2b65b1;
  animation: reports-load 1s linear infinite alternate;
}

@keyframes reports-load {
  from { transform: translateX(0); }
  to { transform: translateX(235%); }
}

.reports-section {
  margin-bottom: 10px;
  overflow: hidden;
}

.reports-section-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  min-height: 45px;
  padding: 8px 11px;
  border-bottom: 1px solid #e8edf3;
  background: #fbfcfe;
}

.reports-section-head span {
  display: block;
  color: #7d899b;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.reports-section-head h2 {
  margin: 1px 0 0;
  color: #263850;
  font-size: 12px;
}

.reports-section-head small {
  color: #8b96a7;
  font-size: 8px;
}

.reports-kpis {
  display: grid;
  grid-template-columns: repeat(8, minmax(110px, 1fr));
}

.report-kpi {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 9px 10px;
  border-right: 1px solid #edf1f5;
}

.report-kpi:last-child {
  border-right: 0;
}

.report-kpi span {
  color: #748196;
  font-size: 8px;
}

.report-kpi strong {
  color: #273b56;
  font-size: 18px;
  line-height: 1.1;
}

.report-kpi small {
  color: #98a2b3;
  font-size: 7px;
}

.report-kpi.is-alert strong {
  color: #b42318;
}

.report-kpi.is-good strong {
  color: #16734b;
}

.reports-backlog {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
}

.reports-backlog > div {
  display: grid;
  gap: 2px;
  padding: 8px 9px;
  border-right: 1px solid #edf1f5;
}

.reports-backlog > div:last-child {
  border-right: 0;
}

.reports-backlog span {
  color: #748196;
  font-size: 8px;
}

.reports-backlog strong {
  color: #2c405a;
  font-size: 14px;
}

.reports-backlog .is-danger strong {
  color: #b42318;
}

.reports-performance {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
}

.performance-card {
  padding: 9px 10px;
  border-right: 1px solid #edf1f5;
}

.performance-card > div {
  display: grid;
  gap: 2px;
  margin-bottom: 6px;
}

.performance-card > div span {
  color: #748196;
  font-size: 8px;
}

.performance-card > div strong {
  color: #273b56;
  font-size: 16px;
}

.performance-card dl {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  margin: 0;
}

.performance-card dl div {
  display: grid;
  gap: 1px;
}

.performance-card dt {
  color: #98a2b3;
  font-size: 7px;
}

.performance-card dd {
  margin: 0;
  color: #596a80;
  font-size: 8px;
  font-weight: 700;
}

.reports-dimension-tabs {
  display: flex;
  gap: 3px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.reports-dimension-tabs button {
  padding: 4px 6px;
  font-size: 8px;
}

.reports-dimension-tabs button.is-active {
  border-color: #8fb0dd;
  background: #edf4ff;
  color: #164f9c;
}

.reports-breakdown {
  display: grid;
  gap: 0;
}

.stat-row {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 86px;
  gap: 8px;
  align-items: center;
  min-height: 46px;
  padding: 6px 10px;
  border-bottom: 1px solid #edf1f5;
}

.stat-row:last-child {
  border-bottom: 0;
}

.stat-rank {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 7px;
  background: #f1f4f8;
  color: #6c798d;
  font-size: 8px;
  font-weight: 800;
}

.stat-copy {
  display: grid;
  gap: 4px;
}

.stat-copy > div:first-child {
  display: flex;
  gap: 6px;
  align-items: baseline;
}

.stat-copy strong {
  color: #32465f;
  font-size: 10px;
}

.stat-copy small {
  color: #95a0b0;
  font-size: 7px;
}

.stat-track {
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: #eef2f6;
}

.stat-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #709bd5;
}

.stat-value {
  display: grid;
  gap: 1px;
  text-align: right;
}

.stat-value strong {
  color: #263850;
  font-size: 11px;
}

.stat-value small {
  color: #8591a2;
  font-size: 8px;
}

.reports-result-count {
  color: #294f83;
  font-size: 12px;
}

.reports-table-wrap {
  overflow-x: auto;
}

.reports-table {
  width: 100%;
  min-width: 1000px;
  border-collapse: collapse;
}

.reports-table th {
  padding: 7px 9px;
  border-bottom: 1px solid #dfe6ef;
  background: #fbfcfe;
  color: #68768b;
  font-size: 8px;
  text-align: left;
  text-transform: uppercase;
}

.reports-table td {
  padding: 8px 9px;
  border-bottom: 1px solid #edf1f5;
  color: #465872;
  font-size: 9px;
}

.reports-table td strong {
  color: #263850;
  font-size: 9px;
}

.reports-table td.is-object {
  max-width: 360px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reports-empty {
  padding: 22px;
  color: #8994a5;
  font-size: 10px;
  text-align: center;
}

@media (max-width: 1350px) {
  .reports-kpis {
    grid-template-columns: repeat(4, 1fr);
  }

  .reports-backlog {
    grid-template-columns: repeat(5, 1fr);
  }

  .reports-performance {
    grid-template-columns: repeat(3, 1fr);
  }

  .reports-export-filter-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 820px) {
  .reports-head {
    display: grid;
  }

  .reports-head-actions {
    justify-content: flex-start;
  }

  .reports-period {
    flex-wrap: wrap;
  }

  .reports-export-filter-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .reports-kpis,
  .reports-backlog,
  .reports-performance {
    grid-template-columns: repeat(2, 1fr);
  }

  .reports-section-head {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .reports-dimension-tabs {
    justify-content: flex-start;
  }
}

@media (max-width: 520px) {
  .reports-export-filter-grid,
  .reports-kpis,
  .reports-backlog,
  .reports-performance {
    grid-template-columns: 1fr;
  }

  .reports-period label {
    width: 100%;
  }

  .reports-form-actions {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .reports-filter-note {
    width: 100%;
  }
}
