.task-control-filters{display:grid;grid-template-columns:220px auto;justify-content:end;align-items:stretch;width:100%;max-width:1200px;box-sizing:border-box;gap:10px}
.task-control-filters #task-control-date{box-sizing:border-box;width:100%;height:44px;margin:0;padding:0 13px;border:1px solid #cfdad4;border-radius:8px;background:#fff;color:var(--ink)}
.task-control-filters #task-control-date{min-width:0}
.task-control-filters #task-control-filter-button{width:auto;min-width:110px;height:44px;margin:0;padding:0 18px}
.task-control-workspace{box-sizing:border-box;width:100%}
.task-control-table{min-width:760px;table-layout:fixed}
.task-control-table th:nth-child(1){width:40%}.task-control-table th:nth-child(2){width:18%}.task-control-table th:nth-child(3){width:18%}.task-control-table th:nth-child(4){width:13%}.task-control-table th:nth-child(5){width:11%}
.task-control-table td:first-child{min-width:0}
.task-stat-label{max-width:1200px;margin:10px 0 7px;color:var(--muted);font-size:9px;font-weight:900;letter-spacing:.08em}
.task-control-status-stats{grid-template-columns:repeat(4,minmax(140px,1fr))}
.task-control-alert-stats{grid-template-columns:repeat(5,minmax(130px,1fr))}
.task-control-filters input{min-width:150px;padding:11px 12px;border:1px solid var(--line);border-radius:7px;background:white;color:var(--ink)}
.task-control-filters input[type="search"]{flex:1;min-width:220px}
.task-workload-card{max-width:1200px;margin-top:18px;padding:18px;background:white;border:1px solid var(--line);border-radius:11px}
.task-workload-card h4{margin:0 0 4px}
.task-workload-card>p{margin:0 0 14px;color:var(--muted);font-size:11px}
.task-workload-grid{display:grid;grid-template-columns:repeat(3,minmax(180px,1fr));gap:10px}
.task-workload-item{display:flex;flex-direction:column;align-items:stretch;gap:7px;padding:14px;border:1px solid var(--line);border-radius:8px;background:#f8fbf9;color:var(--ink);cursor:pointer;text-align:left}
.task-workload-item.requires-attention{border-left:3px solid #d89b2b}
.task-workload-item:hover{border-color:#9fcbb8;background:#f2faf6}
.task-workload-header{display:flex;align-items:center;justify-content:space-between;gap:10px}.task-workload-header>span{padding:4px 7px;border-radius:12px;background:var(--mint);white-space:nowrap}
.task-workload-item span{font-size:12px;font-weight:800}
.task-workload-item small{color:var(--muted);line-height:1.4}
.task-workload-alerts{color:#8a4b00!important}
.task-workload-performance{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;padding-top:7px;border-top:1px solid var(--line)}.task-workload-performance>span{display:flex;flex-direction:column;gap:3px}.task-workload-performance small{font-size:8px}.task-workload-performance b{font-size:10px}
.task-risks-card{max-width:1200px;margin-top:18px;padding:18px;background:white;border:1px solid var(--line);border-radius:11px}.task-risks-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:13px}.task-risks-heading h4{margin:0 0 4px}.task-risks-heading p{margin:0;color:var(--muted);font-size:11px}.task-risks-heading>strong{padding:5px 8px;border-radius:14px;background:#fff1dc;color:#7a4400;font-size:9px;white-space:nowrap}.task-risks-list{display:grid;gap:8px}.task-risk-item{display:grid;grid-template-columns:74px 1fr;gap:11px;align-items:start;width:100%;padding:12px;border:1px solid var(--line);border-radius:8px;background:#fff;text-align:left;color:var(--ink);cursor:pointer}.task-risk-item:hover{background:#fbfcfb}.task-risk-item.critical{border-left:3px solid #c83f3f}.task-risk-item.warning{border-left:3px solid #d89b2b}.task-risk-item.workload{border-left:3px solid #4879b8}.task-risk-marker{display:inline-block;padding:4px 6px;border-radius:10px;background:#f0f3f2;color:var(--muted);font-size:8px;font-weight:900;text-align:center;text-transform:uppercase}.task-risk-item.critical .task-risk-marker{background:#fff0f0;color:#a02e2e}.task-risk-item.warning .task-risk-marker{background:#fff1dc;color:#7a4400}.task-risk-item.workload .task-risk-marker{background:#edf4ff;color:#285b99}.task-risk-item strong{display:block;font-size:11px}.task-risk-item p{margin:4px 0;font-size:10px}.task-risk-item small{display:block;color:var(--muted);font-size:9px;line-height:1.4}.task-risk-rules{margin-top:12px;padding-top:10px;border-top:1px solid var(--line);font-size:9px;color:var(--muted)}.task-risk-rules summary{cursor:pointer;font-weight:800;color:var(--ink)}.task-risk-rules p{line-height:1.5}
.task-trends-card{max-width:1200px;margin-top:18px;padding:18px;background:white;border:1px solid var(--line);border-radius:11px}.task-trends-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:14px}.task-trends-heading h4{margin:0 0 4px}.task-trends-heading p{margin:0;color:var(--muted);font-size:11px}.task-trends-heading>strong{padding:6px 9px;border-radius:14px;font-size:10px;white-space:nowrap}.task-trends-heading>strong.positive{background:#e5f7ef;color:#08754a}.task-trends-heading>strong.negative{background:#fff0f0;color:#a02e2e}.task-trends-heading>strong.neutral{background:#eef2f0;color:var(--muted)}.task-trends-grid{display:grid;grid-template-columns:repeat(3,minmax(170px,1fr));gap:9px}.task-trend-item{display:flex;flex-direction:column;gap:5px;padding:13px;border:1px solid var(--line);border-radius:8px;background:#fbfcfb}.task-trend-item>span{font-size:9px;color:var(--muted)}.task-trend-item>strong{font-size:18px}.task-trend-item>small{font-size:9px;color:var(--muted)}.task-trend-item>small.improved{color:#08754a}.task-trend-item>small.worsened{color:#a02e2e}.task-trends-note{margin:12px 0 0;color:var(--muted);font-size:9px}
.task-report-card{max-width:1200px;margin-top:18px;padding:18px;background:white;border:1px solid var(--line);border-radius:11px}.task-report-heading h4{margin:0 0 4px}.task-report-heading p{margin:0;color:var(--muted);font-size:11px}.task-report-filters{display:grid;grid-template-columns:160px 160px minmax(210px,1fr) auto;gap:9px;align-items:end;margin:15px 0}.task-report-filters label{display:flex;flex-direction:column;gap:6px;font-size:9px;color:var(--muted)}.task-report-filters input,.task-report-filters select{width:100%;padding:10px;border:1px solid var(--line);border-radius:7px;background:white;color:var(--ink)}.task-report-filters button{height:38px}.task-report-period{margin:0 0 10px;color:var(--muted);font-size:9px}.task-report-summary{display:grid;grid-template-columns:repeat(4,minmax(130px,1fr));gap:8px;margin-bottom:15px}.task-report-summary article{padding:11px;border:1px solid var(--line);border-radius:8px;background:#fbfcfb}.task-report-summary span{display:block;color:var(--muted);font-size:8px}.task-report-summary strong{display:block;margin-top:5px;font-size:16px}.task-report-table-wrap{overflow:auto}.task-report-table{width:100%;border-collapse:collapse}.task-report-table th,.task-report-table td{padding:10px 9px;border-bottom:1px solid var(--line);text-align:left;white-space:nowrap}.task-report-table th{font-size:8px;color:var(--muted);text-transform:uppercase;letter-spacing:.05em}.task-report-table td{font-size:9px}
@media(max-width:850px){.task-control-filters{grid-template-columns:1fr}.task-control-filters #task-control-filter-button{width:100%}.task-workload-grid,.task-trends-grid,.task-report-summary{grid-template-columns:1fr}.task-trends-heading,.task-risks-heading{flex-direction:column}.task-risk-item{grid-template-columns:1fr}.task-report-filters{grid-template-columns:1fr}}

/* Polished manager trends and report */
.task-trends-card,.task-report-card{
  box-sizing:border-box;
  width:100%;
  max-width:1200px;
  margin-top:20px;
  padding:22px;
  border:1px solid #d9e2dd;
  border-radius:14px;
  background:#fff;
  box-shadow:0 8px 24px rgba(18,48,37,.045);
}
.task-trends-heading,.task-report-heading{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:20px;
  padding-bottom:16px;
  border-bottom:1px solid #e7ece9;
}
.task-trends-heading h4,.task-report-heading h4{margin:0 0 6px;font-size:17px;line-height:1.2}
.task-trends-heading p,.task-report-heading p{margin:0;color:var(--muted);font-size:11px;line-height:1.5}
.task-trends-heading>strong{
  display:inline-flex;align-items:center;min-height:30px;padding:6px 11px;border-radius:999px;
  font-size:9px;font-weight:900;letter-spacing:.04em;text-transform:uppercase;
}
.task-trends-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
  margin-top:16px;
}
.task-trend-item{
  display:grid;
  grid-template-columns:1fr auto;
  gap:7px 12px;
  min-width:0;
  padding:16px;
  border:1px solid #e0e7e3;
  border-radius:10px;
  background:linear-gradient(145deg,#fbfdfc,#f5f9f7);
}
.task-trend-item>span{grid-column:1/-1;color:#617069;font-size:9px;font-weight:800;text-transform:uppercase;letter-spacing:.07em}
.task-trend-item>strong{font-size:21px;line-height:1.15;color:#102d23}
.task-trend-item>small{align-self:end;text-align:right;font-size:9px;line-height:1.35;color:var(--muted)}
.task-trends-note{margin:15px 0 0;padding:11px 13px;border-radius:8px;background:#f3f7f5;color:#56655e;font-size:10px;line-height:1.5}
.task-report-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px}
.task-report-actions button{width:auto;min-width:112px;margin:0;padding:10px 14px}
.task-report-filters{
  display:grid;
  grid-template-columns:minmax(150px,.8fr) minmax(150px,.8fr) minmax(230px,1.5fr) auto;
  gap:12px;
  align-items:end;
  margin:18px 0 16px;
  padding:16px;
  border:1px solid #e0e7e3;
  border-radius:10px;
  background:#f7faf8;
}
.task-report-filters label{display:grid;gap:7px;margin:0;color:#526159;font-size:9px;font-weight:800;text-transform:uppercase;letter-spacing:.06em}
.task-report-filters input,.task-report-filters select{
  box-sizing:border-box;width:100%;height:42px;margin:0;padding:0 12px;border:1px solid #cfdad4;
  border-radius:8px;background:#fff;color:#102d23;font:600 11px/1.2 inherit;
}
.task-report-filters button{width:auto;min-width:112px;height:42px;margin:0;padding:0 17px}
.task-report-period{margin:0 0 12px;padding:9px 12px;border-left:3px solid #16a66a;border-radius:0 7px 7px 0;background:#eef8f3;color:#355348;font-size:10px}
.task-report-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:0 0 18px}
.task-report-summary article{min-width:0;padding:14px;border:1px solid #dfe7e2;border-radius:10px;background:#fff}
.task-report-summary span{display:block;color:#627069;font-size:8px;font-weight:800;text-transform:uppercase;letter-spacing:.07em}
.task-report-summary strong{display:block;margin-top:7px;color:#102d23;font-size:19px;line-height:1.2}
.task-report-table-wrap{overflow:auto;border:1px solid #dfe7e2;border-radius:10px}
.task-report-table{width:100%;min-width:780px;border-collapse:separate;border-spacing:0;background:#fff}
.task-report-table th,.task-report-table td{padding:12px 11px;border:0;border-bottom:1px solid #e7ece9;text-align:left;white-space:nowrap}
.task-report-table th{position:sticky;top:0;background:#f2f7f4;color:#526159;font-size:8px;font-weight:900;text-transform:uppercase;letter-spacing:.055em}
.task-report-table td{color:#233e34;font-size:10px}
.task-report-table tbody tr:last-child td{border-bottom:0}
.task-report-table tbody tr:hover td{background:#f7fbf9}
.task-report-table td:first-child{font-weight:800;color:#102d23}
.task-report-card .empty-state{margin:16px 0 0;padding:24px;border:1px dashed #cfdad4;border-radius:9px;background:#fafcfb;text-align:center}
@media(max-width:900px){
  .task-trends-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .task-report-summary{grid-template-columns:repeat(2,minmax(0,1fr))}
  .task-report-filters{grid-template-columns:1fr 1fr}
  .task-report-filters label:nth-child(3){grid-column:1/-1}
}
@media(max-width:600px){
  .task-trends-card,.task-report-card{padding:16px;border-radius:11px}
  .task-trends-heading,.task-report-heading{flex-direction:column}
  .task-report-actions{width:100%;justify-content:flex-start}
  .task-report-actions button{flex:1}
  .task-trends-grid,.task-report-summary,.task-report-filters{grid-template-columns:1fr}
  .task-report-filters label:nth-child(3){grid-column:auto}
  .task-report-filters button{width:100%}
  .task-trend-item{grid-template-columns:1fr}
  .task-trend-item>small{text-align:left}
}

/* Individual employee card */
#task-control-content.employee-profile-open>:not(.page-heading):not(#task-employee-profile):not(.task-control-workspace){display:none!important}
.task-employee-profile{
  box-sizing:border-box;width:100%;max-width:1200px;margin:0 0 14px;padding:22px;
  border:1px solid #d9e2dd;border-radius:14px;background:#fff;box-shadow:0 8px 24px rgba(18,48,37,.045);
}
.task-employee-profile[hidden]{display:none!important}
.task-employee-profile-heading{display:flex;align-items:center;justify-content:space-between;gap:22px;padding-bottom:18px;border-bottom:1px solid #e7ece9}
.task-employee-back{align-self:flex-start;padding:9px 12px;border:1px solid #cfdad4;border-radius:8px;background:#fff;color:#24463a;font:800 10px/1 inherit;cursor:pointer}
.task-employee-back:hover{border-color:#8fc6ae;background:#f3faf6}
.task-employee-identity{display:flex;align-items:center;gap:13px;min-width:0;margin-left:auto;text-align:right}
.task-employee-avatar{display:grid;place-items:center;width:46px;height:46px;flex:0 0 46px;border-radius:50%;background:#def4e9;color:#008653;font-size:14px;font-weight:900}
.task-employee-identity .eyebrow{margin:0 0 5px;font-size:8px}
.task-employee-identity h4{margin:0;font-size:21px;line-height:1.2}
.task-employee-identity p:last-child{margin:5px 0 0;color:var(--muted);font-size:10px}
.task-employee-metrics{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:9px;margin-top:18px}
.task-employee-metrics article{min-width:0;padding:13px;border:1px solid #dfe7e2;border-radius:9px;background:#f8fbf9}
.task-employee-metrics article.danger{border-color:#f0c7c7;background:#fff7f7}
.task-employee-metrics span{display:block;color:#5b6b64;font-size:8px;font-weight:900;text-transform:uppercase;letter-spacing:.05em}
.task-employee-metrics strong{display:block;margin:7px 0 5px;color:#102d23;font-size:18px;line-height:1.15;overflow-wrap:anywhere}
.task-employee-metrics article.danger strong{color:#aa3434}
.task-employee-metrics small{display:block;color:#738078;font-size:8px;line-height:1.35}
.task-employee-tasks-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-top:20px;padding-top:17px;border-top:1px solid #e7ece9}
.task-employee-tasks-heading h5{margin:0 0 4px;font-size:14px}
.task-employee-tasks-heading p{margin:0;color:var(--muted);font-size:9px}
.task-employee-task-tabs{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:6px}
.task-employee-task-tabs button{padding:8px 10px;border:1px solid #d4ded8;border-radius:999px;background:#fff;color:#52645c;font:800 9px/1 inherit;cursor:pointer}
.task-employee-task-tabs button:hover{border-color:#9fcbb8;background:#f3faf6}
.task-employee-task-tabs button.active{border-color:#14a66a;background:#e4f7ed;color:#08754a}
.employee-profile-open .task-control-workspace{margin-top:0;box-shadow:0 8px 24px rgba(18,48,37,.045)}
.employee-profile-open .task-control-table th:nth-child(2),.employee-profile-open .task-control-table td:nth-child(2){display:none}
.employee-profile-open .task-control-table th:nth-child(1){width:48%}.employee-profile-open .task-control-table th:nth-child(3){width:21%}.employee-profile-open .task-control-table th:nth-child(4){width:17%}.employee-profile-open .task-control-table th:nth-child(5){width:14%}
@media(max-width:1050px){.task-employee-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:700px){
  .task-employee-profile{padding:16px}
  .task-employee-profile-heading,.task-employee-tasks-heading{align-items:flex-start;flex-direction:column}
  .task-employee-identity{margin-left:0;text-align:left}
  .task-employee-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}
  .task-employee-task-tabs{justify-content:flex-start}
}
