* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: #f5f5f5;
  color: #333;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 18px;
  overflow-x: auto;
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background: #fff;
  border-bottom: 2px solid #ddd;
}

header h1 {
  font-size: 28px;
  font-weight: 600;
  color: #c0392b;
}

#status {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-size: 14px;
  color: #888;
}

main {
  padding: 16px;
}

table {
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;
}

thead th {
  background: #2c3e50;
  color: #fff;
  padding: 12px 10px;
  text-align: left;
  font-weight: 600;
  font-size: 15px;
  white-space: nowrap;
  position: sticky;
  top: 0;
  z-index: 1;
  cursor: pointer;
  user-select: none;
}

thead th:hover {
  background: #34495e;
}

.sort-arrow {
  font-size: 12px;
  color: #e74c3c;
}

thead th small {
  font-weight: 400;
  color: #bdc3c7;
}

tbody td {
  padding: 10px 10px;
  border-bottom: 1px solid #ddd;
  white-space: nowrap;
  font-size: 17px;
}

tbody tr:nth-child(odd) {
  background: #fff;
}

tbody tr:nth-child(even) {
  background: #f0f4f8;
}

tbody tr:hover {
  background: #e8eef4;
}

/* Employee column */
td:first-child {
  font-weight: 600;
  color: #222;
}

/* Active customer / description */
td:nth-child(2),
td:nth-child(3) {
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Numeric columns - center align (cols 5-12) */
td:nth-child(n+5),
th:nth-child(n+5) {
  text-align: center;
  font-variant-numeric: tabular-nums;
}

/* Idle status colors */
.idle-active {
  color: #1e8449;
  font-weight: 600;
}

.idle-short {
  color: #b7950b;
}

.idle-long {
  color: #c0392b;
  font-weight: 600;
}

.idle-none {
  color: #999;
  font-style: italic;
}

/* Ticket count badges */
.badge {
  display: inline-block;
  min-width: 28px;
  padding: 2px 8px;
  border-radius: 4px;
  text-align: center;
  font-weight: 600;
}

.badge-open {
  background: #d4e6f9;
  color: #1a5276;
}

.badge-incomplete {
  background: #fde8d0;
  color: #7e3c0e;
}

.badge-complete {
  background: #d5f5e3;
  color: #1e6e3e;
}

.badge-zero {
  background: transparent;
  color: #bbb;
}

/* Billable percentage color scale */
.pct-high {
  color: #1e8449;
}

.pct-mid {
  color: #b7950b;
}

.pct-low {
  color: #c0392b;
}

/* Started time */
.time-started {
  color: #2471a3;
  font-size: 15px;
}

/* No active entry */
.inactive-dash {
  color: #bbb;
}

/* Loading state */
.loading {
  text-align: center;
  padding: 40px;
  color: #888;
  font-style: italic;
}

/* Error state */
.error {
  text-align: center;
  padding: 40px;
  color: #c0392b;
}
