.attendance-toolbar {
  display: flex;
  align-items: flex-end;
  gap: 10px;
}

.attendance-employee {
  flex: 1 1 auto;
  max-width: 560px;
}

.attendance-side {
  display: grid;
  gap: 7px;
  flex: 0 0 300px;
}

.attendance-toolbar .danger {
  white-space: nowrap;
  width: 100%;
}

.attendance-summary {
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-left: 7px solid var(--green);
  border-radius: 12px;
  background: #f8fbff;
}

.attendance-summary-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.attendance-decision {
  font-size: 18px;
  font-weight: 900;
  text-align: right;
  white-space: nowrap;
}

.attendance-forward {
  margin-top: 8px;
  width: 100%;
}

.attendance-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 10px 0 6px;
  align-items: center;
}

.attendance-facts span:not(.badge) {
  background: #edf3f8;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  padding: 4px 8px;
}

.active-report-kpi {
  outline: 3px solid rgba(21, 88, 176, .2);
  border-color: var(--theme);
}

.report-links {
  display: grid;
  gap: 10px;
}

.report-links button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  text-align: left;
}

@media (max-width: 720px) {
  .attendance-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .attendance-employee {
    max-width: none;
  }

  .attendance-side {
    flex-basis: auto;
  }

  .attendance-summary-main {
    flex-direction: column;
  }

  .attendance-decision {
    text-align: left;
    white-space: normal;
  }

  .attendance-forward {
    width: auto;
  }
}

/* Parade Control module */
.parade-shell .card-h {
  align-items: flex-start;
}
.parade-shell .dt td:last-child {
  min-width: 230px;
  white-space: nowrap;
}
.parade-shell .dt td:nth-child(1) {
  min-width: 170px;
}
.parade-shell .dt td:nth-child(4) {
  min-width: 170px;
}
.parade-shell .primary[disabled],
.parade-shell .outline[disabled] {
  opacity: .45;
  cursor: not-allowed;
}
.parade-shell .btn-sm {
  margin: 2px;
}
@media (max-width: 820px) {
  .parade-shell .form-grid {
    grid-template-columns: 1fr !important;
  }
  .parade-shell .dt td:last-child {
    min-width: 180px;
  }
}

/* Compact Parade Control grid: action and comments are separated for quicker control-room use */
.parade-compact .table-wrap {
  max-height: 660px;
}
.parade-compact .dt {
  font-size: 11px;
}
.parade-compact .dt th,
.parade-compact .dt td {
  padding: 7px 8px;
}
.parade-compact .dt td:nth-child(6) {
  min-width: 148px;
  white-space: nowrap;
}
.parade-compact .dt td:nth-child(7) {
  min-width: 260px;
  white-space: normal;
}
.parade-comment {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}
.parade-compact .btn-sm {
  padding: 5px 8px;
  margin: 1px;
}

/* Reporting cards: organized downloads instead of clickable titles */
.report-section-grid {
  display: grid;
  gap: 14px;
}
.report-card-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.compact-report-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.report-card {
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, .06);
  display: flex;
  flex-direction: column;
  min-height: 172px;
  padding: 16px;
}
.report-card.pdf { border-left: 4px solid #1558B0; }
.report-card.excel { border-left: 4px solid #147A4A; }
.report-card.csv { border-left: 4px solid #64748B; min-height: 148px; }
.report-card-top,
.report-card-footer {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: space-between;
}
.report-type-pill {
  background: #edf4ff;
  border: 1px solid #cfe1ff;
  border-radius: 999px;
  color: #1558B0;
  font-size: 11px;
  font-weight: 900;
  padding: 4px 9px;
  text-transform: uppercase;
  letter-spacing: .03em;
}
.report-card h3 {
  color: var(--ink);
  font-size: 16px;
  line-height: 1.25;
  margin: 14px 0 8px;
}
.report-card p {
  color: var(--muted);
  flex: 1;
  font-size: 13px;
  line-height: 1.45;
  margin: 0 0 14px;
}
.report-file {
  color: #64748B;
  font-size: 11px;
  font-weight: 800;
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
@media (max-width: 720px) {
  .report-card-grid { grid-template-columns: 1fr; }
  .report-card-footer { align-items: stretch; flex-direction: column; }
  .report-file { max-width: none; }
}

/* Compact Parade + Personnel filters */
.parade-filter-grid,
.personnel-filter-grid {
  display: grid;
  gap: 8px;
  align-items: end;
}
.parade-filter-grid {
  grid-template-columns: minmax(170px, 1.4fr) repeat(4, minmax(115px, .95fr)) minmax(150px, 1.25fr) minmax(120px, .8fr);
}
.personnel-filter-grid {
  grid-template-columns: minmax(190px, 1.6fr) repeat(6, minmax(115px, 1fr));
}
.parade-filter-grid label,
.personnel-filter-grid label {
  min-width: 0;
  font-size: 11px;
  color: var(--muted);
  font-weight: 800;
}
.parade-filter-grid select,
.parade-filter-grid input,
.personnel-filter-grid select,
.personnel-filter-grid input {
  padding: 7px 8px;
  font-size: 12px;
  min-height: 36px;
}
@media (max-width: 1280px) {
  .parade-filter-grid,
  .personnel-filter-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .parade-filter-grid,
  .personnel-filter-grid { grid-template-columns: 1fr; }
}
