/* Additions for the trucking screens. Everything else comes from app.css,
   shared with Lakatan Operations so the two systems look like one family. */

.filters { display:flex; flex-wrap:wrap; gap:8px; align-items:flex-end; margin-bottom:12px; }
.filters label { margin:0; }
.filters label > span { font-size:11px; color:var(--muted); }
.filters input, .filters select { width:auto; min-width:120px; padding:7px 9px; }
.filters input[type=search] { min-width:220px; }
.filters .grow { flex:1; }

.stats { display:flex; flex-wrap:wrap; gap:18px; font-size:12.5px; color:var(--muted); margin:2px 0 10px; }
.stats b { color:var(--ink); }

td.act { white-space:nowrap; text-align:right; }
td.act .link { font-size:12px; }
tr.idle td { color:#8a8f8a; }
tr.flag td:first-child { box-shadow:inset 3px 0 0 var(--amber); }

/* Matrices (KPI, km/L, sales): many numeric columns, a sticky label column. */
.matrix th:first-child, .matrix td:first-child { position:sticky; left:0; background:#fff; z-index:1; }
.matrix thead th:first-child { background:var(--green-pale); z-index:3; }
.matrix td.good { color:#1b6b3a; font-weight:600; }
.matrix td.bad { color:#b3261e; font-weight:600; }
.matrix td.dim { color:#c4c8c4; }
.matrix tr.total td { border-top:2px solid var(--line); font-weight:700; background:#fafbfa; }
.matrix tr.sec td { background:#f4f6f4; font-size:11px; font-weight:700; text-transform:uppercase; letter-spacing:.06em; color:#666; }
.matrix td.std { color:var(--muted); }

.badge { display:inline-block; font-size:10px; font-weight:700; padding:1px 6px; border-radius:4px; background:#eef1ee; color:#555; margin-left:4px; }
.badge-warn { background:#fff3cd; color:#8a6d1f; }
.badge-red { background:#fee2e2; color:#991b1b; }

.grid-3 { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; }
.frow3 { display:grid; grid-template-columns:1fr 1fr 1fr; gap:12px; }
.computed-line { background:#f4f6f4; border-radius:8px; padding:10px 12px; font-size:13px; display:flex; gap:20px; flex-wrap:wrap; }
.computed-line b { color:var(--green); }

/* Record-a-day grid */
.day-grid { width:100%; border-collapse:collapse; font-size:12.5px; }
.day-grid th { text-align:left; font-size:11px; color:var(--muted); padding:4px 4px; font-weight:600; }
.day-grid td { padding:3px 4px; border-top:1px solid var(--line); }
.day-grid input, .day-grid select { padding:5px 6px; font-size:12px; }
.day-grid td.unit { white-space:nowrap; font-weight:600; }
.day-grid td.amt { text-align:right; white-space:nowrap; font-variant-numeric:tabular-nums; }

.calc { display:grid; grid-template-columns:minmax(300px, 1fr) minmax(260px, 360px); gap:20px; align-items:start; }
.calc-out { background:var(--green-pale); border-radius:var(--radius); padding:18px 20px; }
.calc-out .big { font-size:1.9rem; font-weight:700; color:var(--green); line-height:1.1; }
.calc-out .lbl { font-size:12px; color:#456; margin-bottom:12px; }

.dq h4 { font-size:13px; margin:0 0 6px; color:#444; }
.dq p.lead { font-size:12.5px; color:var(--muted); margin:0 0 10px; }

@media (max-width:860px) {
  .calc { grid-template-columns:1fr; }
  .frow3, .grid-3 { grid-template-columns:1fr; }
}
