@font-face { font-family: Inter; font-weight: 400; font-display: swap; src: url(/fonts/inter-400.woff2) format('woff2'); }
@font-face { font-family: Inter; font-weight: 500; font-display: swap; src: url(/fonts/inter-500.woff2) format('woff2'); }
@font-face { font-family: Inter; font-weight: 600; font-display: swap; src: url(/fonts/inter-600.woff2) format('woff2'); }
@font-face { font-family: Inter; font-weight: 700; font-display: swap; src: url(/fonts/inter-700.woff2) format('woff2'); }
@font-face { font-family: Inter; font-weight: 800; font-display: swap; src: url(/fonts/inter-800.woff2) format('woff2'); }

/* Оформление как у «Журнала рейсов»: светлый фон, белые карточки с крупным скруглением, капсулы, крупные числа */
:root {
  --bg: #f2f2f7; --card: #ffffff; --text: #1c1c1e; --hint: #8e8e93; --line: #e5e5ea;
  --blue: #007aff; --red: #ff3b30; --green: #1f9d55; --orange: #ff9500;
  --red-p: #fdecea; --blue-p: #e5f0ff; --green-p: #e6f6ec; --orange-p: #fff1dc; --gray-p: #f2f2f7;
  --shadow: 0 2px 14px rgba(0, 0, 0, 0.05);
  --glass: rgba(255, 255, 255, 0.72); --glass-line: rgba(255, 255, 255, 0.7); --glass-shadow: 0 8px 30px rgba(0, 0, 0, 0.13), inset 0 1px 0 rgba(255, 255, 255, 0.85);
}
:root[data-theme="dark"] {
  --bg: #000000; --card: #1c1c1e; --text: #ffffff; --hint: #8e8e93; --line: #38383a;
  --red-p: rgba(255, 59, 48, 0.2); --blue-p: rgba(0, 122, 255, 0.22); --green-p: rgba(31, 157, 85, 0.24); --orange-p: rgba(255, 149, 0, 0.22); --gray-p: #2c2c2e;
  --shadow: none;
  --glass: rgba(58, 58, 60, 0.62); --glass-line: rgba(255, 255, 255, 0.14); --glass-shadow: 0 8px 30px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.35 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; -webkit-font-smoothing: antialiased; }
main { padding: 22px 16px calc(100px + env(safe-area-inset-bottom)); max-width: 640px; margin: 0 auto; }

.title { font-size: 40px; font-weight: 800; letter-spacing: -1.2px; line-height: 1.1; margin: 6px 4px 0; }
.subtitle { font-size: 17px; color: var(--hint); margin: 4px 4px 20px; }
.sec { font-size: 12.5px; font-weight: 600; color: var(--hint); text-transform: uppercase; letter-spacing: 0.5px; margin: 24px 8px 8px; }

.card { background: var(--card); border-radius: 28px; padding: 20px 22px; margin-bottom: 14px; box-shadow: var(--shadow); }
.card.tight { padding: 8px 22px; }
.lbl { font-size: 13.5px; font-weight: 500; color: var(--hint); }
.big { font-size: 50px; font-weight: 800; letter-spacing: -2px; line-height: 1.05; margin: 8px 0 8px; }
.cap-text { font-size: 15px; color: var(--hint); }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 14px; }
.stat { background: var(--card); border-radius: 24px; padding: 16px 16px 14px; box-shadow: var(--shadow); min-width: 0; }
.stat .v { font-size: 22px; font-weight: 800; letter-spacing: -0.6px; margin-top: 6px; white-space: nowrap; }
.stat .c { font-size: 12px; color: var(--hint); margin-top: 4px; }
.stats.two { grid-template-columns: 1fr 1fr; }
.stats.two .stat .v { font-size: 24px; }
.red { color: var(--red); } .green { color: var(--green); } .orange { color: var(--orange); } .blue { color: var(--blue); } .muted { color: var(--hint); }

.trow { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.trow:last-child { border-bottom: none; }
.trow .d { font-size: 17px; font-weight: 700; letter-spacing: -0.3px; }
.trow .s { font-size: 12.5px; color: var(--hint); margin-top: 2px; }
.trow .r { text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }
.trow .sum { font-size: 17px; font-weight: 700; letter-spacing: -0.3px; white-space: nowrap; }
.trow .w { font-size: 13px; color: var(--hint); white-space: nowrap; }

.cap { display: inline-flex; align-items: center; justify-content: center; min-width: 64px; padding: 5px 12px; border-radius: 999px; font-size: 14.5px; font-weight: 700; white-space: nowrap; background: var(--gray-p); color: var(--hint); }
.cap.red-s { background: var(--red); color: #fff; } .cap.blue-s { background: var(--blue); color: #fff; }
.cap.red-p { background: var(--red-p); color: var(--red); } .cap.blue-p { background: var(--blue-p); color: var(--blue); }
.cap.green { background: var(--green-p); color: var(--green); } .cap.orange { background: var(--orange-p); color: var(--orange); }

label { display: block; font-size: 13px; font-weight: 500; color: var(--hint); margin: 14px 4px 6px; }
input, select, textarea { width: 100%; max-width: 100%; min-width: 0; -webkit-appearance: none; appearance: none; height: 46px; padding: 0 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); color: var(--text); font: inherit; font-size: 16px; }
textarea { height: 96px; padding: 12px 14px; resize: vertical; }
.two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
/* Выбор даты: два раздельных блока «С» и «По», не вылезают за экран на iPhone */
.datepair { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; margin-bottom: 14px; }
.datebox { background: var(--card); border-radius: 22px; padding: 12px 16px 8px; box-shadow: var(--shadow); min-width: 0; overflow: hidden; }
.card .datebox { background: var(--gray-p); box-shadow: none; }
.datebox .lbl { font-size: 12.5px; }
.datebox input { display: block; height: 34px; margin-top: 2px; padding: 0; border: none; border-radius: 0; background: transparent; font-size: 18px; font-weight: 700; letter-spacing: -0.3px; text-align: left; line-height: 34px; }
input[type="date"]::-webkit-date-and-time-value, input[type="time"]::-webkit-date-and-time-value { text-align: left; }
input[type="date"], input[type="time"] { text-align: left; }
button { font: inherit; font-size: 16px; font-weight: 600; border: none; border-radius: 16px; height: 50px; padding: 0 16px; background: var(--blue); color: #fff; width: 100%; margin-top: 14px; }
button.sec2 { background: var(--card); color: var(--blue); border: 1px solid var(--line); box-shadow: var(--shadow); }
button:disabled { opacity: 0.55; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.chip { height: auto; padding: 8px 14px; border-radius: 999px; background: var(--gray-p); color: var(--text); font-size: 14px; font-weight: 500; width: auto; margin: 0; }
.chip.on { background: var(--blue); color: #fff; }
.seg { display: flex; background: var(--gray-p); border-radius: 14px; padding: 3px; gap: 3px; }
.seg button { margin: 0; height: 38px; font-size: 14.5px; background: transparent; color: var(--text); font-weight: 500; border-radius: 11px; }
.seg button.on { background: var(--card); font-weight: 700; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1); }
.bar { height: 12px; border-radius: 6px; background: var(--gray-p); overflow: hidden; margin: 10px 0 8px; }
.bar > i { display: block; height: 100%; background: var(--green); border-radius: 6px; }
.bar.low > i { background: var(--red); }
.hl { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.hl:last-child { border-bottom: none; }
.hl .a { font-weight: 600; } .hl .b { font-weight: 700; text-align: right; white-space: nowrap; }
.hl .s { font-size: 12.5px; color: var(--hint); font-weight: 400; margin-top: 1px; }
pre { white-space: pre-wrap; word-break: break-word; font: inherit; font-size: 14px; line-height: 1.5; margin: 0; }
.legend { font-size: 13px; color: var(--hint); line-height: 1.5; margin: 6px 6px 0; }

/* Нижняя панель как в iOS: плавающая капсула из стекла с контурными иконками */
nav { position: fixed; left: 0; right: 0; bottom: calc(12px + env(safe-area-inset-bottom)); width: calc(100% - 28px); max-width: 520px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 2px; padding: 6px; border-radius: 999px; background: var(--glass); -webkit-backdrop-filter: blur(26px) saturate(180%); backdrop-filter: blur(26px) saturate(180%); border: 1px solid var(--glass-line); box-shadow: var(--glass-shadow); }
nav button { flex: 1; height: 48px; margin: 0; padding: 0; border-radius: 999px; background: transparent; color: var(--text); display: flex; align-items: center; justify-content: center; transition: background 0.18s, color 0.18s; }
nav button svg { width: 27px; height: 27px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
nav button.on { color: var(--blue); background: var(--blue-p); }
#toast { position: fixed; left: 50%; bottom: calc(88px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: rgba(0, 0, 0, 0.84); color: #fff; padding: 12px 18px; border-radius: 16px; max-width: 90%; opacity: 0; pointer-events: none; transition: opacity 0.2s; text-align: center; }
#toast.show { opacity: 1; }
.center { text-align: center; padding: 34px 10px; color: var(--hint); }
@media (max-width: 380px) { .big { font-size: 42px; } .title { font-size: 34px; } .stat .v { font-size: 19px; } }

/* Единый стиль с отчётом «Журнал рейсов» (PNG/PDF): карточка клиента и цены, таблица рейсов, капсулы, легенда */
.cardrow { display: flex; align-items: center; background: var(--card); border-radius: 28px; padding: 18px 22px; margin-bottom: 14px; box-shadow: var(--shadow); }
.cardrow .l { flex: 1; min-width: 0; }
.cardrow .div { width: 1px; align-self: stretch; background: var(--line); margin: 0 18px; }
.cardrow .rr { width: 42%; min-width: 0; }
.cardrow .v { font-size: 19px; font-weight: 700; letter-spacing: -0.3px; margin-top: 6px; overflow-wrap: anywhere; }
.stats:not(.two) .stat .lbl { min-height: 2.7em; }
.jt { background: var(--card); border-radius: 28px; padding: 20px 14px 6px; box-shadow: var(--shadow); margin-bottom: 14px; }
.jt-row { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.85fr) minmax(0, 0.85fr) 64px minmax(0, 1.1fr); column-gap: 4px; align-items: center; }
.jt-head > div { white-space: nowrap; }
.jt-head { padding: 0 0 10px; border-bottom: 1px solid var(--line); font-size: 10px; font-weight: 500; color: var(--hint); align-items: end; line-height: 1.2; }
.jt-item { padding: 11px 0; border-bottom: 1px solid var(--line); }
.jt-item:last-child { border-bottom: none; }
.jt .c-plate, .jt .c-brand, .jt .long, .jt .x-wide { display: none; }
.jt .d { font-size: 14px; font-weight: 700; letter-spacing: -0.2px; white-space: nowrap; }
.jt .s { font-size: 11px; color: var(--hint); margin-top: 1px; white-space: nowrap; }
.jt .jt-extra { font-size: 11px; color: var(--hint); margin-top: 4px; overflow-wrap: anywhere; line-height: 1.3; }
.jt .r { text-align: right; } .jt .c { text-align: center; }
.jt .n { font-size: 13.5px; font-weight: 500; white-space: nowrap; } .jt .sum { font-size: 13.5px; font-weight: 700; white-space: nowrap; }
.jt .cap { min-width: 54px; font-size: 12.5px; padding: 4px 6px; }
.legend-row { display: flex; align-items: center; gap: 12px; margin: 14px 6px 0; font-size: 13.5px; color: var(--hint); }
.swatch { width: 46px; height: 24px; border-radius: 999px; background: var(--red); flex: none; }
@media (min-width: 560px) {
  .jt { padding: 24px 22px 12px; }
  .jt-row { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.05fr) minmax(0, 1.1fr) minmax(0, 1.05fr) minmax(0, 0.85fr) minmax(0, 0.9fr) minmax(0, 1fr); column-gap: 8px; }
  .jt-item { padding: 12px 0; }
  .jt .c-plate, .jt .c-brand, .jt .long, .jt .x-wide { display: block; } .jt .short, .jt .x-narrow { display: none; }
  .jt-head { font-size: 11.5px; } .jt .d { font-size: 15.5px; } .jt .s, .jt .jt-extra { font-size: 12px; }
  .jt .n, .jt .sum { font-size: 15px; } .jt .cap { min-width: 60px; font-size: 14px; padding: 4px 10px; }
}

/* Исправление рейсов: нажимаемые строки, недавние записи бота, карточка рейса снизу */
.jt-item.tap { cursor: pointer; border-radius: 12px; }
.jt-item.tap:active { background: var(--gray-p); }
.jt .botmark { color: var(--blue); font-weight: 600; }
.recent { padding: 12px 0; border-bottom: 1px solid var(--line); }
.recent:last-child { border-bottom: none; }
.recent .a { font-size: 15.5px; font-weight: 700; letter-spacing: -0.2px; }
.recent .s { font-size: 12.5px; color: var(--hint); margin-top: 2px; }
.recent .btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.recent .btns button { height: 40px; margin-top: 10px; font-size: 14.5px; border-radius: 12px; }
button.danger { background: var(--card); color: var(--red); border: 1px solid var(--line); box-shadow: var(--shadow); }
.small { font-size: 12.5px; margin: 0 8px 4px; }
.sheet-bg { position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, 0.38); display: flex; align-items: flex-end; justify-content: center; }
.sheet { background: var(--bg); width: 100%; max-width: 640px; max-height: 92vh; overflow-y: auto; -webkit-overflow-scrolling: touch; border-radius: 28px 28px 0 0; padding: 10px 16px calc(24px + env(safe-area-inset-bottom)); }
.sheet .grab { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 12px; }
.sheet-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin: 0 4px 14px; }
.sheet-title { font-size: 28px; font-weight: 800; letter-spacing: -0.8px; }
.sheet .x { width: 36px; height: 36px; padding: 0; margin: 0; border-radius: 999px; background: var(--gray-p); color: var(--hint); font-size: 16px; flex: none; }
.sheet .card label:first-child, .sheet .card .two:first-child label { margin-top: 0; }
.sheet .two { align-items: end; }
#toast { z-index: 60; }
.trow.tap { cursor: pointer; }
.trow.tap:active { opacity: 0.6; }
.sheet pre { white-space: pre-wrap; }
.card .stat { background: var(--gray-p); box-shadow: none; }
.card .stats .stat { padding: 14px 12px 12px; }
.card .stats .stat .v { font-size: 20px; overflow: hidden; text-overflow: ellipsis; }
.chips.on-bg { flex-wrap: nowrap; gap: 6px; }
.chips.on-bg .chip { flex: 1 1 auto; padding: 9px 8px; font-size: 13.5px; white-space: nowrap; }
.chips.on-bg .chip:not(.on) { background: var(--card); box-shadow: var(--shadow); }
/* Контрагенты */
input[type="search"] { -webkit-appearance: none; }
input.changed, select.changed { border-color: var(--blue); background: var(--blue-p); }
input:disabled { opacity: 0.6; }
a.btnlink { display: flex; align-items: center; justify-content: center; height: 50px; margin-top: 14px; border-radius: 16px; background: var(--green-p); color: var(--green); font-weight: 600; text-decoration: none; }
.sheet .card .two button { margin-top: 10px; height: 44px; font-size: 14.5px; }
/* Меню «Ещё» и ссылка назад */
.menu-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.menu-row:last-child { border-bottom: none; }
.menu-row:active { opacity: 0.6; }
.menu-row .mi { font-size: 22px; width: 30px; text-align: center; }
.menu-row .mt { flex: 1; min-width: 0; font-size: 16.5px; font-weight: 600; }
.menu-row .mt .s { font-size: 12.5px; color: var(--hint); font-weight: 400; margin-top: 2px; }
.menu-row .chev { color: var(--hint); font-size: 22px; }
button.back { width: auto; height: auto; margin: 0 0 4px; padding: 4px 0; background: none; color: var(--blue); font-size: 16px; font-weight: 500; box-shadow: none; }

/* ===== Версия 2.0: нижнее меню с подписями, главная-витрина, сервисы, уведомления, сканер, дашборд ===== */
nav { border-radius: 26px; }
nav button { flex-direction: column; gap: 2px; height: 56px; border-radius: 20px; font-size: 11px; font-weight: 600; position: relative; }
nav button svg { width: 25px; height: 25px; }
nav button .tl { line-height: 1; }
nav button .badge { position: absolute; top: 4px; left: calc(50% + 6px); background: var(--red); color: #fff; font-size: 10.5px; font-weight: 700; border-radius: 999px; padding: 1px 6px; line-height: 1.4; }
main { padding-bottom: calc(110px + env(safe-area-inset-bottom)); }
.ic { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.card svg text { font-family: Inter, sans-serif; }
.search { display: flex; align-items: center; gap: 10px; background: var(--card); border-radius: 16px; height: 48px; padding: 0 14px; color: var(--hint); box-shadow: var(--shadow); margin: 0 0 14px; }
.search svg { width: 20px; height: 20px; flex: none; }
.search input { border: none; background: transparent; height: 44px; padding: 0; font-size: 16px; flex: 1; min-width: 0; }
.search input:focus { outline: none; }
.search .cam { color: var(--blue); display: flex; cursor: pointer; }
.carousel { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -16px; padding: 0 16px; scrollbar-width: none; }
.carousel::-webkit-scrollbar { display: none; }
.hero { flex: 0 0 calc(100% - 46px); scroll-snap-align: center; background: var(--blue); color: #fff; border-radius: 28px; padding: 18px 22px; cursor: pointer; }
.hero .lbl { color: rgba(255, 255, 255, 0.82); }
.hero .big { color: #fff; font-size: 36px; margin: 6px 0 4px; white-space: nowrap; }
.hero .cap-text { color: rgba(255, 255, 255, 0.88); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hero.dark { background: #1c1c1e; } .hero.green { background: #1f9d55; } .hero.orange { background: #e8590c; }
:root[data-theme="dark"] .hero.dark { background: #2c2c2e; }
.dots { display: flex; justify-content: center; gap: 6px; margin: 10px 0 14px; }
.dots i { width: 6px; height: 6px; border-radius: 3px; background: var(--line); transition: width 0.2s; }
.dots i.on { width: 18px; background: var(--blue); }
.svc { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px 8px; text-align: center; font-size: 12.5px; font-weight: 500; }
.svc-i { cursor: pointer; min-width: 0; }
.svc-i:active { opacity: 0.6; }
.svc-t { width: 54px; height: 54px; border-radius: 17px; background: var(--blue-p); color: var(--blue); display: flex; align-items: center; justify-content: center; margin: 0 auto 6px; }
.svc-t svg { width: 27px; height: 27px; }
.att { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.att:last-child { border-bottom: none; }
.att-i { width: 38px; height: 38px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex: none; }
.att-i svg { width: 21px; height: 21px; }
.att-b { flex: 1; min-width: 0; }
.att-t { font-weight: 600; font-size: 15px; }
.att-s { font-size: 12.5px; color: var(--hint); margin-top: 1px; }
.att-c { width: 18px; height: 18px; color: var(--hint); flex: none; }
.red-t { background: var(--red-p); color: var(--red); } .org-t { background: var(--orange-p); color: var(--orange); } .blu-t { background: var(--blue-p); color: var(--blue); } .grn-t { background: var(--green-p); color: var(--green); }
.more-link { text-align: center; color: var(--blue); font-weight: 600; padding: 12px 0; cursor: pointer; }
.hs { display: flex; gap: 10px; overflow-x: auto; margin: 0 -16px 14px; padding: 0 16px 4px; scrollbar-width: none; }
.hs::-webkit-scrollbar { display: none; }
.hc { flex: 0 0 132px; background: var(--card); border-radius: 20px; padding: 12px 14px; box-shadow: var(--shadow); cursor: pointer; }
.hc .hd { font-size: 12px; color: var(--hint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hc .hn { font-weight: 600; font-size: 14px; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hc .hv { font-size: 19px; font-weight: 800; letter-spacing: -0.4px; margin-top: 4px; }
.prof { display: flex; align-items: center; gap: 14px; cursor: pointer; }
.ava { width: 52px; height: 52px; border-radius: 50%; background: var(--blue); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 18px; flex: none; }
.pn { font-weight: 700; font-size: 17px; }
.camera { height: 260px; border-radius: 28px; background: #1c1c1e; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: #fff; margin-bottom: 14px; position: relative; cursor: pointer; font-size: 15px; }
.camera .frame { position: absolute; inset: 30px 36px; border: 2.5px solid rgba(255, 255, 255, 0.85); border-radius: 18px; }
.camera svg { width: 48px; height: 48px; }
.pbtn { height: 50px; border-radius: 16px; background: var(--card); box-shadow: var(--shadow); display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--blue); font-weight: 600; cursor: pointer; }
.pbtn svg { width: 20px; height: 20px; }
.ct { font-weight: 700; font-size: 16px; letter-spacing: -0.2px; margin-bottom: 4px; }
.cs { font-size: 12.5px; color: var(--hint); margin-bottom: 10px; }
.card > svg, .card > div > svg { display: block; margin-top: 8px; overflow: visible; }
.lg { display: flex; gap: 16px; margin-top: 10px; font-size: 12.5px; color: var(--text); flex-wrap: wrap; }
.lg span { display: flex; align-items: center; gap: 6px; }
.lg i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
.up { color: var(--green); } .down { color: var(--red); }
/* Дашборд: фильтры-кнопки, карточка клиента, полоса оплаты */
.fbar { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px 14px; padding: 2px 16px 4px; scrollbar-width: none; }
.fbar::-webkit-scrollbar { display: none; }
.fbar .chip { flex: 0 0 auto; white-space: nowrap; background: var(--card); box-shadow: var(--shadow); display: inline-flex; align-items: center; gap: 6px; }
.fbar .chip.on { background: var(--blue); color: #fff; font-weight: 700; }
.fbar .chip .dd { opacity: 0.55; font-size: 10px; }
.dcl { display: flex; align-items: center; gap: 12px; }
.dcl .av { width: 44px; height: 44px; border-radius: 14px; background: var(--blue); color: #fff; font-weight: 800; font-size: 18px; display: grid; place-items: center; flex: none; }
.dcl .n { font-weight: 800; font-size: 17px; letter-spacing: -0.3px; } .dcl .s { color: var(--hint); font-size: 13px; margin-top: 2px; }
.paybar { height: 12px; border-radius: 6px; background: var(--gray-p); overflow: hidden; display: flex; gap: 2px; margin: 12px 0 4px; }
.paybar > div { height: 100%; }
.stat.tap, .card.tap { cursor: pointer; }
/* Журнал действий */
.hist-d { font-size: 12.5px; font-weight: 600; color: var(--hint); text-transform: uppercase; letter-spacing: 0.4px; padding: 14px 0 4px; }
.hist { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.hist:last-child { border-bottom: none; }
.hist-t { font-size: 13px; font-weight: 700; color: var(--hint); width: 42px; flex: none; padding-top: 1px; }
.hist-x { font-size: 14.5px; line-height: 1.35; overflow-wrap: anywhere; }

/* ===== Версия 2.2: счета на оплату и АВР ===== */
.doc { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.doc:last-child { border-bottom: none; }
.doc.tap { cursor: pointer; } .doc.tap:active { opacity: 0.6; }
.doc.off { opacity: 0.5; }
.doc .ico { width: 44px; height: 44px; border-radius: 13px; background: var(--blue-p); color: var(--blue); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; letter-spacing: -0.3px; }
.doc .d { font-size: 16px; font-weight: 700; letter-spacing: -0.2px; }
.doc .s { font-size: 12.5px; color: var(--hint); margin-top: 2px; }
.doc .r { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; align-self: start; }
.doc .sum { font-size: 16px; font-weight: 700; white-space: nowrap; }
.doc .dl { display: flex; gap: 8px; margin-top: 8px; }
.doc .dl .chip { margin: 0; white-space: nowrap; font-size: 13px; padding: 6px 12px; color: var(--blue); }
.thumbs { display: grid; grid-template-columns: 1fr 1.41fr; gap: 10px; margin-top: 14px; align-items: start; }
.thumbs img { width: 100%; display: block; border-radius: 10px; border: 1px solid var(--line); background: #fff; }
.thumbs .t { font-size: 12px; color: var(--hint); margin-top: 4px; text-align: center; }
.warn { background: var(--orange-p); color: var(--text); border-radius: 18px; padding: 12px 16px; font-size: 14px; line-height: 1.4; margin-bottom: 14px; }
.opt { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0 0; margin-top: 12px; border-top: 1px solid var(--line); }
.tgl { position: relative; width: 51px; height: 31px; flex: none; margin: 0; }
.tgl input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; z-index: 1; }
.tgl span { position: absolute; inset: 0; border-radius: 999px; background: var(--line); transition: background 0.2s; }
.tgl span::after { content: ''; position: absolute; left: 2px; top: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25); transition: transform 0.2s; }
.tgl input:checked + span { background: var(--green); }
.tgl input:checked + span::after { transform: translateX(20px); }

/* ===== Версия 2.4: кабинет водителя, ТО ===== */
.hero2 { background: var(--blue); color: #fff; border-radius: 28px; padding: 22px; margin-bottom: 14px; }
.hero2 .h { font-size: 24px; font-weight: 800; letter-spacing: -0.5px; }
.hero2 .p { opacity: 0.85; font-size: 14.5px; margin-top: 6px; line-height: 1.4; }
.hero2 .bt { display: flex; gap: 10px; margin-top: 16px; }
.hero2 .bt button { margin: 0; background: #fff; color: var(--blue); height: 48px; flex: 1; white-space: nowrap; }
.hero2 .bt button.g { background: rgba(255, 255, 255, 0.18); color: #fff; }
.bar { height: 12px; border-radius: 999px; background: var(--gray-p); overflow: hidden; margin: 12px 0 6px; }
.bar i { display: block; height: 100%; border-radius: 999px; }
.warn b { display: block; margin-bottom: 2px; }

/* ===== Версия 2.5: сотрудники ===== */
.per { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.per:last-child { border-bottom: none; }
.per.tap { cursor: pointer; } .per.tap:active { opacity: 0.6; }
.per .av { width: 44px; height: 44px; border-radius: 50%; background: var(--blue-p); color: var(--blue); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 15px; }
.per .n { font-weight: 700; font-size: 16px; }
.per .s { font-size: 12.5px; color: var(--hint); margin-top: 2px; }
.per .r { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.per .sum { font-weight: 700; white-space: nowrap; }

/* ===== Версия 2.8: новые уведомления ===== */
.dot-new { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--red); margin-right: 6px; vertical-align: 2px; }

/* ===== Версия 2.9: рейсы без акта ===== */
.grp { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin: 18px 4px 8px; }
.grp .n { font-size: 13px; font-weight: 600; color: var(--hint); text-transform: uppercase; letter-spacing: 0.2px; }
.grp .chip { font-size: 13px; padding: 6px 12px; color: var(--blue); margin: 0; white-space: nowrap; }
.na { padding: 12px 0; border-bottom: 1px solid var(--line); }
.na:last-child { border-bottom: none; }
.na .top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.na .a, .na .t { font-size: 15.5px; font-weight: 700; letter-spacing: -0.2px; }
.na .t { white-space: nowrap; }
.na .s { font-size: 12.5px; color: var(--hint); margin-top: 2px; }
.na .btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.na .btns button { height: 40px; margin-top: 10px; font-size: 14.5px; border-radius: 12px; }
.na.done .a, .na.done .t { color: var(--hint); }
.na .st { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; font-size: 14px; }
.na .st a { color: var(--blue); font-weight: 600; text-decoration: none; }
.bigin { font-size: 34px; font-weight: 800; letter-spacing: -1px; height: 60px; }
.wbig { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; margin-top: 4px; }
.cap.skip { background: var(--gray-p); color: var(--hint); font-size: 11px; }

/* ===== Версия 2.10: карточки нарушений ===== */
.vbig { display: flex; align-items: baseline; gap: 10px; margin: 2px 0 4px; }
.vbig .n { font-size: 44px; font-weight: 800; letter-spacing: -1.4px; }
.vbig .u { font-size: 20px; font-weight: 700; }
.kv { display: grid; grid-template-columns: 1.25fr 1fr 1fr; gap: 8px; margin-top: 12px; }
.kv > div { background: var(--bg); border-radius: 14px; padding: 9px 11px; min-width: 0; }
.kv .l { font-size: 12px; color: var(--hint); line-height: 1.25; white-space: nowrap; }
.kv .v { font-size: 15.5px; font-weight: 700; margin-top: 3px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.btnrow { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.btnrow button { margin-top: 10px; }
.trip { display: flex; justify-content: space-between; gap: 10px; }
.trip .a { font-weight: 700; white-space: nowrap; }
.trip .s { font-size: 12.5px; color: var(--hint); margin-top: 2px; }
textarea.msg { height: 130px; }

/* ===== Версия 2.11: экран «Нарушения» ===== */
.who { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.who:last-child { border-bottom: none; }
.who .n { font-weight: 700; }
.who .r { font-weight: 700; text-align: right; white-space: nowrap; }
.who .s { font-size: 12.5px; color: var(--hint); grid-column: 1 / -1; }
.who .bar { grid-column: 1 / -1; height: 6px; border-radius: 3px; background: var(--gray-p); overflow: hidden; margin: 0; }
.who .bar i { display: block; height: 100%; background: #007aff; border-radius: 3px; }
.day { font-size: 13px; font-weight: 600; color: var(--hint); text-transform: uppercase; letter-spacing: 0.2px; margin: 18px 4px 8px; }
/* Оплаты: кнопки на «Деньгах», последние оплаты, предпросмотр, разбор выписки */
.acts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0 0 14px; }
.acts button { margin: 0; height: 48px; font-size: 15px; }
.pay { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.pay:last-child { border-bottom: none; }
.pay .n { font-weight: 700; min-width: 0; overflow-wrap: anywhere; }
.pay .m { font-weight: 700; white-space: nowrap; text-align: right; }
.pay .s { font-size: 12.5px; color: var(--hint); grid-column: 1 / -1; overflow-wrap: anywhere; }
.pay.tap, .op.tap, .card.tap { cursor: pointer; }
.pv { background: var(--green-p); border-radius: 16px; padding: 12px 14px; margin-top: 16px; font-size: 14px; line-height: 1.5; }
.pv.muted { background: var(--gray-p); }
.op { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 2px 12px; padding: 13px 0; border-bottom: 1px solid var(--line); align-items: start; }
.op:last-child { border-bottom: none; }
.op .ck { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line); margin-top: 2px; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 14px; font-weight: 800; box-sizing: border-box; }
.op .ck.on { background: var(--blue); border-color: var(--blue); }
.op .n { font-weight: 700; font-size: 15.5px; letter-spacing: -0.2px; min-width: 0; overflow-wrap: anywhere; }
.op .m { font-weight: 700; text-align: right; white-space: nowrap; font-size: 15.5px; }
.op .s { font-size: 12.5px; color: var(--hint); grid-column: 2 / -1; line-height: 1.4; overflow-wrap: anywhere; }
.op .tags { grid-column: 2 / -1; display: flex; gap: 6px; flex-wrap: wrap; margin-top: 5px; }
.op select { grid-column: 2 / -1; height: 40px; font-size: 15px; margin-top: 6px; }
.op.dim { opacity: 0.55; }
.cap.sm { min-width: 0; font-size: 12px; font-weight: 600; padding: 3px 9px; white-space: normal; }
.fold { display: flex; justify-content: space-between; align-items: center; font-weight: 600; color: var(--hint); }
.file { display: flex; gap: 12px; align-items: center; }
.file .fi { width: 42px; height: 42px; flex: none; border-radius: 12px; background: var(--red-p); color: var(--red); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 12px; }
.file .ft { font-weight: 700; overflow-wrap: anywhere; }
.file .fs { font-size: 12.5px; color: var(--hint); }
.recent .btns.three { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.recent .btns.three button { margin: 10px 0 0; padding: 0 6px; font-size: 14px; }

/* WhatsApp: клиенты и перевозчики, карточка с галочками */
.wp { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 2px 12px; padding: 13px 0; border-bottom: 1px solid var(--line); align-items: center; cursor: pointer; }
.wp:last-child { border-bottom: none; }
.wp:active { opacity: 0.6; }
.wp .av { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 15px; grid-row: span 2; }
.wp .av.c { background: var(--blue-p); color: var(--blue); } .wp .av.k { background: var(--orange-p); color: var(--orange); }
.wp .n { font-weight: 700; font-size: 15.5px; letter-spacing: -0.2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wp .r { grid-row: 1; grid-column: 3; }
.wp .s { font-size: 12.5px; color: var(--hint); grid-column: 2 / -1; line-height: 1.4; overflow-wrap: anywhere; }
.ty { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--line); }
.ty .t { font-weight: 600; } .ty .d { font-size: 12.5px; color: var(--hint); margin-top: 1px; line-height: 1.35; }
.two.wa-btns > button { margin: 0; }
.opt.tap { cursor: pointer; }

/* «Сервисы» по группам: значок новых на плитке */
.svc-i { position: relative; letter-spacing: -0.2px; }
.svc-b { position: absolute; top: -4px; left: calc(50% + 14px); background: var(--red); color: #fff; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 0 6px; line-height: 17px; }

/* Свайп «Назад»: текущий экран уезжает, под ним — предыдущий (сдвинут и притемнён) */
#view.swiping { position: relative; z-index: 2; background: var(--bg); box-shadow: -8px 0 24px rgba(0, 0, 0, 0.12); will-change: transform; }
.swipe-under { position: fixed; inset: 0; z-index: 1; overflow: hidden; background: var(--bg); pointer-events: none; will-change: transform; }
.swipe-under-in > * { pointer-events: none; }
.swipe-dim { position: absolute; inset: 0; background: #000; opacity: 0.25; }
.swipe-under-in { padding: 22px 16px 0; max-width: 640px; margin: 0 auto; }
nav { z-index: 10; }

/* «Что нового» */
.wn-hero { background: var(--blue); color: #fff; }
.wn-hero .lbl, .wn-hero .cap-text { color: rgba(255, 255, 255, 0.88); }
.wn-chips { position: sticky; top: 0; z-index: 3; background: var(--bg); padding: 8px 0; margin: 4px 0 0; }
.wn { padding: 18px 22px 10px; }
.wn-n { font-size: 22px; font-weight: 800; letter-spacing: -0.5px; }
.wn-now { display: inline-block; vertical-align: 4px; margin-left: 8px; font-size: 12px; font-weight: 700; color: #fff; background: var(--blue); border-radius: 999px; padding: 2px 9px; letter-spacing: 0; }
.wn-t { font-size: 14px; color: var(--hint); margin-top: 2px; }
.wn-g { padding: 12px 0 8px; border-top: 1px solid var(--line); margin-top: 12px; }
.wn-g + .wn-g { margin-top: 0; }
.wn-gh { display: inline-block; font-size: 13px; font-weight: 700; border-radius: 999px; padding: 4px 11px; margin-bottom: 8px; }
.wn-g.n .wn-gh { background: var(--blue-p); color: var(--blue); }
.wn-g.f .wn-gh { background: var(--orange-p); color: var(--orange); }
.wn-g.i .wn-gh { background: var(--green-p); color: var(--green); }
.wn-g ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.wn-g li { position: relative; padding-left: 16px; font-size: 15px; line-height: 1.45; }
.wn-g li::before { content: ''; position: absolute; left: 2px; top: 9px; width: 6px; height: 6px; border-radius: 50%; background: var(--line); }
.wn-g.n li::before { background: var(--blue); } .wn-g.f li::before { background: var(--orange); } .wn-g.i li::before { background: var(--green); }
.wn-g b { font-weight: 600; }
.wn-chips { overflow-x: auto; scrollbar-width: none; }
.wn-chips::-webkit-scrollbar { display: none; }
.wn-chips .chip { flex: 0 0 auto; padding: 9px 12px; }
.wn-stats .stat .lbl { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* «Мессенджеры»: единый вид Telegram и WhatsApp */
.msg-seg { margin-bottom: 14px; }
.msg-seg button { flex: 1; min-width: 0; padding: 0 2px; font-size: 13.5px; }
.cap.tg { background: #e3f1fb; color: #2481cc; } .cap.wa { background: #e2f6ea; color: #1a9e55; }
.wp .av.d { background: var(--green-p); color: var(--green); }
.wp .s .cap { margin: 2px 4px 0 0; }
.wp .r .ic { width: 18px; height: 18px; color: var(--hint); }
.bot-card { display: flex; align-items: center; gap: 12px; }
.bot-card .dot { width: 10px; height: 10px; border-radius: 50%; flex: none; background: var(--line); } .bot-card .dot.on { background: var(--green); }
.bot-card .t { font-weight: 700; } .bot-card .d { font-size: 12.5px; color: var(--hint); }
.bot-card > .ic, .line-card > .ic { width: 18px; height: 18px; color: var(--hint); margin-left: auto; flex: none; }
.line-card { display: flex; align-items: center; gap: 10px; }
.line-card .cap { margin-right: 4px; }
.mh { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.mlogo { width: 34px; height: 34px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex: none; color: #fff; }
.mlogo .ic { width: 19px; height: 19px; stroke: #fff; } .mlogo.tg { background: #2aabee; } .mlogo.wa { background: #25d366; }
.mh .t { font-weight: 800; font-size: 17px; letter-spacing: -0.2px; } .mh .d { font-size: 12.5px; color: var(--hint); }
.mr { display: grid; grid-template-columns: minmax(0, 1fr) auto 36px; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid var(--line); }
.mr .a { font-weight: 650; font-size: 15.5px; overflow: hidden; text-overflow: ellipsis; } .mr .s { font-size: 12.5px; color: var(--hint); margin-top: 1px; }
.mr.off .a { color: var(--hint); }
.mr.sug { grid-template-columns: minmax(0, 1fr) auto; } .mr.sug .chip { margin: 0; }
.mr .del { width: 36px; height: 36px; padding: 0; margin: 0; border-radius: 999px; background: var(--gray-p); color: var(--hint); display: flex; align-items: center; justify-content: center; }
.mr .del .ic { width: 17px; height: 17px; }
.mr-empty { padding: 10px 0 2px; border-top: 1px solid var(--line); }
.add { display: flex; align-items: center; justify-content: center; width: 100%; margin: 12px 0 0; height: 46px; border-radius: 14px; border: 1.5px dashed var(--line); background: transparent; color: var(--blue); font-weight: 700; font-size: 15px; }
.foot { font-size: 12.5px; color: var(--hint); margin-top: 10px; line-height: 1.4; }
.nt { display: grid; grid-template-columns: minmax(0, 1fr) 64px 64px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.nt.h { border-top: none; padding-top: 0; } .nt .c { display: flex; justify-content: center; }
.nt.h .mlogo { width: 30px; height: 30px; border-radius: 9px; } .nt.h .mlogo .ic { width: 16px; height: 16px; }
.nt .t { font-weight: 600; } .nt .d { font-size: 12px; color: var(--hint); line-height: 1.3; }
.hi { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 2px 10px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; }
.hi:first-child { border-top: none; } .hi .tm { color: var(--hint); font-size: 12.5px; line-height: 1.35; }
.hi .ok { color: var(--green); font-size: 12.5px; font-weight: 600; text-align: right; }
.info { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.info:first-child { border-top: none; } .info span:first-child { color: var(--hint); }

/* «Куда везти»: адреса доставки клиента */
.addr { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); cursor: pointer; }
.card > .addr:first-child { border-top: none; padding-top: 2px; }
.addr .pin { width: 36px; height: 36px; border-radius: 12px; background: var(--blue-p); color: var(--blue); display: flex; align-items: center; justify-content: center; font-size: 18px; flex: none; }
.addr-b { flex: 1; min-width: 0; }
.addr-t { font-weight: 600; }
.addr-s { font-size: 13.5px; color: var(--hint); margin-top: 2px; }
.addr-g { font-size: 13px; color: var(--green); font-weight: 600; margin-top: 4px; }
.addr-no { font-size: 13px; color: var(--orange); font-weight: 600; margin-top: 4px; }
.addr-ch { color: var(--hint); font-size: 20px; align-self: center; }
.addr-empty { color: var(--hint); font-size: 14px; padding-bottom: 12px; }
.add-l { color: var(--blue); font-weight: 600; padding-top: 12px; border-top: 1px solid var(--line); cursor: pointer; }
.card > .add-l:first-child { border-top: none; padding-top: 0; }
.card .opt.first { border-top: none; margin-top: 0; padding-top: 0; }
