.tem-toolbar{display:flex;gap:8px;margin:12px 0;align-items:center}.tem-search{font-size:18px;padding:8px;min-width:360px}.tem-dashboard{display:grid;grid-template-columns:repeat(4,minmax(120px,1fr)) minmax(240px,1.8fr);gap:12px;margin:14px 0}.tem-stat,.tem-progress-card{background:#fff;border:1px solid #dcdcde;border-radius:10px;padding:12px;box-shadow:0 1px 2px #0001}.tem-stat span{display:block;color:#646970;font-size:12px;text-transform:uppercase;letter-spacing:.03em}.tem-stat strong{display:block;font-size:30px;line-height:1.1}.tem-progress-card strong{font-size:30px}.tem-progress{height:18px;background:#f0f0f1;border-radius:999px;overflow:hidden;margin-top:8px}.tem-progress span{display:block;height:100%;background:#1f9d45;border-radius:999px}.tem-bulkbar{display:flex;gap:8px;align-items:center;background:#f6f7f7;border:1px solid #dcdcde;padding:10px;border-radius:8px;margin:10px 0}.tem-bulk-group{min-width:140px}.tem-selected-count{color:#646970}.tem-table{width:100%;border-collapse:collapse;font-size:14px}.tem-table th,.tem-table td{padding:7px;border-bottom:1px solid #ddd;text-align:left}.tem-table th{background:#111;color:#fff;position:sticky;top:0}.tem-toggle{border:0;background:transparent;font-size:18px;cursor:pointer}.tem-new{background:#fff}.tem-checked{background:#fff6bf}.tem-ready{background:#d7ffd9}.tem-finished{background:#d9ecff}.tem-car{max-width:130px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.tem-owe{background:#c60000;color:#fff;border-radius:12px;padding:3px 7px;font-weight:bold}.tem-modal{position:fixed;inset:0;background:rgba(0,0,0,.45);z-index:99999;display:flex;align-items:flex-start;justify-content:flex-end}.tem-card{background:#fff;width:min(560px,96vw);min-height:100vh;padding:18px;box-shadow:0 0 20px #0006;overflow:auto}.tem-card label{display:block;font-weight:700;margin-top:8px}.tem-card input,.tem-card select,.tem-card textarea{width:100%;box-sizing:border-box;padding:8px}.tem-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.tem-actions{position:sticky;top:0;background:#fff;padding:8px 0;border-bottom:1px solid #ddd}.tem-events .button{font-size:18px;margin:5px 0}@media(max-width:1100px){.tem-dashboard{grid-template-columns:repeat(2,1fr)}.tem-table{font-size:12px}.tem-table th,.tem-table td{padding:4px}.tem-search{min-width:0;width:100%}.tem-toolbar,.tem-bulkbar{flex-wrap:wrap}.tem-grid{grid-template-columns:1fr}}

.tem-danger{border-color:#c60000!important;background:#fff1f1!important}.tem-danger strong{color:#c60000}.tem-outstanding-screen .tem-table th:nth-child(2),.tem-outstanding-screen .tem-table td:nth-child(2){font-size:18px;text-align:center}.tem-timer-counts{grid-template-columns:repeat(auto-fit,minmax(140px,1fr))}

.tem-timer-input{width:70px;max-width:70px;text-align:center;font-weight:700;padding:3px 4px;} .tem-static-icon{display:inline-block;min-width:28px;text-align:center;font-size:18px;}

.tem-log-table .tem-log-unsent{background:#fff7e6;}
.tem-log-table .tem-log-sent{background:#f3f4f6;color:#666;}
.tem-field-badge{display:inline-block;background:#111827;color:#fff;border-radius:999px;padding:3px 8px;font-weight:700;font-size:12px;}
.tem-log-unsent .tem-field-badge{background:#d97706;}

.tem-duplicate-number{outline:3px solid #dc3545!important;}
.tem-dupe-badge{display:inline-block;margin-top:3px;padding:2px 6px;border-radius:999px;background:#dc3545;color:white;font-weight:700;font-size:11px;}

.tem-westhold{font-weight:700;color:#1d4ed8;white-space:nowrap;}

.tem-driver-scroll{max-height:70vh;overflow:auto;border:1px solid #dcdcde;background:#fff;}
.tem-driver-scroll .tem-table th{position:sticky;top:0;z-index:2;}
.tem-driver-scroll .tem-head-sub th{top:34px;z-index:3;}
.tem-scroll-box{max-height:520px;overflow:auto;border:1px solid #dcdcde;background:#fff;margin-top:10px;}
.tem-sort{cursor:pointer;user-select:none;white-space:nowrap;}
.tem-sort:hover{background:#2c3338!important;}
.tem-sort-arrow{font-size:11px;opacity:.85;margin-left:3px;}
.tem-sort-asc,.tem-sort-desc{background:#1d4ed8!important;}
.tem-box-grid,.tem-box-summary{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:12px;margin:12px 0}.tem-box-card{background:#fff;border:1px solid #dcdcde;border-radius:10px;padding:12px;box-shadow:0 1px 2px #0001}.tem-box-card h3{margin:.1em 0}.tem-number-grid{display:flex;flex-wrap:wrap;gap:4px;max-height:180px;overflow:auto}.tem-number-grid span{display:inline-block;background:#f0f6ff;border:1px solid #b8d7ff;border-radius:6px;padding:3px 6px;font-weight:700}.tem-timer-missing{background:#ffe2e2!important}.tem-available-screen .tem-box-card strong{font-size:28px;color:#0a7a2f}.tem-missing-screen .tem-table td:nth-child(2){font-size:18px;text-align:center}


/* 1.3.16: make the driver edit record/card vertically scrollable on smaller screens */
.tem-modal{align-items:stretch!important;overflow:hidden!important;}
.tem-card{height:100vh!important;max-height:100vh!important;min-height:0!important;overflow-y:auto!important;-webkit-overflow-scrolling:touch;box-sizing:border-box;padding-bottom:80px!important;}
.tem-card textarea{min-height:90px;}
@media(max-height:800px){.tem-card{padding-top:10px!important}.tem-card label{margin-top:5px}.tem-card input,.tem-card select,.tem-card textarea{padding:6px}}
.tem-trackside-view{max-width:1100px;margin:0 auto;padding:16px}.tem-trackside-note{font-size:14px;opacity:.75}.tem-trackside-counts{margin:14px 0 20px}.tem-trackside-group{margin-top:24px;border-bottom:2px solid #ddd;padding-bottom:6px}.tem-trackside-table th,.tem-trackside-table td{font-size:18px;padding:10px 12px}.tem-trackside-table th:first-child,.tem-trackside-table td:first-child{width:90px;text-align:center}.tem-trackside-table td:first-child strong{font-size:22px}.tem-trackside-table tr:nth-child(even){background:#fafafa}@media(max-width:700px){.tem-trackside-table th,.tem-trackside-table td{font-size:15px;padding:8px}.tem-trackside-table td:first-child strong{font-size:18px}}

.tem-trackside-group-block{margin:18px 0 28px 0;padding:12px;border:1px solid #dcdcde;border-radius:8px;background:#fff}.tem-trackside-subhead{margin:12px 0 6px 0;font-size:15px}.tem-trackside-no-timer td{background:#fff7db}.tem-trackside-out td{background:#e7f7ea}.tem-trackside-table th,.tem-trackside-table td{font-size:16px;padding:9px 10px}.tem-trackside-counts .tem-stat strong{font-size:28px}


/* 1.3.21 Trackside incident controls */
.tem-trackside-table th:nth-child(5),.tem-trackside-table td:nth-child(5){text-align:center;width:70px;font-weight:700}
.tem-trackside-table th:nth-child(6),.tem-trackside-table td:nth-child(6){white-space:nowrap;width:180px}
.tem-trackside-tow{background:#fff7db!important;border-color:#d97706!important;color:#7c2d12!important;font-weight:700!important}
.tem-trackside-crash{background:#fee2e2!important;border-color:#dc2626!important;color:#7f1d1d!important;font-weight:700!important}
.tem-crashed{background:#ffd6d6!important;outline:3px solid #dc2626!important}
.tem-crash-badge{display:inline-block;margin-left:6px;background:#dc2626;color:#fff;border-radius:999px;padding:2px 7px;font-size:11px;font-weight:800;white-space:nowrap}
