/* ===== ĐIỀU XE – Liquid Glass theme ===== */
[hidden] { display: none !important; }
:root {
  --bg0: #020f24;
  --bg1: #04224a;
  --bg2: #0a3d78;
  --vtb: #0066b3;
  --vtb-red: #e31837;
  --accent: #3aa0ff;
  --text: #f3f8ff;
  --muted: rgba(220, 234, 255, .66);
  --faint: rgba(220, 234, 255, .38);
  --line: rgba(255, 255, 255, .14);
  --glass-a: rgba(255, 255, 255, .15);
  --glass-b: rgba(255, 255, 255, .05);
  --glass-brd: rgba(255, 255, 255, .24);
  --ok: #34d17a;
  --warn: #ffb547;
  --danger: #ff5a52;
  --info: #5ac8fa;
  --purple: #b58cff;
  --r-xl: 32px; --r-lg: 24px; --r-md: 18px; --r-sm: 12px;
  --blur: blur(26px) saturate(170%);
  --shadow: 0 18px 50px rgba(0, 8, 30, .45);
  --font: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: var(--font); color: var(--text); font-size: 16px; line-height: 1.4;
  background: radial-gradient(1200px 800px at 85% -10%, #1d6fd1 0%, transparent 60%),
              radial-gradient(900px 700px at -10% 110%, #0b5aa8 0%, transparent 55%),
              linear-gradient(160deg, var(--bg0), var(--bg1) 45%, var(--bg2));
  background-attachment: fixed;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: rgba(90, 170, 255, .45); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .18); border-radius: 10px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-track { background: transparent; }

/* Đốm sáng nền chuyển động chậm */
.bg-blobs { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.bg-blobs i { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .55; animation: drift 28s ease-in-out infinite alternate; }
.bg-blobs i:nth-child(1) { width: 520px; height: 520px; background: #1f8bff; left: 55%; top: -120px; }
.bg-blobs i:nth-child(2) { width: 420px; height: 420px; background: #00c2c7; left: -120px; top: 45%; animation-duration: 34s; opacity: .35; }
.bg-blobs i:nth-child(3) { width: 360px; height: 360px; background: #e31837; right: -100px; bottom: -120px; animation-duration: 40s; opacity: .22; }
@keyframes drift { to { transform: translate(-60px, 50px) scale(1.12); } }

/* ===== Kính ===== */
.glass {
  position: relative;
  background: linear-gradient(140deg, var(--glass-a), var(--glass-b));
  backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur);
  border: 1px solid var(--glass-brd);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .38), inset 0 -1px 0 rgba(255, 255, 255, .06), var(--shadow);
  border-radius: var(--r-lg);
}
.glass::before { /* viền sáng cong kiểu liquid glass */
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(160deg, rgba(255, 255, 255, .22), transparent 28%, transparent 72%, rgba(255, 255, 255, .07));
  mask: linear-gradient(#000, #000) content-box, linear-gradient(#000, #000); -webkit-mask-composite: xor; mask-composite: exclude;
  padding: 1px;
}
.card { padding: 22px; }
.card + .card { margin-top: 18px; }
.card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.card-head h3 { margin: 0; font-size: 20px; font-weight: 650; display: flex; align-items: center; gap: 10px; }
.card-head .sp { flex: 1; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: 13.5px; }
.ic { flex: none; vertical-align: middle; }

/* ===== Bố cục ===== */
#app { position: relative; z-index: 1; height: 100vh; }
.shell { display: grid; grid-template-columns: 112px 1fr; height: 100vh; gap: 0; }
.side { margin: 14px 0 14px 14px; padding: 14px 10px; display: flex; flex-direction: column; align-items: stretch; gap: 8px; border-radius: var(--r-xl); }
.side .logo { display: grid; place-items: center; padding: 6px 0 14px; }
.side .logo .lg { width: 58px; height: 58px; border-radius: 18px; display: grid; place-items: center; background: linear-gradient(145deg, #2a8cff, #0050a0); box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 8px 20px rgba(0, 80, 200, .5); }
.nav-item { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 4px; border-radius: 20px; color: var(--muted); text-decoration: none; font-size: 13px; font-weight: 600; border: 1px solid transparent; transition: .18s; cursor: pointer; background: none; }
@media (hover: hover) { .nav-item:not(.active):hover { color: var(--text); background: rgba(255, 255, 255, .07); } }
.nav-item.active { color: #fff; background: linear-gradient(150deg, rgba(80, 170, 255, .55), rgba(30, 110, 230, .35)); border-color: rgba(255, 255, 255, .3); box-shadow: inset 0 1px 0 rgba(255,255,255,.4), 0 8px 22px rgba(20, 100, 220, .4); }
.nav-item .badge { position: absolute; top: 6px; right: 14px; }
.side .sp { flex: 1; }
.badge { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--vtb-red); color: #fff; font-size: 12.5px; font-weight: 700; display: inline-grid; place-items: center; box-shadow: 0 2px 8px rgba(227, 24, 55, .6); }

.main { display: flex; flex-direction: column; min-width: 0; height: 100vh; }
.topbar { display: flex; align-items: center; gap: 14px; margin: 14px 14px 0; padding: 12px 18px; border-radius: var(--r-xl); }
.topbar h1 { margin: 0; font-size: 24px; font-weight: 700; letter-spacing: -.01em; display: flex; align-items: center; gap: 12px; }
.topbar .sp { flex: 1; }
.clock { text-align: right; line-height: 1.15; }
.clock b { font-size: 24px; font-variant-numeric: tabular-nums; }
.clock span { display: block; font-size: 13px; color: var(--muted); }
.sync-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 10px var(--ok); }
.sync-dot.busy { background: var(--warn); box-shadow: 0 0 10px var(--warn); }
.sync-dot.err { background: var(--danger); box-shadow: 0 0 10px var(--danger); }
.me-chip { display: flex; align-items: center; gap: 10px; padding: 6px 14px 6px 6px; border-radius: 30px; background: rgba(255, 255, 255, .08); border: 1px solid var(--line); cursor: pointer; }
.me-chip:hover { background: rgba(255, 255, 255, .14); }
.me-chip b { display: block; font-size: 15px; }
.me-chip small { color: var(--muted); font-size: 12px; }
.content { flex: 1; overflow: auto; padding: 18px 14px 40px; }
.content > .wrap { max-width: 1600px; margin: 0 auto; }

/* ===== Nút ===== */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 46px; padding: 0 20px; border-radius: 16px; border: 1px solid rgba(255, 255, 255, .26); cursor: pointer; font-weight: 650; font-size: 16px; color: #fff; text-decoration: none; white-space: nowrap;
  background: linear-gradient(150deg, rgba(255, 255, 255, .2), rgba(255, 255, 255, .07));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35), 0 6px 16px rgba(0, 10, 40, .3); transition: transform .12s, filter .15s, background .15s; backdrop-filter: blur(10px); }
.btn:hover { filter: brightness(1.12); }
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .38; cursor: not-allowed; filter: grayscale(.6); transform: none; }
.btn.primary { background: linear-gradient(150deg, #3ea2ff, #0a5fd0); border-color: rgba(160, 210, 255, .6); }
.btn.ok { background: linear-gradient(150deg, #3ee08a, #12a058); border-color: rgba(170, 255, 200, .55); }
.btn.danger { background: linear-gradient(150deg, #ff6b62, #d42a3c); border-color: rgba(255, 180, 180, .5); }
.btn.warn { background: linear-gradient(150deg, #ffc35c, #e48a12); border-color: rgba(255, 220, 160, .55); color: #1f1300; }
.btn.ghost { background: rgba(255, 255, 255, .06); box-shadow: none; }
.btn-sm { height: 36px; padding: 0 14px; font-size: 14px; border-radius: 12px; gap: 6px; }
.btn-lg { height: 58px; padding: 0 26px; font-size: 18px; border-radius: 20px; }
.btn-xl { height: 76px; padding: 0 30px; font-size: 21px; border-radius: 24px; gap: 14px; }
.btn-block { width: 100%; }
.icon-btn { width: 44px; height: 44px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255, 255, 255, .07); display: inline-grid; place-items: center; cursor: pointer; color: var(--text); position: relative; }
.icon-btn:hover { background: rgba(255, 255, 255, .15); }
.icon-btn .badge { position: absolute; top: -6px; right: -6px; }
.row-btns { display: flex; gap: 12px; justify-content: flex-end; margin-top: 18px; flex-wrap: wrap; }

/* Nút thao tác nhanh (dashboard) */
.quick { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 18px; }
.quick-btn { display: flex; align-items: center; gap: 16px; padding: 18px 20px; border-radius: var(--r-lg); cursor: pointer; text-align: left; border: 1px solid var(--glass-brd); color: var(--text); font-size: 19px; font-weight: 700; position: relative;
  background: linear-gradient(140deg, rgba(255, 255, 255, .17), rgba(255, 255, 255, .05)); backdrop-filter: var(--blur); box-shadow: inset 0 1px 0 rgba(255,255,255,.35), var(--shadow); transition: transform .12s, filter .15s; }
.quick-btn:hover { filter: brightness(1.12); transform: translateY(-2px); }
.quick-btn:active { transform: scale(.98); }
.quick-btn .qi { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; flex: none; background: linear-gradient(150deg, var(--c1, #3ea2ff), var(--c2, #0a5fd0)); box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 8px 18px rgba(0,0,0,.25); }
.quick-btn .badge { position: absolute; top: 12px; right: 12px; }

/* Ô thống kê */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin-bottom: 18px; }
.tile { padding: 16px 18px; display: flex; align-items: center; gap: 14px; cursor: default; }
.tile.click { cursor: pointer; }
.tile.click:hover { filter: brightness(1.1); }
.tile .ti { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; background: color-mix(in srgb, var(--c, #3aa0ff) 30%, transparent); color: var(--c, #3aa0ff); border: 1px solid color-mix(in srgb, var(--c, #3aa0ff) 45%, transparent); }
.tile b { font-size: 32px; line-height: 1; font-variant-numeric: tabular-nums; display: block; }
.tile span { color: var(--muted); font-size: 14px; }
.tile.hot { border-color: rgba(255, 90, 82, .7); box-shadow: 0 0 0 1px rgba(255,90,82,.4), 0 0 28px rgba(255, 90, 82, .3), var(--shadow); }

/* ===== Form ===== */
.inp, .sel { width: 100%; min-height: 50px; padding: 12px 16px; border-radius: 16px; border: 1px solid rgba(255, 255, 255, .22); background: rgba(0, 20, 50, .35); color: var(--text); outline: none; font-size: 16.5px; transition: border .15s, box-shadow .15s; }
textarea.inp { resize: vertical; min-height: 60px; line-height: 1.4; }
.inp:focus, .sel:focus { border-color: #67b6ff; box-shadow: 0 0 0 4px rgba(80, 160, 255, .25); }
.sel option, .sel optgroup { background: #0b2a52; color: #fff; }
.inp::placeholder { color: var(--faint); }
input[type=date].inp, input[type=time].inp { color-scheme: dark; }
.fld { display: flex; flex-direction: column; gap: 6px; }
.fld > span { font-size: 13.5px; font-weight: 650; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; display: flex; align-items: center; gap: 6px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.hstack { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.seg { display: inline-flex; padding: 4px; border-radius: 18px; background: rgba(0, 20, 50, .35); border: 1px solid var(--line); gap: 4px; flex-wrap: wrap; }
.seg button { height: 44px; padding: 0 18px; border-radius: 14px; border: 0; background: none; cursor: pointer; font-weight: 650; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; }
.seg button.on { background: linear-gradient(150deg, rgba(90, 175, 255, .6), rgba(30, 110, 230, .45)); color: #fff; box-shadow: inset 0 1px 0 rgba(255,255,255,.4), 0 4px 12px rgba(0, 60, 160, .4); }

/* Chọn tài xế: bấm để đổi vai trò Không → Chính → Dự phòng */
.dpick { display: flex; flex-wrap: wrap; gap: 10px; }
.dpick button { display: flex; align-items: center; gap: 10px; padding: 8px 16px 8px 8px; min-height: 56px; border-radius: 18px; border: 1.5px solid var(--line); background: rgba(255,255,255,.05); cursor: pointer; text-align: left; transition: .15s; }
.dpick button:hover { background: rgba(255,255,255,.12); }
.dpick button b { display: block; font-size: 16px; }
.dpick button small { display: block; font-size: 12px; color: var(--muted); }
.dpick button.main { border-color: #5fb4ff; background: linear-gradient(150deg, rgba(60,150,255,.45), rgba(20,90,200,.3)); }
.dpick button.backup { border-color: var(--warn); border-style: dashed; background: rgba(255,181,71,.14); }
.dpick button.l1 small { color: var(--warn); }
.dpick button.l2 small { color: var(--danger); }
.dpick .role { margin-left: 4px; font-size: 11.5px; font-weight: 800; padding: 3px 8px; border-radius: 8px; background: rgba(0,0,0,.25); }

/* ===== Chip / pill / avatar ===== */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 15px; font-size: 14px; font-weight: 650; background: rgba(255, 255, 255, .1); border: 1px solid var(--line); white-space: nowrap; }
.dept { --h: 210; background: hsla(var(--h), 85%, 60%, .22); border-color: hsla(var(--h), 85%, 70%, .45); color: hsl(var(--h), 100%, 88%); }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px; border-radius: 14px; font-size: 13px; font-weight: 700; white-space: nowrap; }
.pill.st-planned { background: rgba(90, 170, 255, .2); color: #a9d4ff; }
.pill.st-started { background: rgba(255, 181, 71, .25); color: #ffd28e; }
.pill.st-done { background: rgba(52, 209, 122, .22); color: #8ff0b8; }
.pill.st-cancelled { background: rgba(255, 90, 82, .2); color: #ffaaa5; }
.pill.pending { background: rgba(181, 140, 255, .25); color: #dcc9ff; }
.pill.backup { background: rgba(255, 181, 71, .2); color: #ffd28e; border: 1px dashed rgba(255,181,71,.6); }
.pill.warn { background: rgba(255, 181, 71, .2); color: #ffd28e; }
.pill.danger { background: rgba(255, 90, 82, .22); color: #ffb0ab; }
.avatar { --h: 210; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 18px; flex: none; color: #fff;
  background: linear-gradient(145deg, hsl(var(--h), 85%, 62%), hsl(calc(var(--h) + 40), 80%, 42%)); box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 4px 12px rgba(0,0,0,.3); }
.avatar.sm { width: 32px; height: 32px; font-size: 14px; }
.avatar.lg { width: 64px; height: 64px; font-size: 26px; }
.avatar.taxi { background: linear-gradient(145deg, #ffd34d, #e8a400); color: #2b1d00; }
.avatar.none { background: rgba(255,255,255,.12); color: var(--muted); }


/* ===== Danh sách chuyến ===== */
.trip-list { display: flex; flex-direction: column; gap: 10px; }
.trip { display: grid; grid-template-columns: 110px 1fr auto; gap: 16px; align-items: center; padding: 14px 18px; border-radius: var(--r-md); background: rgba(255, 255, 255, .06); border: 1px solid var(--line); cursor: pointer; transition: background .15s, transform .12s; }
.trip:hover { background: rgba(255, 255, 255, .12); }
.trip.cancelled { opacity: .5; }
.trip.cancelled .trip-title { text-decoration: line-through; }
.trip-time b { display: block; font-size: 22px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.trip-time span { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.trip-title { font-weight: 650; font-size: 16.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.trip-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 6px; color: var(--muted); font-size: 14px; align-items: center; }
.trip-meta .loc { display: inline-flex; align-items: center; gap: 4px; max-width: 520px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trip-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.drv-chips { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.day-head { display: flex; align-items: center; gap: 10px; margin: 18px 4px 10px; font-size: 17px; font-weight: 750; }
.day-head:first-child { margin-top: 0; }
.day-head .today { background: var(--vtb-red); color: #fff; font-size: 12px; padding: 3px 9px; border-radius: 8px; }
.empty { padding: 34px; text-align: center; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.empty .ic { opacity: .5; }

/* ===== Dashboard tài xế ===== */
.drv-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.hero { padding: 26px 28px; }
.hero .lbl { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.hero .time { font-size: 64px; font-weight: 800; letter-spacing: -.02em; line-height: 1; margin: 10px 0 6px; font-variant-numeric: tabular-nums; }
.hero .time small { font-size: 30px; color: var(--muted); font-weight: 600; }
.hero .count { font-size: 20px; font-weight: 700; color: var(--info); }
.hero .what { font-size: 22px; font-weight: 700; margin: 16px 0 10px; line-height: 1.3; }
.hero .info { display: grid; gap: 10px; font-size: 16.5px; }
.hero .info div { display: flex; gap: 10px; align-items: flex-start; }
.hero .info .ic { margin-top: 2px; color: var(--info); }
.big-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 20px; }
.big-btn { height: 150px; border-radius: 30px; border: 1.5px solid rgba(255,255,255,.35); cursor: pointer; color: #fff; font-size: 28px; font-weight: 850; letter-spacing: .03em; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; transition: transform .12s, filter .15s; box-shadow: inset 0 2px 0 rgba(255,255,255,.4), 0 16px 36px rgba(0,0,0,.35); }
.big-btn:hover { filter: brightness(1.1); }
.big-btn:active { transform: scale(.97); }
.big-btn.go { background: linear-gradient(150deg, #44e892, #0f9a52); }
.big-btn.fin { background: linear-gradient(150deg, #4aaeff, #0a58c8); }
.big-btn.yes { background: linear-gradient(150deg, #44e892, #0f9a52); height: 110px; font-size: 24px; }
.big-btn.no { background: linear-gradient(150deg, #8d9bb5, #4b5a78); height: 110px; font-size: 24px; }
.big-btn[disabled] { opacity: .28; filter: grayscale(.8); cursor: not-allowed; transform: none; box-shadow: none; }
.big-btn small { font-size: 15px; font-weight: 600; opacity: .9; letter-spacing: 0; }
.alert-banner { display: flex; align-items: center; gap: 16px; padding: 18px 22px; margin-bottom: 18px; border-radius: var(--r-lg); font-size: 20px; font-weight: 750;
  background: linear-gradient(140deg, rgba(255, 90, 82, .55), rgba(227, 24, 55, .35)); border: 1px solid rgba(255, 170, 170, .6); animation: glow 1.4s ease-in-out infinite; }
.alert-banner.soon { background: linear-gradient(140deg, rgba(255, 181, 71, .5), rgba(228, 138, 18, .3)); border-color: rgba(255, 220, 160, .6); }
@keyframes glow { 50% { box-shadow: 0 0 34px rgba(255, 90, 82, .55); } }
.backup-box { margin-top: 18px; padding: 18px; border-radius: var(--r-md); border: 1.5px dashed rgba(255,181,71,.7); background: rgba(255,181,71,.1); }

/* ===== Modal ===== */
.modal-wrap { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px; background: rgba(0, 8, 25, .55); backdrop-filter: blur(6px); animation: fade .18s; }
.modal-wrap.out { opacity: 0; transition: opacity .18s; }
.modal { width: min(680px, 100%); max-height: calc(100vh - 48px); display: flex; flex-direction: column; border-radius: var(--r-xl); background: linear-gradient(150deg, rgba(40, 80, 140, .72), rgba(10, 30, 70, .82)); animation: pop .22s cubic-bezier(.2, 1.3, .4, 1); }
.modal.wide { width: min(1040px, 100%); }
.modal-head { display: flex; align-items: center; gap: 12px; padding: 20px 22px 12px; }
.modal-head h2 { margin: 0; font-size: 22px; flex: 1; }
.modal-ic { width: 46px; height: 46px; border-radius: 15px; display: grid; place-items: center; background: linear-gradient(150deg, #3ea2ff, #0a5fd0); }
.modal-body { padding: 8px 22px 22px; overflow: auto; }
.confirm-msg { font-size: 18px; margin: 4px 0 12px; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { transform: scale(.94); opacity: 0; } }

.detail { display: grid; gap: 12px; }
.detail .drow { display: grid; grid-template-columns: 130px 1fr; gap: 12px; align-items: start; }
.detail .drow > span { color: var(--muted); font-size: 14px; font-weight: 650; padding-top: 2px; display: flex; align-items: center; gap: 6px; }
.detail .drow > div { white-space: pre-line; }
.stop { padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,.06); border: 1px solid var(--line); }
.stop + .stop { margin-top: 8px; }
.stop .loc { color: var(--info); display: flex; gap: 6px; margin-top: 6px; white-space: pre-line; }
.hist { font-size: 13.5px; color: var(--muted); border-left: 2px solid var(--line); padding-left: 12px; display: grid; gap: 6px; max-height: 180px; overflow: auto; }
.action-bar { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.stop-edit { display: grid; grid-template-columns: 1fr 1fr auto; gap: 10px; align-items: start; }

/* ===== Toast ===== */
#toast-root { position: fixed; right: 20px; bottom: 20px; z-index: 80; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.toast { display: flex; align-items: center; gap: 12px; padding: 14px 18px; max-width: 460px; font-size: 15.5px; font-weight: 600; border-radius: 18px; animation: slide .25s; cursor: pointer; background: linear-gradient(140deg, rgba(40, 90, 160, .85), rgba(15, 40, 90, .9)); }
.toast.out { opacity: 0; transform: translateY(10px); transition: .35s; }
.toast.t-ok .ic { color: var(--ok); }
.toast.t-error { background: linear-gradient(140deg, rgba(200, 40, 50, .9), rgba(120, 20, 30, .9)); }
.toast.t-warn .ic { color: var(--warn); }
@keyframes slide { from { transform: translateY(16px); opacity: 0; } }

/* ===== Thông báo ===== */
.notif-panel { position: fixed; top: 84px; right: 24px; width: 440px; max-height: calc(100vh - 110px); z-index: 40; display: flex; flex-direction: column; border-radius: var(--r-lg); background: linear-gradient(150deg, rgba(40, 80, 140, .8), rgba(10, 30, 70, .9)); animation: pop .2s; }
.notif-panel .nh { display: flex; align-items: center; padding: 16px 18px 10px; gap: 10px; }
.notif-panel .nh h3 { margin: 0; flex: 1; font-size: 19px; }
.notif-list { overflow: auto; padding: 0 10px 12px; }
.notif { display: flex; gap: 12px; padding: 12px; border-radius: 14px; cursor: pointer; }
.notif:hover { background: rgba(255,255,255,.08); }
.notif .ni { width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; flex: none; background: color-mix(in srgb, var(--c, #3aa0ff) 28%, transparent); color: var(--c, #3aa0ff); }
.notif b { display: block; font-size: 15px; }
.notif p { margin: 2px 0 0; font-size: 14px; color: var(--muted); }
.notif small { font-size: 12px; color: var(--faint); }
.notif.unread { background: rgba(90, 170, 255, .12); }

/* ===== Bảng ===== */
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 14.5px; }
.table th { text-align: left; font-size: 12.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; padding: 10px 12px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: rgba(10, 35, 75, .92); backdrop-filter: blur(8px); z-index: 1; }
.table td { padding: 12px; border-bottom: 1px solid rgba(255,255,255,.07); vertical-align: top; }
.table tr.click { cursor: pointer; }
.table tr.click:hover td { background: rgba(255,255,255,.05); }
.table .clip { max-width: 360px; white-space: pre-line; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.tag { display: inline-block; padding: 3px 9px; border-radius: 8px; font-size: 12px; font-weight: 800; }
.tag.new { background: rgba(52, 209, 122, .25); color: #9ff5c4; }
.tag.update { background: rgba(90, 170, 255, .25); color: #b5dbff; }
.tag.keep { background: rgba(181, 140, 255, .25); color: #dcc9ff; }
.tag.same { background: rgba(255,255,255,.1); color: var(--muted); }
.tag.remove { background: rgba(255, 90, 82, .25); color: #ffb0ab; }
.flag { color: var(--warn); font-size: 13px; display: flex; gap: 5px; align-items: flex-start; margin-top: 4px; }
.diff-from { color: #ffaaa5; text-decoration: line-through; }
.diff-to { color: #9ff5c4; font-weight: 650; }

/* ===== Import ===== */
.drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 46px 20px; border-radius: var(--r-xl); border: 2px dashed rgba(255,255,255,.35); cursor: pointer; text-align: center; transition: .15s; }
.drop:hover, .drop.over { background: rgba(90, 170, 255, .12); border-color: #67b6ff; }
.drop .di { width: 86px; height: 86px; border-radius: 28px; display: grid; place-items: center; background: linear-gradient(150deg, #3ee08a, #12a058); box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 12px 28px rgba(0,0,0,.3); }
.drop h3 { margin: 0; font-size: 22px; }

/* ===== Đăng nhập ===== */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card { width: min(520px, 100%); padding: 34px; border-radius: 36px; }
.login-card .brand { display: flex; align-items: center; gap: 16px; margin-bottom: 26px; }
.login-card .brand .lg { width: 72px; height: 72px; border-radius: 22px; display: grid; place-items: center; background: linear-gradient(145deg, #2a8cff, #0050a0); box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 12px 26px rgba(0, 80, 200, .5); }
.login-card h1 { margin: 0; font-size: 30px; letter-spacing: -.01em; }
.login-card .brand p { margin: 2px 0 0; color: var(--muted); }
.login-card .stack { gap: 16px; }
.login-hero { width: 100%; height: 120px; margin-bottom: 8px; }
.pin { letter-spacing: .5em; font-size: 24px; text-align: center; font-weight: 800; }
.folder-note { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,.06); color: var(--muted); font-size: 14px; }

/* ===== Tiện ích khác ===== */
.grid-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.grid-3-1 { display: grid; grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr); gap: 18px; align-items: start; }
.next-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.next-card { padding: 16px; border-radius: var(--r-md); background: rgba(255,255,255,.06); border: 1px solid var(--line); cursor: pointer; }
.next-card:hover { background: rgba(255,255,255,.11); }
.next-card .nc-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.next-card .nc-head b { font-size: 18px; display: block; }
.next-card .nc-time { font-size: 26px; font-weight: 800; font-variant-numeric: tabular-nums; }
.next-card .nc-what { margin-top: 4px; color: var(--muted); font-size: 14.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.toolbar .sp { flex: 1; }
.date-nav { display: inline-flex; align-items: center; gap: 8px; }
.date-nav .dlabel { min-width: 210px; text-align: center; font-size: 19px; font-weight: 750; }
.warn-box { padding: 14px 16px; border-radius: 16px; background: rgba(255, 181, 71, .12); border: 1px solid rgba(255, 181, 71, .4); }
.danger-box { padding: 14px 16px; border-radius: 16px; background: rgba(255, 90, 82, .12); border: 1px solid rgba(255, 90, 82, .4); }
.kbd { font-family: Consolas, monospace; background: rgba(255,255,255,.12); padding: 1px 6px; border-radius: 6px; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.legend i { display: inline-block; width: 22px; height: 12px; border-radius: 4px; vertical-align: -1px; margin-right: 6px; }
.req { padding: 18px; border-radius: var(--r-md); background: rgba(255,255,255,.06); border: 1px solid var(--line); }
.req + .req { margin-top: 14px; }
.req-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.req-head b { font-size: 18px; }
.unsupported { max-width: 640px; margin: 15vh auto; padding: 34px; text-align: center; }

@media (max-width: 1200px) {
  .drv-grid, .grid-2, .grid-3-1 { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .shell { grid-template-columns: 1fr; }
  .side { display: none; }
  .grid2, .grid3 { grid-template-columns: 1fr; }
  .trip { grid-template-columns: 80px 1fr; }
  .trip-right { grid-column: 1 / -1; align-items: flex-start; }
}

/* Thẻ chuyến trong cột hẹp: phần xe/trạng thái xuống dòng dưới */
.card { container-type: inline-size; }
@container (max-width: 680px) {
  .trip { grid-template-columns: 84px 1fr; gap: 12px; }
  .trip-right { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: flex-start; padding-left: 96px; }
  .trip-right .drv-chips { justify-content: flex-start; }
  .trip-time b { font-size: 20px; }
}
