/* tai-xe.css — trang riêng của tài xế (điện thoại, dùng 1 tay, ngoài trời). Chữ to, nút to,
   tương phản cao. Dùng chung biến màu + toast + nút của style.css. */
.tx-body { background: var(--bg); min-height: 100vh; font-size: 17px; }
.tx-head {
  position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 12px;
  padding: 12px 16px calc(12px); padding-top: calc(12px + env(safe-area-inset-top));
  background: var(--ink); color: #fff;
}
.tx-head .brand-mark { flex: 0 0 auto; }
.tx-head-text { flex: 1; min-width: 0; }
.tx-eyebrow { font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--side-text-faint); font-weight: 600; }
.tx-name { font-size: 20px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx-refresh {
  width: 44px; height: 44px; border-radius: 8px; border: 1px solid #3a3d43; background: transparent;
  color: #fff; font-size: 22px; cursor: pointer;
}
.tx-main { max-width: 560px; margin: 0 auto; padding: 14px 12px 40px; }
.tx-section { font-size: 14px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--gray); margin: 26px 4px 10px; }
.tx-empty { background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 26px 18px; text-align: center; color: var(--gray); }
.tx-empty.error { color: var(--red); border-color: var(--red); background: var(--red-soft); }
.tx-foot { font-size: 14px; color: var(--gray); line-height: 1.5; margin: 22px 4px 0; }
.tx-muted { color: var(--gray); font-size: 14px; font-weight: 500; }

.tx-trip {
  background: #fff; border: 1px solid var(--border); border-left: 5px solid var(--accent);
  border-radius: 10px; padding: 16px 14px; margin-bottom: 14px; box-shadow: var(--shadow);
}
.tx-trip.is-done { border-left-color: var(--green); opacity: 0.85; }
.tx-trip-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.tx-ma { font-size: 19px; font-weight: 600; }
.tx-badge { font-size: 12.5px; font-weight: 800; padding: 3px 8px; border-radius: 5px; background: var(--ink); color: #fff; letter-spacing: 0.04em; }
.tx-badge.nhap { background: var(--blue); }
.tx-badge.done { background: var(--green); }

.tx-info { display: grid; grid-template-columns: max-content 1fr; gap: 6px 12px; margin: 0 0 12px; font-size: 16px; }
.tx-info dt { color: var(--gray); font-size: 14px; padding-top: 1px; }
.tx-info dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; white-space: pre-line; }

.tx-legs { display: flex; flex-direction: column; gap: 10px; }
.tx-leg { border: 1px solid var(--border); border-radius: 8px; padding: 12px; background: var(--bg); }
.tx-leg.wait { background: var(--amber-soft); border-color: #e8cf98; }
.tx-leg.done { background: var(--green-soft); border-color: #b7dcc4; }
.tx-leg.warn { background: var(--red-soft); border-color: #f0b5a8; }
.tx-leg-head { display: flex; flex-direction: column; gap: 2px; }
.tx-leg-head strong { font-size: 17px; }
.tx-leg-route { font-size: 15px; color: var(--ink-soft); }
.tx-leg-state { margin-top: 6px; font-size: 15px; font-weight: 600; }
.tx-leg.done .tx-leg-state { color: var(--green); }
.tx-leg.warn .tx-leg-state { color: var(--red); }
.tx-leg.wait .tx-leg-state { color: var(--amber); }
.tx-leg-reason { margin-top: 6px; font-size: 15px; }
.tx-leg-note { margin-top: 6px; font-size: 14px; color: var(--gray); }

.tx-big-btn {
  display: block; width: 100%; margin-top: 10px; min-height: 54px; border: 0; border-radius: 10px;
  background: var(--ink); color: #fff; font-family: inherit; font-size: 18px; font-weight: 800; cursor: pointer;
}
.tx-big-btn:disabled { opacity: 0.5; }
.tx-leg.warn .tx-big-btn { background: var(--red); }
.tx-photo-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; margin-top: 12px;
  min-height: 50px; border: 2px dashed var(--border); border-radius: 10px; background: #fff;
  font-family: inherit; font-size: 17px; font-weight: 700; color: var(--ink); cursor: pointer;
}
.tx-count { font-size: 13px; font-weight: 600; color: var(--green); background: var(--green-soft); padding: 2px 7px; border-radius: 10px; }

/* Hộp xác nhận trượt từ đáy */
.tx-sheet-overlay { position: fixed; inset: 0; z-index: 100; display: none; align-items: flex-end; justify-content: center; }
.tx-sheet-overlay.open { display: flex; }
.tx-sheet-backdrop { position: absolute; inset: 0; background: rgba(23,25,29,0.5); }
.tx-sheet {
  position: relative; width: 100%; max-width: 560px; background: #fff; border-radius: 16px 16px 0 0;
  padding: 20px 16px calc(16px + env(safe-area-inset-bottom)); animation: pnl-slide-in 0.2s ease;
}
.tx-sheet-title { font-size: 19px; font-weight: 800; margin-bottom: 8px; }
.tx-sheet-body p { margin: 0 0 6px; color: var(--ink-soft); line-height: 1.5; }
.tx-sheet-actions { display: flex; gap: 10px; margin-top: 14px; }
.tx-sheet-actions > * { flex: 1; min-height: 50px; font-size: 17px; }
.tx-radios { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; }
.tx-radio { display: flex; align-items: center; gap: 10px; padding: 10px 6px; font-size: 16px; border-bottom: 1px solid var(--border-soft); }
.tx-radio input { width: 20px; height: 20px; accent-color: var(--accent); }
.tx-file {
  display: flex; align-items: center; justify-content: center; min-height: 54px; border-radius: 10px;
  background: var(--ink); color: #fff; font-weight: 800; font-size: 17px; cursor: pointer;
  text-align: center; padding: 6px 12px;
}
.tx-file + .tx-file { margin-top: 8px; }
.tx-file-name { margin: 8px 2px; }
.tx-note { width: 100%; padding: 12px; border: 1px solid var(--border); border-radius: 8px; font-family: inherit; font-size: 16px; }

/* Link cố định /tai-xe: nhập số điện thoại */
.tx-login { background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 18px 16px; display: flex; flex-direction: column; gap: 8px; }
.tx-login-btn { min-height: 52px; font-size: 17px; margin-top: 6px; }
.tx-doi { background: none; border: 0; padding: 2px 0 0; color: var(--side-text-faint); font-size: 13px; text-decoration: underline; cursor: pointer; }
.tx-doi[hidden] { display: none; }

/* Ảnh đã gửi của chuyến (03/11/2026) */
.tx-anh-box { margin-top: 12px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.tx-anh-box > summary { padding: 12px; font-weight: 700; font-size: 15px; cursor: pointer; }
.tx-anh-loi { color: var(--red); font-size: 13px; font-weight: 700; margin-left: 6px; }
.tx-anh-list { display: flex; flex-direction: column; gap: 8px; padding: 0 12px 12px; }
.tx-anh { display: flex; align-items: center; gap: 10px; border: 1px solid var(--border-soft); border-radius: 8px; padding: 6px; }
.tx-anh.warn { border-color: #f0b5a8; background: var(--red-soft); }
.tx-anh.done { background: var(--green-soft); }
.tx-anh img { width: 64px; height: 64px; object-fit: cover; border-radius: 6px; display: block; }
.tx-anh-info { flex: 1; min-width: 0; }
.tx-anh-loai { font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.tx-anh-tt { font-size: 13.5px; color: var(--gray); }
.tx-anh.warn .tx-anh-tt { color: var(--red); font-weight: 600; }
.tx-anh.done .tx-anh-tt { color: var(--green); }
.tx-anh-xoa { flex: 0 0 auto; width: 40px; height: 40px; border-radius: 8px; border: 1px solid var(--border); background: #fff; font-size: 16px; color: var(--gray); }
