@font-face { font-family: 'Work Sans'; font-weight: 400; font-display: swap; src: url(/vendor/fonts/work-sans-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'Work Sans'; font-weight: 600; font-display: swap; src: url(/vendor/fonts/work-sans-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: 'Work Sans'; font-weight: 700; font-display: swap; src: url(/vendor/fonts/work-sans-latin-700-normal.woff2) format('woff2'); }
:root { --p: #7e37d8; --pd: #5a1eb0; --bg: #f6f7fb; --ink: #23232f; --mut: #6b7486; --line: #e6e8ef; --ok: #2f9e44; --warn: #d48806; --bad: #c92a2a; }
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font-family: 'Work Sans', system-ui, sans-serif; font-size: 16px; }
button, input, select, textarea { font: inherit; color: inherit; }
.view { display: none; min-height: 100vh; padding-bottom: env(safe-area-inset-bottom); }
.view.on { display: block; }
.muted { color: var(--mut); }
.small { font-size: 13px; }
.hide { display: none !important; }
.pad { padding: 16px; max-width: 560px; margin: 0 auto; }

.login { max-width: 380px; margin: 0 auto; padding: 56px 20px; text-align: center; }
.login .logo { width: 72px; height: 72px; }
.login h1 { color: var(--p); margin: 12px 0 4px; font-size: 26px; }
.login form { text-align: left; margin-top: 28px; }

label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 14px; }
input, select, textarea { display: block; width: 100%; margin-top: 6px; padding: 13px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; font-size: 17px; font-weight: 500; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--p); box-shadow: 0 0 0 3px rgba(126, 55, 216, .15); }
fieldset { border: 0; padding: 0; margin: 0 0 14px; }
legend { font-weight: 600; font-size: 14px; margin-bottom: 6px; padding: 0; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.btn { display: block; width: 100%; padding: 16px; border: 0; border-radius: 14px; font-size: 18px; font-weight: 700; cursor: pointer; }
.btn-primary { background: var(--p); color: #fff; box-shadow: 0 8px 18px rgba(126, 55, 216, .3); }
.btn-primary:active { background: var(--pd); }
.btn:disabled { opacity: .6; }
.err { color: var(--bad); font-size: 14px; min-height: 1em; margin: 4px 0 10px; }

.top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; padding-top: calc(14px + env(safe-area-inset-top));
  background: linear-gradient(135deg, var(--p), var(--pd)); color: #fff; }
.top .nopol { font-size: 22px; font-weight: 700; }
.top .who { font-size: 13px; opacity: .85; }
.top .title { font-size: 18px; font-weight: 700; flex: 1; }
.icon-btn { background: rgba(255, 255, 255, .18); border: 0; color: #fff; width: 42px; height: 42px; border-radius: 12px; font-size: 22px; cursor: pointer; }

.sync { padding: 8px 16px; font-size: 13px; font-weight: 600; text-align: center; }
.sync.ok { background: #e9f7ec; color: #22743a; }
.sync.pending { background: #fff6e0; color: #8a5a00; }
.sync.off { background: #fdecec; color: #9b1c1c; }

.big { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; padding: 18px; margin-bottom: 12px; border-radius: 16px; border: 1.5px solid var(--line); background: #fff; cursor: pointer; box-shadow: 0 2px 10px rgba(20, 20, 60, .04); }
.big b { display: block; font-size: 18px; }
.big small { display: block; color: var(--mut); font-size: 13px; margin-top: 2px; }
.big-primary { border-color: var(--p); }
.big-ic { font-size: 30px; width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center; background: #f3ecfc; flex-shrink: 0; }

.today { margin-top: 18px; background: #fff; border-radius: 16px; padding: 14px 16px; border: 1.5px solid var(--line); }
.today-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.item { display: flex; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); align-items: center; }
.item .t { color: var(--mut); font-size: 13px; width: 44px; flex-shrink: 0; font-variant-numeric: tabular-nums; }
.item .d { flex: 1; min-width: 0; }
.item .d b { display: block; font-size: 15px; }
.item .d span { color: var(--mut); font-size: 13px; }
.item .kg { font-weight: 700; font-variant-numeric: tabular-nums; }
.tag { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; }
.tag-wait { background: #fff6e0; color: #8a5a00; }

.gps { background: #fff; border: 1.5px dashed var(--line); border-radius: 12px; padding: 10px 12px; font-size: 14px; margin-bottom: 14px; }
.gps.ok { border-color: #b9e3c3; background: #f3fbf5; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.seg button { padding: 14px 6px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; font-weight: 600; font-size: 15px; cursor: pointer; }
.seg button.on { border-color: var(--p); background: #f3ecfc; color: var(--pd); box-shadow: inset 0 0 0 1px var(--p); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: -6px 0 6px; }
.chips button { border: 1.5px solid var(--line); background: #fff; border-radius: 20px; padding: 8px 14px; font-weight: 600; font-size: 14px; cursor: pointer; }
.hint { font-size: 13px; color: var(--mut); margin: 4px 0 14px; min-height: 1em; }
.hint.warn { color: var(--warn); }
.photo input { display: none; }
.photo-box { display: flex; align-items: center; justify-content: center; min-height: 110px; border: 2px dashed #c9b3ee; border-radius: 14px; background: #faf7fe; color: var(--pd); font-size: 16px; overflow: hidden; margin-top: 6px; }
.photo-box img { width: 100%; max-height: 260px; object-fit: cover; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(120px); background: #23232f; color: #fff; padding: 12px 18px; border-radius: 12px; font-size: 15px; transition: transform .25s; max-width: 90vw; z-index: 50; }
.toast.on { transform: translateX(-50%) translateY(0); }
