/* 10 Cent Towing — v0.1.001. Navy + Amber Beacon. One button system: outlined only, momentary fill on tap.
   v0.2.012: these are the 10 Cent Towing (live) colors. Other skins (Cinder in Demo Mode) override the same
   variables from skins.js; var(--x, fallback) uses below keep the live look identical when a skin leaves --x unset. */
:root {
  --bg: #F5F6F8;
  --card: #FFFFFF;
  --field: #FFFFFF;
  --line: #D8DDE5;
  --text: #0E1A33;
  --muted: #5A6578;
  --brand: #00204F;          /* buttons, links, focus */
  --on-brand: #FFFFFF;
  --accent: #C97F00;         /* amber beacon: highlights, current status */
  --blue: #2F5BC2;
  --ok: #067647;  --ok-bg: #E7F6EC;
  --warn: #B54708; --warn-bg: #FEF4E6;
  --bad: #B42318;  --bad-bg: #FDECEA;
  --info-bg: #E8EEF9;
  --duty: #00204F;           /* duty line on the graph */
  --shadow: 0 1px 2px rgba(14, 26, 51, 0.06), 0 4px 14px rgba(14, 26, 51, 0.06);
  --radius: 12px;
  --r-sm: 8px;
  --btn-w: 9.25rem;          /* the one button size */
  --btn-h: 44px;
  color-scheme: light;
}
[data-theme="dark"] {
  --bg: #0B0D11;
  --card: #161A21;
  --field: #0F1217;
  --line: #2A303B;
  --text: #EEF1F5;
  --muted: #9AA3B2;
  --brand: #F5A623;
  --on-brand: #0B0D11;
  --accent: #F5A623;
  --blue: #5B86E5;
  --ok: #47CD89;  --ok-bg: #0F2A1D;
  --warn: #FDB022; --warn-bg: #2B2111;
  --bad: #F97066;  --bad-bg: #2E1513;
  --info-bg: #17223A;
  --duty: #F5A623;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 6px 18px rgba(0, 0, 0, 0.35);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg); color: var(--text); line-height: 1.45; font-size: 16px;
  min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column;
  padding-bottom: env(safe-area-inset-bottom); overflow-x: hidden;
}
img, svg, canvas, video { max-width: 100%; }
a { color: var(--brand); }
h2 { font-size: 1.25rem; line-height: 1.25; }
h3 { font-size: 1.05rem; }
.icon { width: 20px; height: 20px; flex: none; display: inline-block; vertical-align: middle; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- header ---------- */
.inbox-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 9px;
  background: var(--accent);
  color: var(--on-accent, #00204F);
  font-weight: 750;
  font-size: 11px;
  line-height: 18px;
  text-align: center;
}
.banner {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0.6rem 1rem;
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.header {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  padding: 0.5rem 0.9rem; padding-top: calc(0.5rem + env(safe-area-inset-top));
  background: var(--card); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20; min-height: 62px;
}
.header-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.site-name { font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--silver, var(--muted)); font-weight: 600; white-space: nowrap; }
.page-title { font-size: 1.3rem; font-weight: 700; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.header-logo { display: none; height: 40px; width: auto; max-width: 62vw; object-fit: contain; object-position: left center; }
body.on-home .header-logo.light { display: block; }
[data-theme="dark"] body.on-home .header-logo.light { display: none; }
[data-theme="dark"] body.on-home .header-logo.dark { display: block; }
body.on-home .header-text .site-name, body.on-home .header-text .page-title { display: none; }
.header-actions { display: flex; align-items: center; gap: 0.5rem; flex: none; }
.sync-status { font-size: 0.72rem; color: var(--muted); display: none; white-space: nowrap; }
.sync-status.offline { color: var(--warn); display: inline; }
@media (min-width: 480px) { .sync-status { display: inline; } }

/* ---------- icon buttons (square, outlined) ---------- */
.icon-btn {
  width: var(--btn-h); height: var(--btn-h); min-width: var(--btn-h); flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1.5px solid var(--line); border-radius: var(--r-sm); background: transparent; color: var(--text);
  cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent; transition: background 0.12s, color 0.12s, border-color 0.12s;
}
.icon-btn.round { border-radius: 50%; }
.icon-btn.brand { border-color: var(--brand); color: var(--brand); }
.icon-btn.danger { border-color: var(--bad); color: var(--bad); }
.icon-btn:active, .icon-btn.flash { background: var(--brand); color: var(--on-brand); border-color: var(--brand); }
.icon-btn.danger:active, .icon-btn.danger.flash { background: var(--bad); color: #fff; border-color: var(--bad); }
.icon-btn:disabled { opacity: 0.45; cursor: default; }
.icon-btn:focus-visible, .btn:focus-visible, .tab:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }

/* ---------- the one button ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  width: var(--btn-w); max-width: 100%; min-height: var(--btn-h); padding: 0.45rem 0.6rem;
  border: 2px solid var(--brand); border-radius: var(--r-sm); background: transparent; color: var(--brand);
  font: inherit; font-size: 0.95rem; font-weight: 650; line-height: 1.15; text-align: center; text-decoration: none;
  cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent; user-select: none;
  transition: background 0.12s, color 0.12s;
}
.btn .icon { width: 18px; height: 18px; }
.btn:active, .btn.flash { background: var(--brand); color: var(--on-brand); }
.btn.danger { border-color: var(--bad); color: var(--bad); }
.btn.danger:active, .btn.danger.flash { background: var(--bad); color: #fff; }
.btn.primary { border-color: var(--brand); font-weight: 750; }
details.card > summary { cursor: pointer; list-style: none; }
details.card > summary::-webkit-details-marker { display: none; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.45; cursor: default; }
.btn.busy { opacity: 0.6; pointer-events: none; }
/* current status / selected: outlined + amber ring + dot, never filled */
.btn.on { border-color: var(--accent); color: var(--text); box-shadow: inset 0 0 0 2px var(--accent); }
.btn.on::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); flex: none; }

/* button layouts: lone button centered, pairs and grids equal size and centered */
.btn-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem; margin: 0.9rem 0 0.25rem; }
.btn-grid { display: grid; grid-template-columns: repeat(2, var(--btn-w)); justify-content: center; gap: 0.5rem; margin: 0.9rem 0 0.25rem; }
.btn-grid.four { grid-template-columns: repeat(2, var(--btn-w)); }
@media (min-width: 720px) { .btn-grid.four { grid-template-columns: repeat(4, var(--btn-w)); } }
.btn-grid > .btn, .btn-row > .btn { width: var(--btn-w); }
@media (max-width: 340px) { :root { --btn-w: 8.4rem; } }

/* ---------- drawer ---------- */
.drawer {
  position: fixed; top: 0; right: 0; width: min(320px, 86vw); height: 100vh; height: 100dvh;
  background: var(--card); border-left: 1px solid var(--line); z-index: 30;
  transform: translateX(100%); transition: transform 0.22s ease; display: flex; flex-direction: column;
  box-shadow: -6px 0 24px rgba(0, 0, 0, 0.18); padding-top: env(safe-area-inset-top);
}
.drawer.open { transform: translateX(0); }
.drawer-header { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding: 0.75rem 1rem; border-bottom: 1px solid var(--line); }
.drawer-logo { height: 34px; width: auto; max-width: 70%; object-fit: contain; }
.drawer-logo.dark { display: none; }
[data-theme="dark"] .drawer-logo.dark { display: block; }
[data-theme="dark"] .drawer-logo.light { display: none; }
.drawer-nav { list-style: none; padding: 0.4rem 0; flex: 1; overflow-y: auto; }
.nav-link {
  display: flex; align-items: center; gap: 0.75rem; min-height: 46px; padding: 0.6rem 1.25rem;
  color: var(--text); text-decoration: none; font-weight: 550; border-left: 3px solid transparent;
}
.nav-link .icon { color: var(--silver, var(--muted)); }
.nav-link.active { border-left-color: var(--accent); background: var(--bg); }
.nav-link.active .icon { color: var(--accent); }
.drawer-divider { height: 1px; background: var(--line); margin: 0.4rem 1.25rem; }
.drawer-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.45); z-index: 25; opacity: 0; pointer-events: none; transition: opacity 0.22s; }
.drawer-overlay.open { opacity: 1; pointer-events: auto; }

/* ---------- main, cards ---------- */
.main { flex: 1; width: 100%; max-width: 860px; margin: 0 auto; padding: 0.9rem 0.75rem 1.5rem; }
.page { display: none; }
.page.active { display: block; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 1.1rem 1rem; margin: 0 auto 0.9rem; width: 100%; max-width: 860px; min-width: 0;
}
.card.narrow { max-width: 460px; }
.card > h2 { margin-bottom: 0.6rem; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; margin-bottom: 0.6rem; flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.section-title { margin: 1.25rem 0 0.5rem; font-size: 1rem; font-weight: 700; display: flex; align-items: center; gap: 0.5rem; }
.section-title:first-child { margin-top: 0; }
.hint { font-size: 0.86rem; color: var(--muted); margin-top: 0.5rem; text-align: left; }
.hint.center { text-align: center; }
.meta { font-size: 0.86rem; color: var(--muted); }
.empty { text-align: center; color: var(--muted); padding: 1rem 0.5rem; font-size: 0.92rem; }
.warn-text { color: var(--warn); font-weight: 600; }
.bad-text { color: var(--bad); font-weight: 600; }
.ok-text { color: var(--ok); font-weight: 600; }

/* ---------- forms ---------- */
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.8rem 0.75rem; min-width: 0; }
.form-grid > * { min-width: 0; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 520px) { .form-grid { grid-template-columns: minmax(0, 1fr); } }
.field, .form-grid > label { display: flex; flex-direction: column; gap: 0.3rem; font-weight: 600; font-size: 0.9rem; min-width: 0; text-align: left; }
input, select, textarea {
  font: inherit; font-size: 16px; color: var(--text); background: var(--field);
  border: 1.5px solid var(--line); border-radius: var(--r-sm); min-height: var(--btn-h);
  padding: 0.55rem 0.7rem; width: 100%; max-width: 100%; min-width: 0; text-align: left;
}
input[type="date"], input[type="time"] { -webkit-appearance: none; appearance: none; display: block; text-align: left; }
input::-webkit-date-and-time-value { text-align: left; }
textarea { min-height: 84px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 22%, transparent); }
input:disabled, select:disabled, textarea:disabled { opacity: 0.65; }
fieldset.plain { border: 0; min-width: 0; }
.check { display: flex !important; flex-direction: row !important; align-items: center; gap: 0.6rem; font-weight: 500 !important; min-height: 40px; cursor: pointer; }
.check input { width: 22px; height: 22px; min-height: 0; flex: none; accent-color: var(--brand); padding: 0; }
.inline { display: flex; gap: 0.5rem; align-items: center; min-width: 0; }
.inline > input, .inline > select { flex: 1; }
.geo-wrap, .vin-row { display: flex; gap: 0.4rem; align-items: stretch; min-width: 0; }
.geo-wrap input, .vin-row input { flex: 1; min-width: 0; }
.field-note { font-weight: 400; font-size: 0.82rem; color: var(--muted); }
.field-note.warn { color: var(--warn); font-weight: 600; }

/* photo picker */
.photo-pick { display: flex; flex-direction: column; gap: 0.5rem; align-items: center; }
.photo-pick input[type="file"] { display: none; }
.photo-pick .pv { display: none; position: relative; }
.photo-pick .pv.show { display: inline-block; }
.photo-pick .pv img { width: 96px; height: 96px; object-fit: cover; border-radius: var(--r-sm); border: 1px solid var(--line); display: block; }
.photo-pick .pv .icon-btn { position: absolute; top: -10px; right: -10px; width: 32px; height: 32px; min-width: 32px; background: var(--card); border-radius: 50%; }
.photo-pick .btn-row { margin: 0; }
.photo-pick.compact { flex-direction: row; }

/* ---------- lists ---------- */
.list { display: flex; flex-direction: column; gap: 0.55rem; min-width: 0; }
.list-item {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.7rem 0.75rem; min-width: 0;
}
.list-item > div:first-child { min-width: 0; flex: 1; overflow-wrap: anywhere; }
.row-actions { display: flex; gap: 0.4rem; flex: none; }
.list-item.stack { flex-direction: column; align-items: stretch; }
.list-item.stack > div:first-child { flex: 1 1 auto; width: 100%; overflow-wrap: break-word; }
.list-item.stack .row-actions, .list-item.stack .btn-row { justify-content: center; flex-wrap: wrap; }
.chip-row { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.chip {
  display: inline-flex; align-items: center; gap: 0.35rem; min-height: 40px; padding: 0.3rem 0.75rem;
  border: 1.5px solid var(--line); border-radius: 999px; background: transparent; color: var(--text);
  font: inherit; font-size: 0.9rem; font-weight: 600; cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.chip .icon { width: 16px; height: 16px; }
.chip.on { border-color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); }
.chip:active, .chip.flash { background: var(--brand); color: var(--on-brand); border-color: var(--brand); }
.chip-group { display: inline-flex; align-items: stretch; border: 1.5px solid var(--line); border-radius: 999px; overflow: hidden; }
.chip-group .chip { border: 0; border-radius: 0; }
.chip-group .chip + .chip { border-left: 1px solid var(--line); padding: 0.3rem 0.55rem; }
.badge { display: inline-flex; align-items: center; gap: 0.25rem; padding: 0.1rem 0.5rem; border-radius: 999px; font-size: 0.74rem; font-weight: 700; white-space: nowrap; vertical-align: middle; border: 1px solid transparent; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.bad { background: var(--bad-bg); color: var(--bad); }
.badge.info { background: var(--info-bg); color: var(--brand); }
.badge.muted { background: transparent; border-color: var(--line); color: var(--muted); }
[data-theme="dark"] .badge.info { color: var(--blue); }

/* heads-up / banners */
/* v0.2.020 (S6): thin full tinted border plus the icon, no thick left bar */
.notice { display: flex; gap: 0.6rem; align-items: flex-start; border: 1px solid color-mix(in srgb, var(--blue) 45%, var(--line)); background: var(--info-bg); border-radius: var(--r-sm); padding: 0.65rem 0.75rem; margin: 0.75rem 0; font-size: 0.92rem; }
.notice.warn { border-color: color-mix(in srgb, var(--warn) 50%, var(--line)); background: var(--warn-bg); }
.notice.bad { border-color: color-mix(in srgb, var(--bad) 50%, var(--line)); background: var(--bad-bg); }
.notice.ok { border-color: color-mix(in srgb, var(--ok) 50%, var(--line)); background: var(--ok-bg); }
.notice > .icon { margin-top: 1px; color: var(--blue); }
.notice.warn > .icon { color: var(--warn); }
.notice.bad > .icon { color: var(--bad); }
.notice.ok > .icon { color: var(--ok); }
.notice ul { padding-left: 1.1rem; margin-top: 0.2rem; }
.notice .btn-row { margin-top: 0.5rem; }
.notice > div { min-width: 0; flex: 1; }

/* disclosure with a drawn chevron */
details.disc { border: 1px solid var(--line); border-radius: var(--r-sm); margin: 0.9rem 0; background: var(--bg); }
details.disc > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; padding: 0.7rem 0.75rem; min-height: var(--btn-h); font-weight: 650; }
details.disc > summary::-webkit-details-marker { display: none; }
details.disc > summary .chev { transition: transform 0.15s; color: var(--silver, var(--muted)); }
details.disc[open] > summary .chev { transform: rotate(180deg); }
details.disc > .disc-body { padding: 0 0.75rem 0.85rem; }

/* tabs (segmented) */
.tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border: 1.5px solid var(--line); border-radius: var(--r-sm); overflow: hidden; margin-bottom: 0.9rem; background: var(--card); position: sticky; top: 64px; z-index: 5; }
.tab { min-height: var(--btn-h); border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 0.83rem; font-weight: 700; padding: 0.35rem 0.25rem; line-height: 1.1; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.tab + .tab { border-left: 1px solid var(--line); }
/* v0.2.020 (S7): active tab = soft fill + inset underline, no border fighting the rounded corners */
.tab.active { color: var(--text); background: var(--bg); box-shadow: inset 0 -2px 0 var(--accent); }
.tab:active { background: var(--bg); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* stat tiles */
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.55rem; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tile { background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.6rem 0.7rem; display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.tile span { font-size: 0.78rem; color: var(--muted); font-weight: 600; }
.tile b { font-size: 1.35rem; line-height: 1.2; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.tile b.sm { font-size: 1.02rem; }
.tile small { font-size: 0.76rem; color: var(--muted); }
.tile.low { border-color: var(--warn); } .tile.low b { color: var(--warn); }
.tile.over { border-color: var(--bad); } .tile.over b { color: var(--bad); }
.tile.inc b { font-size: 1.02rem; color: var(--warn); }
.reminders { list-style: none; display: flex; flex-direction: column; gap: 0.4rem; }
.reminders li a, .reminders li > span { display: flex; align-items: center; gap: 0.6rem; min-height: 44px; padding: 0.5rem 0.7rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--bg); color: var(--text); text-decoration: none; font-weight: 550; }
.reminders .icon { color: var(--accent); }
.reminders li.bad .icon { color: var(--bad); }
.reminders li.ok .icon { color: var(--ok); }
.reminders .go { margin-left: auto; color: var(--silver, var(--muted)); }

/* ---------- HOS ---------- */
.now-card { background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.8rem; }
.now-st { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.35rem 0.5rem; margin-bottom: 0.6rem; }
.now-st b { font-size: 1.12rem; }
.pill { display: inline-flex; align-items: center; justify-content: center; min-width: 2.4rem; font-size: 0.72rem; font-weight: 800; padding: 0.12rem 0.45rem; border-radius: 999px; border: 1.5px solid var(--accent); color: var(--text); letter-spacing: 0.03em; }
.duty-grid { display: grid; grid-template-columns: repeat(2, var(--btn-w)); justify-content: center; gap: 0.5rem; margin: 0.75rem 0 0.25rem; }
@media (min-width: 720px) { .duty-grid { grid-template-columns: repeat(4, var(--btn-w)); } }
.date-nav { display: flex; align-items: center; justify-content: center; gap: 0.5rem; margin-bottom: 0.6rem; }
.date-nav input { width: 11rem; flex: none; text-align: center; }
.day-head { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 0.4rem; text-align: center; margin-bottom: 0.25rem; }
.day-head h3 { font-size: 1.05rem; }
.graph-wrap { border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--card); overflow-x: auto; overflow-y: hidden; margin: 0.6rem 0 0.25rem; -webkit-overflow-scrolling: touch; }
.graph-wrap.zoom .hos-svg { width: 980px; max-width: none; }
.graph-tools { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; flex-wrap: wrap; }
.hos-svg { display: block; width: 100%; height: auto; user-select: none; -webkit-user-select: none; }
.hos-svg.edit { touch-action: pan-y; cursor: crosshair; }
.hos-svg .bgr { fill: var(--card); }
.hos-svg .row { fill: none; stroke: var(--text); stroke-width: 1.2; }
.hos-svg .row.alt { fill: color-mix(in srgb, var(--text) 3%, transparent); }
.hos-svg .hr { stroke: var(--text); stroke-width: 0.9; opacity: 0.55; }
.hos-svg .tk { stroke: var(--text); stroke-width: 0.8; opacity: 0.6; }
.hos-svg .tk.half { opacity: 0.8; }
.hos-svg text { fill: var(--text); font-family: system-ui, -apple-system, sans-serif; }
.hos-svg .hl { font-size: 13px; font-weight: 700; text-anchor: middle; }
.hos-svg .hl.mid { font-size: 10px; }
.hos-svg .rl { font-size: 14px; font-weight: 800; }
.hos-svg .rl2 { font-size: 10px; fill: var(--muted); }
.hos-svg .tot { font-size: 14px; font-weight: 800; text-anchor: end; font-variant-numeric: tabular-nums; }
.hos-svg .tot.all { fill: var(--muted); font-size: 12px; }
.hos-svg .duty { fill: none; stroke: var(--duty); stroke-width: 4; stroke-linejoin: round; stroke-linecap: round; }
.hos-svg .nowl { stroke: var(--blue); stroke-width: 2; stroke-dasharray: 4 3; }
.hos-svg .sel { fill: var(--accent); opacity: 0.28; }
.hos-svg .evd { fill: var(--duty); }
@media (max-width: 600px) { .hos-svg.fit .odd { display: none; } }
/* paper mode: Inspection Mode, Last 8 Days, PDF look */
.paper, .paper .graph-wrap { background: #fff !important; color: #000; }
.hos-svg.paper .bgr { fill: #fff; }
.hos-svg.paper .row, .hos-svg.paper .hr, .hos-svg.paper .tk { stroke: #000; }
.hos-svg.paper text { fill: #000; }
.hos-svg.paper .rl2, .hos-svg.paper .tot.all { fill: #333; }
.hos-svg.paper .duty { stroke: #000; stroke-width: 3.5; }
.hos-svg.paper .evd { fill: #000; }
.totals-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.3rem 1rem; font-size: 0.88rem; margin: 0.4rem 0; }
.totals-row b { font-variant-numeric: tabular-nums; }
.recap-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.45rem; }
@media (min-width: 640px) { .recap-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ev-time { font-variant-numeric: tabular-nums; }
.cert-box { border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.75rem; margin-top: 0.9rem; text-align: center; background: var(--bg); }
.cert-box .sig-img { height: 44px; background: #fff; border-radius: 4px; padding: 2px 6px; }
.sig-typed { font-family: "Brush Script MT", "Segoe Script", "Snell Roundhand", cursive; font-size: 1.5rem; }
.sign-pad { width: 100%; max-width: 560px; height: 150px; background: #fff; border: 1.5px solid var(--line); border-radius: var(--r-sm); touch-action: none; display: block; margin: 0 auto; }
.status-strip { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 0.25rem; margin: 0.25rem 0 0.5rem; }
.status-strip .d { display: flex; flex-direction: column; align-items: center; gap: 0.15rem; font-size: 0.68rem; color: var(--muted); font-weight: 600; min-width: 0; }
.dot { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--line); display: inline-block; flex: none; }
.dot.certified { background: var(--ok); border-color: var(--ok); }
.dot.unsigned, .dot.recertify { background: var(--warn); border-color: var(--warn); }
.dot.missing { background: transparent; border-color: var(--bad); border-style: dashed; }
.dot.today { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--blue); }
.legend { display: flex; flex-wrap: wrap; gap: 0.3rem 0.9rem; font-size: 0.78rem; color: var(--muted); justify-content: center; }
.legend span { display: inline-flex; align-items: center; gap: 0.3rem; }
.legend .dot { width: 12px; height: 12px; }
.board { display: flex; flex-direction: column; gap: 0.55rem; }
.board-row { border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.6rem 0.7rem; background: var(--bg); }
.board-row .top { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.35rem; }
.board-row .top > div { min-width: 0; overflow-wrap: anywhere; }
.state-rows { display: flex; flex-direction: column; gap: 0.4rem; }
.state-row { display: grid; grid-template-columns: 5.5rem minmax(0, 1fr) var(--btn-h); gap: 0.4rem; }

/* photos */
.thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 6px; border: 1px solid var(--line); cursor: zoom-in; vertical-align: middle; background: var(--bg); flex: none; }
.photo-missing { cursor: default; opacity: 0.4; }
.thumb-row { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.4rem; }
.thumb-card { display: flex; flex-direction: column; gap: 0.2rem; max-width: 120px; font-size: 0.78rem; }
.receipt-row { display: flex; gap: 0.7rem; align-items: center; min-width: 0; }
.day-group { margin-bottom: 0.9rem; }
.day-group > h4 { font-size: 0.9rem; color: var(--muted); margin-bottom: 0.35rem; }
.maint-items { padding-left: 1.1rem; margin-top: 0.3rem; }
.maint-items li { margin: 0.2rem 0; }
.maint-row { display: grid; grid-template-columns: minmax(0, 1fr) var(--btn-h) var(--btn-h); gap: 0.4rem; align-items: center; margin-bottom: 0.45rem; }
.maint-row .pv-mini { grid-column: 1 / -1; display: none; }
.maint-row .pv-mini.show { display: flex; align-items: center; gap: 0.5rem; }
.maint-row .pv-mini img { width: 56px; height: 56px; object-fit: cover; border-radius: 6px; }
.maint-row input[type="file"] { display: none; }
.doc-cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.75rem; }
@media (min-width: 640px) { .doc-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.doc-card { border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.85rem; background: var(--bg); display: flex; flex-direction: column; gap: 0.6rem; min-width: 0; }
.doc-card h3 { display: flex; align-items: center; gap: 0.5rem; justify-content: space-between; }
.doc-photo { display: flex; justify-content: center; }
.doc-photo .thumb { width: 120px; height: 80px; }

/* toast + sheets */
/* v0.2.020 (E9): toasts drop in under the header; swipe up to dismiss */
.toast-box { position: fixed; left: 50%; top: calc(4.4rem + env(safe-area-inset-top)); transform: translateX(-50%); z-index: 70; display: flex; flex-direction: column; gap: 0.5rem; width: min(520px, 94vw); pointer-events: none; }
.toast { touch-action: pan-x; transition: transform 0.15s, opacity 0.15s; pointer-events: auto; background: var(--text); color: var(--card); border-radius: var(--radius); padding: 0.7rem 0.85rem; display: flex; gap: 0.75rem; align-items: center; justify-content: space-between; box-shadow: var(--shadow); font-size: 0.93rem; }
.toast .btn { width: auto; min-width: 5.5rem; border-color: var(--card); color: var(--card); }
.toast .btn:active { background: var(--card); color: var(--text); }
.sheet-overlay { position: fixed; inset: 0; background: rgba(5, 8, 14, 0.55); z-index: 50; display: flex; align-items: flex-end; justify-content: center; padding: 0.6rem; padding-bottom: calc(0.6rem + env(safe-area-inset-bottom)); }
@media (min-width: 600px) { .sheet-overlay { align-items: center; } }
.sheet { width: 100%; max-width: 540px; max-height: 92vh; max-height: 92dvh; overflow-y: auto; overscroll-behavior: contain; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1rem; }
.sheet.wide { max-width: 860px; }
.sheet h3 { margin-bottom: 0.6rem; font-size: 1.1rem; }
.sheet .msg { font-size: 1rem; margin-bottom: 0.25rem; max-width: none; border: 0; padding: 0; background: none; align-self: auto; } /* v0.2.020 (S8): lines up with the title */
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.6rem; }
.sheet-head h3 { margin: 0; }
body.sheet-open { overflow: hidden; }
.checklist { display: flex; flex-direction: column; gap: 0.15rem; }
.check-row { border-bottom: 1px solid var(--line); padding: 0.2rem 0 0.35rem; display: flex; flex-direction: column; gap: 0.3rem; }
.check-row .note-line { display: none; gap: 0.4rem; }
.check-row.bad .note-line { display: flex; }
.check-row.bad .check { color: var(--bad); }
.scan-box { position: relative; background: #000; border-radius: var(--r-sm); overflow: hidden; }
.scan-box video { width: 100%; display: block; max-height: 60vh; object-fit: cover; }
.scan-aim { position: absolute; left: 8%; right: 8%; top: 40%; height: 20%; border: 2px solid #fff; border-radius: 6px; box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.25); }

/* home */
.hero { text-align: center; padding: 1.5rem 0.5rem 1rem; }
.hero .tagline { font-size: 1.05rem; color: var(--muted); margin-bottom: 0.5rem; }
.hello { font-size: 1.15rem; font-weight: 700; margin-bottom: 0.15rem; }

/* read-only day views (Last 8 Days, Inspection Mode, admin view) */
.hi-day { border-top: 2px solid var(--line); padding-top: 0.9rem; margin-top: 0.9rem; scroll-margin-top: 6rem; }
.hi-day h3 { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: baseline; }
.hi-day h4 { margin: 0.7rem 0 0.2rem; font-size: 0.95rem; }
.hi-dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0.35rem 1rem; margin: 0.5rem 0; }
.hi-dl dt { font-size: 0.78rem; color: var(--muted); } .hi-dl dd { font-weight: 600; overflow-wrap: anywhere; }
.hi-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.35rem; margin: 0.6rem 0; }
.hi-nav .chip.none { opacity: 0.55; border-style: dashed; }
.hos-hist { padding-left: 1.2rem; font-size: 0.9rem; }
.hos-inspect { position: fixed; inset: 0; z-index: 55; background: var(--card); overflow-y: auto; padding: 0 0.9rem 2rem; padding-top: env(safe-area-inset-top); }
.hi-top { position: sticky; top: 0; background: var(--card); border-bottom: 2px solid var(--accent); padding: 0.6rem 0; z-index: 1; }
.hi-top h2 { font-size: 1.02rem; text-align: center; }
.hi-top .meta { text-align: center; }
.hi-top .btn-row { margin-top: 0.4rem; }
.hi-body { max-width: 900px; margin: 0 auto; }

/* footer, changelog */
.footer { text-align: center; padding: 1rem; color: var(--muted); font-size: 0.86rem; border-top: 1px solid var(--line); }
.powered { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.3rem; margin: 0.55rem 0 0.15rem; font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; }
.powered .cinder-logo { height: 48px; width: auto; opacity: 0.85; flex: none; }
.powered .cinder-logo.dark { display: none; }
[data-theme="dark"] .powered .cinder-logo.light { display: none; }
[data-theme="dark"] .powered .cinder-logo.dark { display: block; }
.build-number { margin-top: 0.25rem; font-size: 0.74rem; opacity: 0.7; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.changelog { display: flex; flex-direction: column; gap: 1.1rem; }
.changelog-entry { border-left: 3px solid var(--accent); padding-left: 0.85rem; }
.changelog-version { font-weight: 800; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.changelog-date { font-size: 0.82rem; color: var(--muted); margin-bottom: 0.25rem; }
.changelog-entry ul { padding-left: 1.1rem; }
.audit-list .list-item { padding: 0.5rem 0.65rem; font-size: 0.9rem; }

/* v0.0.031 additions */
.icon-btn.on { border-color: var(--accent); color: var(--accent); }
.icon-btn.on svg { fill: currentColor; }
.icon-btn.busy { opacity: 0.6; pointer-events: none; }
fieldset.card { min-width: 0; }
fieldset.card:disabled input, fieldset.card:disabled select, fieldset.card:disabled textarea { opacity: 0.75; }
button.d { background: none; border: 0; padding: 0.15rem 0; font: inherit; cursor: pointer; color: inherit; }
.status-strip .d .dot { width: 18px; height: 18px; }
.invite-link { font-family: ui-monospace, Menlo, monospace; font-size: 0.8rem; overflow-wrap: anywhere; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.5rem; }
.notice ul { padding-left: 1.1rem; margin-top: 0.25rem; }

/* v0.0.032 additions */
.sync-note { margin: 0; padding: 0.3rem 0.9rem; font-size: 0.8rem; font-weight: 600; text-align: center; color: var(--warn); background: var(--warn-bg); border-bottom: 1px solid var(--line); }
.sync-note[hidden] { display: none; }
.sync-note.ok { color: var(--ok); background: var(--ok-bg); }
/* circle avatar: photo center-cropped, initials when there's none */
.avatar { position: relative; width: 44px; height: 44px; border-radius: 50%; overflow: hidden; flex: none; display: inline-flex; align-items: center; justify-content: center;
  background: var(--info-bg); color: var(--brand); border: 1.5px solid var(--line); font-weight: 800; font-size: 0.95rem; letter-spacing: 0.02em; }
[data-theme="dark"] .avatar { color: var(--accent); }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.avatar img:not([src]), .avatar img.photo-missing { display: none; }
.avatar.lg { width: 76px; height: 76px; font-size: 1.5rem; border-width: 2px; border-color: var(--accent); }
.avatar.sm { width: 38px; height: 38px; font-size: 0.82rem; }
.avatar.parked { color: var(--muted); background: var(--bg); }
.avatar .icon { width: 20px; height: 20px; }
.profile-top { display: flex; align-items: center; gap: 0.85rem; min-width: 0; }
.profile-top .pt-text { min-width: 0; flex: 1; }
.pt-name { font-size: 1.3rem; font-weight: 750; line-height: 1.2; overflow-wrap: anywhere; }
.pt-since { display: flex; align-items: center; gap: 0.35rem; margin-top: 0.1rem; }
.icon-btn.mini { width: 30px; height: 30px; min-width: 30px; }
.icon-btn.mini .icon { width: 16px; height: 16px; }
#profilePhotoBox .btn-grid { margin: 0.8rem 0 0.4rem; }
.board-row .who { display: flex; align-items: center; gap: 0.6rem; min-width: 0; flex: 1; }
.board-row .who > div { min-width: 0; overflow-wrap: anywhere; }
/* collapsible headers (Audit Trail, Key Addresses groups) */
.collapse-head { display: flex; align-items: center; gap: 0.5rem; width: 100%; background: none; border: 0; padding: 0.2rem 0; color: var(--text); font: inherit; text-align: left; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.collapse-head h2 { margin: 0; flex: 1; }
.collapse-head > span:first-child { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.collapse-head .chev, .fleet-sum .chev { color: var(--silver, var(--muted)); transition: transform 0.15s; }
.collapse-head[aria-expanded="true"] .chev, .fleet-sum[aria-expanded="true"] .chev { transform: rotate(180deg); }
#auditBody { margin-top: 0.6rem; }
.pager { display: flex; align-items: center; justify-content: center; gap: 0.6rem; margin-top: 0.75rem; flex-wrap: wrap; text-align: center; }
.pager:empty { display: none; }
/* Fleet */
.fleet-row { border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--bg); min-width: 0; }
.fleet-row.open { border-color: var(--accent); }
.fleet-sum { display: flex; align-items: center; gap: 0.65rem; width: 100%; background: none; border: 0; padding: 0.65rem 0.7rem; font: inherit; color: var(--text); text-align: left; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.fs-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.fs-text b { overflow-wrap: anywhere; }
.meta.sm { font-size: 0.76rem; }
.fleet-body { padding: 0 0.75rem 0.75rem; border-top: 1px solid var(--line); }
.fb-sec { padding-top: 0.7rem; }
.fb-sec h4 { display: flex; align-items: center; gap: 0.4rem; font-size: 0.95rem; margin-bottom: 0.3rem; }
.fb-sec h4 .icon { color: var(--accent); width: 18px; height: 18px; }
.fb-sec dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0.25rem 1rem; }
.fb-row dt { font-size: 0.76rem; color: var(--muted); }
.fb-row dd { font-weight: 600; overflow-wrap: anywhere; }
.fb-photo { display: flex; align-items: center; gap: 0.6rem; margin-top: 0.5rem; }
.fleet-body .notice { flex-direction: column; align-items: stretch; }
.fleet-body .notice .btn-grid { margin: 0.4rem 0 0; }
/* Key Addresses */
.search-box { display: flex; align-items: center; gap: 0.4rem; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--field); padding: 0 0.6rem; margin-bottom: 0.8rem; }
.search-box .icon { color: var(--silver, var(--muted)); }
.search-box input { border: 0; background: transparent; padding-left: 0.2rem; box-shadow: none !important; }
.search-box:focus-within { border-color: var(--brand); }
.addr-list { display: flex; flex-direction: column; gap: 0.5rem; min-width: 0; }
.addr-state { border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.45rem 0.7rem; background: var(--bg); min-width: 0; }
.collapse-head.lvl1 { font-weight: 750; font-size: 1.05rem; min-height: 36px; }
.collapse-head.lvl2 { font-weight: 650; font-size: 0.95rem; min-height: 34px; color: var(--brand); }
[data-theme="dark"] .collapse-head.lvl2 { color: var(--accent); }
.addr-biz { border-top: 1px solid var(--line); padding-top: 0.25rem; margin-top: 0.25rem; }
.addr-items { display: flex; flex-direction: column; gap: 0.4rem; padding: 0.2rem 0 0.4rem 0.6rem; }
.addr-item { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.5rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 0.55rem 0.65rem; min-width: 0; }
.ai-text { min-width: 0; flex: 1; }
.ai-label { font-weight: 700; }
.ai-addr { display: inline-flex; align-items: flex-start; gap: 0.3rem; margin-top: 0.15rem; overflow-wrap: anywhere; font-weight: 550; }
.ai-addr .icon { width: 16px; height: 16px; margin-top: 2px; }
.ai-note { font-size: 0.8rem; color: var(--muted); margin-top: 0.2rem; overflow-wrap: anywhere; }
.addr-group[hidden], .addr-items[hidden], .fleet-body[hidden], #auditBody[hidden] { display: none !important; }
.fb-line { font-size: 0.95rem; margin-top: 0.15rem; }

/* v0.1.001 additions: compact document cards */
.doc-card.compact { gap: 0.45rem; }
.doc-card .card-head { margin-bottom: 0; flex-wrap: nowrap; }
.doc-card .card-head h3 { min-width: 0; overflow-wrap: anywhere; }
.dc-tools { display: flex; align-items: center; gap: 0.45rem; flex: none; }
.dc-sum { display: flex; align-items: center; gap: 0.7rem; min-width: 0; font-size: 0.95rem; }
.dc-sum .thumb { width: 56px; height: 56px; }
.dc-nophoto { width: 56px; height: 56px; display: inline-flex; align-items: center; justify-content: center; border: 1px dashed var(--line); border-radius: var(--r-sm); font-size: 0.72rem; flex: none; }

/* ---- v0.2.007: inbox, chat, alerts, demo ---- */
.inbox-btn { position: relative; }
.demo-banner { border-bottom: 1px solid var(--accent); padding: 0.25rem 0.75rem; min-height: 0; font-size: 0.8rem; justify-content: center; text-align: center; } /* v0.2.020 (E4): thin strip, Exit is in the drawer */
.chat-head { align-items: center; gap: 0.5rem; }
.chat-title { flex: 1; min-width: 0; text-align: center; }
.chat-title h2 { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.msg-list { display: flex; flex-direction: column; gap: 0.5rem; margin: 0.6rem 0; }
.msg { max-width: 85%; align-self: flex-start; border: 1px solid var(--border); border-radius: var(--r-sm); padding: 0.5rem 0.7rem; background: var(--surface); }
.msg.mine { align-self: flex-end; border-color: var(--brand); }
.msg.system { align-self: center; border: none; background: none; padding: 0.1rem; }
.msg .body { white-space: pre-wrap; overflow-wrap: anywhere; }
.msg .msg-foot { display: flex; gap: 0.5rem; align-items: center; justify-content: space-between; margin-top: 0.25rem; }
.msg .msg-foot button { background: none; border: none; color: var(--muted, inherit); font: inherit; font-size: 0.8rem; text-decoration: underline; cursor: pointer; padding: 0; }
.msg.waiting { opacity: 0.7; border-style: dashed; }
.alert-item.pinned { border-left: 4px solid var(--accent); padding-left: 0.6rem; }
.alert-item .pin-flag { color: var(--accent); display: inline-flex; align-items: center; gap: 0.2rem; font-weight: 750; }
.alert-item .body { white-space: pre-wrap; overflow-wrap: anywhere; }
.alert-photos { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.4rem; }
.alert-photos img { width: 96px; height: 96px; object-fit: cover; border-radius: var(--r-sm); border: 1px solid var(--border); }
.chat-row { display: flex; width: 100%; text-align: left; background: none; border: none; border-bottom: 1px solid var(--border); padding: 0.6rem 0; color: inherit; font: inherit; cursor: pointer; justify-content: space-between; gap: 0.5rem; }
.chat-row .unread { min-width: 22px; height: 22px; border-radius: 11px; background: var(--accent); color: var(--on-accent, #00204F); font-weight: 750; font-size: 0.8rem; display: inline-flex; align-items: center; justify-content: center; padding: 0 6px; }
.driver-contact .btn-row { justify-content: center; }

/* v0.2.009: tappable Today tiles (open Needs Attention) */
.tile.tap { cursor: pointer; transition: border-color 0.15s, background 0.15s; }
.tile.tap:hover { border-color: var(--accent); }
.tile.tap:active { background: var(--accent); }
.tile.tap:active span, .tile.tap:active b, .tile.tap:active small { color: var(--tap-text, var(--text)); }
.tile.tap:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
#attnChips { margin: 0.6rem 0; }

/* v0.2.020 (S4): the last leftover button in a 2-column grid sits centered at the normal width */
.btn-grid > :last-child:nth-child(odd), .duty-grid > :last-child:nth-child(odd) { grid-column: 1 / -1; justify-self: center; }
@media (min-width: 720px) { .btn-grid.four > :last-child:nth-child(odd) { grid-column: auto; justify-self: stretch; } }
@media (max-width: 639px) { .tiles > :last-child:nth-child(odd) { grid-column: 1 / -1; justify-self: center; width: calc(50% - 0.275rem); } }
/* v0.2.020 (O5) */
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.8rem; }
/* v0.2.020 (S2): hints get a little more contrast */
.hint { color: color-mix(in srgb, var(--muted) 75%, var(--text)); }
/* v0.2.020 (O2/S3): Drivers rows, expanded actions wrap at normal button width */
.driver-contact summary { display: flex; align-items: center; gap: 0.5rem; }
.driver-contact summary .meta { margin-top: 0.15rem; }
.driver-more { padding: 0.6rem 0 0.2rem; display: grid; gap: 0.5rem; }
.driver-more .btn-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 26rem; margin: 0 auto; width: 100%; }
/* v0.2.020 (S1/O4): Transports list as thin sheet-like rows */
.sheet-row { display: flex; align-items: center; gap: 0.5rem; padding: 0.4rem 0.2rem; border-bottom: 1px solid var(--border); }
.sheet-row:first-of-type { border-top: 1px solid var(--border); }
.sheet-row .sr-main { flex: 1; min-width: 0; font-size: 0.9rem; }
.sheet-row .sr-main .meta { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet-row .row-actions { flex: none; display: flex; gap: 0.3rem; }
/* v0.2.022 (L-10, L-11): Recent Transports thin spreadsheet rows; tap a row for details */
.xtable { border-top: 1px solid var(--border); }
.xrow { display: grid; grid-template-columns: 2.6rem minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) auto; align-items: center; gap: 0.4rem; padding: 0.2rem 0.2rem; min-height: 34px; border-bottom: 1px solid var(--border); font-size: 0.82rem; cursor: pointer; }
.xrow > * { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.xrow:nth-child(4n+1) { background: color-mix(in srgb, var(--line) 22%, transparent); }
.xrow .x-date { color: var(--muted); }
.xrow .x-city .icon { width: 13px; height: 13px; vertical-align: -2px; }
.xrow[aria-expanded="true"] { background: color-mix(in srgb, var(--line) 45%, transparent); }
.xmore { padding: 0.3rem 0.4rem 0.45rem 3rem; font-size: 0.8rem; color: var(--muted); border-bottom: 1px solid var(--border); }
#vinCard .card-head .btn { flex: 0 0 auto; }
/* v0.2.023: site variants (skins.js SITE). tencenttowing.com shows .site-tct; cindertransport.com shows .site-cinder. */
.site-cinder { display: none !important; }
:root[data-site="cinder"] .site-cinder { display: block !important; }
:root[data-site="cinder"] p.site-cinder { display: block !important; }
:root[data-site="cinder"] .site-tct { display: none !important; }
.site-links { font-size: 0.8rem; text-align: center; }
.site-links a { color: var(--muted); }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* v0.2.024 (Pass 4): Dispatch */
.jrow { grid-template-columns: 3.4rem minmax(0, 1.8fr) minmax(0, 1fr) minmax(0, 0.9fr) 3.4rem; }
.jst { font-weight: 650; }
.jst-assigned { color: var(--bad); }
.jst-acknowledged, .jst-en_route, .jst-arrived { color: var(--brand); }
.jst-completed, .jst-cancelled { color: var(--muted); }
.hours-check { display: flex; flex-direction: column; gap: 0.15rem; border: 1px solid var(--border); border-radius: 8px; padding: 0.5rem 0.7rem; font-size: 0.88rem; }
.hours-check.low { border-color: var(--accent); }
.hours-check.out { border-color: var(--bad); color: var(--bad); }
.hours-check small { color: var(--muted); }
.week-grid { display: grid; grid-template-columns: minmax(5.5rem, 1.4fr) repeat(7, minmax(0, 1fr)); gap: 2px; font-size: 0.75rem; overflow-x: auto; }
.week-grid > span { padding: 0.3rem 0.2rem; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.week-grid .wk-n { text-align: left; }
.week-grid .wk-h { color: var(--muted); line-height: 1.15; }
.wk-c { border-radius: 4px; border: 1px solid var(--border); min-height: 1.6rem; }
.wk-job { background: color-mix(in srgb, var(--brand) 22%, transparent); }
.wk-off { background: color-mix(in srgb, var(--bad) 16%, transparent); }
.myjob { border: 1px solid var(--border); border-radius: 10px; padding: 0.7rem 0.8rem; margin-bottom: 0.6rem; }
.myjob.new { border-color: var(--bad); }
.myjob-top { display: flex; justify-content: space-between; gap: 0.5rem; align-items: baseline; }
.btn.big { min-height: 56px; min-width: 12rem; font-size: 1.05rem; }
.thumbs { display: flex; gap: 0.4rem; flex-wrap: wrap; margin-top: 0.4rem; }
