

:root { --ink:#1d1b24; --muted:#817d8a; --line:#ebe8ef; --paper:#f6f5f8; --violet:#6049d7; --violet-dark:#4932bc; --green:#159b72; --orange:#ec6f43; }
* { box-sizing:border-box; }
body { margin:0; background:var(--paper); color:var(--ink); font-family:Inter,"Segoe UI",Arial,sans-serif; }
button { font:inherit; color:inherit; }
.shell { min-height:100vh; display:flex; }
.sidebar { width:216px; flex:0 0 216px; background:#fff; border-right:1px solid var(--line); padding:24px 16px 18px; display:flex; flex-direction:column; position:sticky; top:0; height:100vh; z-index:20; }
.brand { display:flex; align-items:center; gap:10px; font-size:18px; font-weight:750; padding:0 9px 27px; letter-spacing:-.3px; }
.brand-mark { width:34px; height:34px; display:grid; place-items:center; border-radius:11px; color:#fff; background:linear-gradient(145deg,#7b68ef,#4e35c7); font-size:18px; box-shadow:0 6px 16px #5f49d735; }
nav { display:flex; flex-direction:column; gap:5px; }
.nav-item { height:43px; border:0; background:transparent; border-radius:10px; padding:0 11px; display:flex; gap:12px; align-items:center; color:#716d79; cursor:pointer; text-align:left; font-size:13px; font-weight:550; }
.nav-item span { width:17px; color:#96919d; font-size:17px; text-align:center; }
.nav-item b { margin-left:auto; background:#eeeafc; color:var(--violet); font-size:10px; min-width:22px; height:19px; border-radius:10px; display:grid; place-items:center; }
.nav-item:hover { background:#f7f5fb; color:var(--ink); }
.nav-item.active { background:#eeeafd; color:var(--violet-dark); font-weight:700; }
.nav-item.active span { color:var(--violet); }
.side-bottom { margin-top:auto; }
.manager { border-top:1px solid var(--line); margin-top:12px; padding:19px 4px 2px; display:flex; align-items:center; gap:9px; }
.manager div:nth-child(2) { display:flex; flex-direction:column; min-width:0; }
.manager strong { font-size:12px; }.manager small { color:var(--muted); font-size:10px; margin-top:2px; }.manager>span { margin-left:auto; color:#a39eaa; }
.avatar { width:38px; height:38px; flex:0 0 38px; display:grid; place-items:center; border-radius:50%; font-size:11px; font-weight:750; }
.avatar.dark { color:#fff; background:#2e2937; }
.workspace { width:calc(100% - 216px); max-width:1500px; padding:26px 30px 40px; margin:0 auto; }
.topbar { display:flex; justify-content:space-between; align-items:center; margin-bottom:23px; }
.eyebrow { color:#9b96a3; font-size:11px; margin:0 0 5px; }
h1 { margin:0; font-size:24px; letter-spacing:-.6px; line-height:1.1; }
.top-actions { display:flex; align-items:center; gap:10px; }
.sync-pill { height:35px; display:flex; align-items:center; gap:8px; padding:0 12px; border:1px solid var(--line); background:#fff; border-radius:9px; color:#67626e; font-size:10px; }
.sync-pill i { width:7px; height:7px; border-radius:50%; background:#2ab77e; box-shadow:0 0 0 3px #daf5e9; }
.icon-btn { position:relative; height:35px; width:35px; border:1px solid var(--line); border-radius:9px; background:#fff; cursor:pointer; }
.icon-btn em { position:absolute; top:-4px; right:-4px; width:15px; height:15px; background:var(--orange); color:#fff; display:grid; place-items:center; font-size:8px; border-radius:50%; font-style:normal; border:2px solid var(--paper); }
.primary-btn { border:0; background:var(--violet); color:#fff; height:36px; border-radius:9px; padding:0 14px; font-weight:650; font-size:11px; cursor:pointer; box-shadow:0 5px 15px #6049d728; }
.primary-btn:hover { background:var(--violet-dark); }
.stats { display:grid; grid-template-columns:repeat(4,1fr); gap:12px; margin-bottom:12px; }
.stats article { min-height:82px; background:#fff; border:1px solid var(--line); border-radius:12px; padding:15px 16px; display:flex; justify-content:space-between; align-items:center; }
.stats article>div { display:flex; flex-direction:column; gap:5px; }.stats small { color:var(--muted); font-size:10px; }.stats strong { font-size:21px; letter-spacing:-.5px; }
.stats strong i { color:#aaa5b0; font-size:11px; font-style:normal; font-weight:500; }
.trend { font-size:9px; color:var(--green); background:#e8f8f1; padding:4px 7px; border-radius:10px; }
.stat-icon { width:31px; height:31px; border-radius:9px; display:grid; place-items:center; font-size:13px; }.stat-icon.purple { color:var(--violet); background:#eeeafd; }.stat-icon.orange { color:var(--orange); background:#fff0ea; }
.notice { min-height:52px; display:flex; align-items:center; padding:8px 12px; border-radius:11px; border:1px solid #ded7ff; background:#f1effd; margin-bottom:12px; }
.notice>span { width:29px; height:29px; border-radius:8px; display:grid; place-items:center; color:var(--violet); background:#fff; margin-right:10px; }
.notice p { display:flex; flex-direction:column; margin:0; gap:2px; }.notice strong { font-size:11px; }.notice small { color:#817a99; font-size:9px; }
.notice button { border:0; background:transparent; margin-left:auto; color:var(--violet-dark); font-size:10px; font-weight:700; cursor:pointer; padding:8px; }
.notice.success { background:#eaf8f2; border-color:#c8eddd; }.notice.success>span { color:var(--green); }
.hub-strip { min-height:66px; margin-bottom:12px; padding:10px 13px; border:1px solid #ddd8e8; border-radius:12px; background:#292531; color:#fff; display:flex; align-items:center; justify-content:space-between; gap:18px; }
.hub-address { display:flex; align-items:center; gap:10px; min-width:285px; }
.hub-address>span { width:36px; height:36px; flex:0 0 36px; display:grid; place-items:center; border-radius:10px; background:var(--violet); font-size:15px; font-weight:800; }
.hub-address p { display:flex; flex-direction:column; gap:3px; margin:0; }
.hub-address small { color:#aaa4b4; font-size:8px; }.hub-address strong { font-size:11px; }
.route-rules { display:grid; grid-template-columns:repeat(3,1fr); width:min(650px,66%); }
.route-rules>span { display:flex; flex-direction:column; gap:3px; padding:2px 14px; border-left:1px solid #484250; }
.route-rules b { font-size:9px; }.route-rules small { color:#aaa4b4; font-size:7px; white-space:nowrap; }
.panel { background:#fff; border:1px solid var(--line); border-radius:13px; overflow:hidden; }
.dashboard-grid { display:grid; grid-template-columns:minmax(430px,.84fr) minmax(450px,1.16fr); gap:12px; min-height:480px; }
.panel-head { min-height:63px; display:flex; justify-content:space-between; align-items:center; padding:0 17px; border-bottom:1px solid var(--line); }
.panel-head>div { display:flex; align-items:baseline; gap:8px; } h2 { margin:0; font-size:13px; letter-spacing:-.1px; }.panel-head span { color:#aaa5af; font-size:9px; }
.more-btn { border:0; background:transparent; color:#99949f; letter-spacing:2px; cursor:pointer; }
.filters { display:flex; gap:5px; padding:10px 13px; border-bottom:1px solid var(--line); overflow-x:auto; }
.filters button { white-space:nowrap; border:0; background:#f5f3f7; color:#827d87; height:27px; border-radius:7px; padding:0 9px; font-size:9px; cursor:pointer; display:flex; gap:6px; align-items:center; }
.filters button b { font-weight:500; opacity:.7; }.filters button.selected { background:#ebe7fc; color:var(--violet-dark); font-weight:700; }
.zone-filters { min-height:37px; padding:5px 13px; display:flex; align-items:center; gap:5px; border-bottom:1px solid var(--line); overflow-x:auto; }
.zone-filters>span { color:#9d98a2; font-size:8px; margin-right:3px; }.zone-filters button { border:1px solid #ebe8ef; background:#fff; border-radius:6px; padding:4px 7px; color:#7b7681; font-size:8px; white-space:nowrap; cursor:pointer; }
.zone-filters button.selected { color:#fff; border-color:var(--violet); background:var(--violet); }
.order-list { max-height:350px; overflow:auto; }
.order-row { border:0; border-bottom:1px solid #f1eef3; background:#fff; width:100%; padding:10px 13px; display:grid; grid-template-columns:31px 1fr auto; gap:10px; text-align:left; cursor:pointer; }
.order-row:hover,.order-row.selected-order { background:#faf9fd; }.order-row.selected-order { box-shadow:inset 3px 0 var(--violet); }
.order-row.order-deferred,.courier-route-list>article.order-deferred { background:#fff5c7!important; }
.order-row.order-completed,.courier-route-list>article.order-completed { background:#e2f7ec!important; }
.order-row.order-overdue,.courier-route-list>article.order-overdue { background:#ffe1e1!important; }
.order-row.order-rescheduled,.courier-route-list>article.order-rescheduled { background:#ffe2f1!important; }
.order-row.order-stopped,.courier-route-list>article.order-stopped { background:#eee4ff!important; }
.order-row.order-confirmed,.courier-route-list>article.order-confirmed { background:#e9f2ff!important; }
.type-icon { width:30px; height:30px; display:grid; place-items:center; border-radius:8px; font-size:15px; font-weight:800; margin-top:2px; }
.order-main,.order-side { display:flex; flex-direction:column; }.order-main>span { display:flex; align-items:center; gap:6px; margin-bottom:3px; }
.order-main>span strong { font-size:8px; color:#8e8993; }.order-main>span small { font-size:7px; background:#e7f0fb; color:#5281aa; padding:2px 4px; border-radius:3px; }.order-main>span em { font-size:7px; color:#635c6c; font-style:normal; background:#f0edf3; padding:2px 4px; border-radius:3px; }
.order-main b { font-size:10px; margin-bottom:3px; }.order-main>small,.order-side small { color:#918c97; font-size:8px; }
.order-side { align-items:flex-end; min-width:92px; }.order-side>span { font-size:9px; font-weight:700; }.order-side>small { margin:3px 0 5px; }
.status { font-style:normal; font-size:7px; border-radius:10px; color:var(--violet-dark); background:#ece8fd; padding:3px 6px; display:flex; align-items:center; gap:3px; }
.status.new { color:var(--orange); background:#fff0e9; }.status.route { color:var(--green); background:#e8f6f1; }
.status u { width:12px; height:12px; display:grid; place-items:center; border-radius:50%; background:#fff; text-decoration:none; font-size:6px; }
.show-all { height:36px; width:100%; border:0; background:#fff; color:var(--violet); font-size:9px; font-weight:650; cursor:pointer; }
.map-panel { position:relative; }
.map-toolbar { position:absolute; z-index:5; top:12px; left:12px; right:12px; display:flex; justify-content:space-between; pointer-events:none; }
.map-toolbar button { pointer-events:auto; border:1px solid #e2dee7; background:#fff; height:31px; min-width:31px; cursor:pointer; box-shadow:0 4px 15px #4f47551b; }
.map-title { border-radius:8px; padding:0 10px; font-size:9px; font-weight:650; }.map-title b { color:var(--violet); background:#eeeafd; padding:2px 5px; border-radius:8px; margin:0 8px; }
.map-toolbar div { display:flex; flex-direction:column; }.map-toolbar div button:first-child { border-radius:7px 7px 0 0; border-bottom:0; }.map-toolbar div button:last-child { border-radius:0 0 7px 7px; }
.map { height:100%; min-height:480px; position:relative; overflow:hidden; background-color:#f0eee9; background-image:linear-gradient(25deg,transparent 47%,#e1ded5 48%,#e1ded5 49%,transparent 50%),linear-gradient(115deg,transparent 48%,#e4e1d9 49%,#e4e1d9 50%,transparent 51%); background-size:100px 120px,140px 130px; }
.river { position:absolute; width:150%; height:68px; left:-20%; top:47%; background:#d3e7ea; transform:rotate(-12deg); border:7px solid #e9e6de; }
.road { position:absolute; background:#fff; box-shadow:0 0 0 1px #dedbd3; opacity:.85; }.r1 { width:110%; height:8px; top:25%; left:-5%; transform:rotate(8deg); }.r2 { width:100%; height:7px; top:72%; left:2%; transform:rotate(-8deg); }.r3 { width:8px; height:115%; left:44%; top:-10%; transform:rotate(7deg); }.r4 { width:7px; height:115%; left:72%; top:-8%; transform:rotate(-21deg); }.r5 { width:7px; height:105%; left:20%; top:-2%; transform:rotate(19deg); }
.map-label { position:absolute; color:#9b978f; font-size:9px; letter-spacing:.4px; text-transform:uppercase; }.ml1 { left:9%; top:18%; }.ml2 { left:54%; top:15%; }.ml3 { left:27%; top:46%; }.ml4 { left:68%; top:78%; }
.laundry { position:absolute; left:50%; top:56%; transform:translate(-50%,-50%); width:30px; height:30px; display:grid; place-items:center; border-radius:9px; color:#fff; background:#27232e; font-size:12px; box-shadow:0 4px 10px #2b263444; z-index:3; }
.laundry span { position:absolute; top:34px; color:#514c55; background:#ffffffc8; padding:2px 5px; border-radius:3px; font-size:7px; white-space:nowrap; }
.map-pin { z-index:4; position:absolute; transform:translate(-50%,-50%); border:3px solid #fff; width:27px; height:27px; border-radius:50% 50% 50% 4px; color:#fff; font-size:12px; font-weight:800; cursor:pointer; box-shadow:0 4px 10px #3f374632; }
.map-pin.active-pin { width:34px; height:34px; z-index:7; box-shadow:0 0 0 5px #ffffffaa,0 6px 14px #3f37463f; }
.route-segment { position:absolute; z-index:2; height:3px; border-radius:3px; background:#6551d8; opacity:.5; transform-origin:left center; }
.route-segment.s1 { left:50%; top:56%; width:27%; transform:rotate(-40deg); }.route-segment.s2 { left:69%; top:39%; width:22%; transform:rotate(66deg); }.route-segment.s3 { left:76%; top:57%; width:34%; transform:rotate(153deg); }.route-segment.s4 { left:47%; top:72%; width:29%; transform:rotate(-128deg); }.route-segment.s5 { left:35%; top:43%; width:23%; transform:rotate(35deg); background:#159b72; }
.order-popover { position:absolute; z-index:6; left:13px; bottom:43px; width:min(315px,calc(100% - 26px)); background:#fff; border:1px solid #e2dee7; border-radius:11px; padding:11px; box-shadow:0 10px 35px #3c35451c; }
.order-popover>div { display:flex; align-items:center; }.order-popover>div>span { width:29px; height:29px; border-radius:8px; display:grid; place-items:center; margin-right:8px; font-weight:800; }
.order-popover p { margin:0; }.order-popover>div p { display:flex; flex-direction:column; gap:2px; }.order-popover strong { font-size:9px; }.order-popover small,.order-popover>p { font-size:8px; color:#8d8892; }.order-popover>div>b { margin-left:auto; font-size:8px; }
.order-popover>p { margin:8px 0; padding-left:37px; }.order-popover footer { border-top:1px solid var(--line); padding-top:8px; display:flex; align-items:center; justify-content:space-between; }
.route-flow { display:flex; align-items:center; gap:5px; margin:8px 0; padding:7px 8px; border-radius:7px; background:#f5f3f8; color:#6d6872; font-size:7px; white-space:nowrap; overflow:hidden; }
.route-flow b { font-size:7px; color:#46404e; overflow:hidden; text-overflow:ellipsis; }.route-flow i { color:var(--violet); font-style:normal; }.route-flow span { color:var(--violet-dark); font-weight:700; }
.order-popover footer span { color:#8d8892; font-size:8px; }.order-popover footer button { border:0; background:#eeeafd; color:var(--violet-dark); padding:5px 8px; border-radius:6px; font-size:8px; font-weight:700; cursor:pointer; }
.legend { position:absolute; bottom:11px; right:12px; display:flex; gap:10px; background:#ffffffdb; border-radius:7px; padding:6px 8px; font-size:7px; color:#6d6872; }.legend span { display:flex; align-items:center; gap:4px; }
.dot { width:6px; height:6px; border-radius:50%; display:inline-block; }.dot.pickup { background:var(--violet); }.dot.dropoff { background:var(--orange); }.dot.exchange { background:var(--green); }
.couriers { margin-top:12px; }.text-btn { border:0; background:transparent; color:var(--violet); font-size:9px; font-weight:650; cursor:pointer; }
.courier-grid { display:grid; grid-template-columns:repeat(4,1fr); }.courier-grid article { min-height:75px; padding:13px 17px; display:flex; align-items:center; gap:9px; border-right:1px solid var(--line); }.courier-grid article:last-child { border:0; }
.courier-info { display:flex; flex-direction:column; gap:4px; min-width:62px; }.courier-info strong { font-size:10px; }.courier-info small { color:#938e98; font-size:8px; }.courier-info i { display:inline-block; width:5px; height:5px; background:#2db883; border-radius:50%; margin-right:3px; }
.load { margin-left:auto; width:75px; }.load>span { font-size:7px; color:#98939d; }.load>span b { color:var(--ink); font-size:9px; }.load>div { height:3px; background:#eeeaf0; border-radius:2px; margin-top:5px; overflow:hidden; }.load>div i { display:block; height:100%; background:var(--violet); border-radius:2px; transition:width .3s; }
@media(max-width:1050px){.dashboard-grid{grid-template-columns:1fr}.map-panel{min-height:500px}.courier-grid{grid-template-columns:repeat(2,1fr)}.courier-grid article:nth-child(2){border-right:0}.courier-grid article:nth-child(-n+2){border-bottom:1px solid var(--line)}}
@media(max-width:780px){.sidebar{width:68px;flex-basis:68px;padding:20px 10px}.brand{padding:0 7px 24px}.brand>span:last-child,.nav-item:not(.active) b,.nav-item{font-size:0}.nav-item{justify-content:center;padding:0}.nav-item span{font-size:18px}.manager>div:not(.avatar),.manager>span{display:none}.workspace{width:calc(100% - 68px);padding:20px 15px 30px}.stats{grid-template-columns:repeat(2,1fr)}.sync-pill{display:none}.dashboard-grid{grid-template-columns:minmax(0,1fr)}.hub-strip{align-items:flex-start;flex-direction:column}.route-rules{width:100%}.route-rules>span:first-child{border-left:0;padding-left:0}}
@media(max-width:560px){.topbar{align-items:flex-start}.top-actions .icon-btn{display:none}.primary-btn{font-size:0;width:36px;padding:0}.primary-btn::first-letter{font-size:16px}h1{font-size:19px}.stats article{min-height:73px}.dashboard-grid{min-height:0}.orders-panel{min-width:0}.order-row{grid-template-columns:30px 1fr}.order-side{grid-column:2;align-items:flex-start;flex-direction:row;gap:7px}.map{min-height:460px}.courier-grid{grid-template-columns:1fr}.courier-grid article{border-right:0;border-bottom:1px solid var(--line)}}

/* Interactive route map */
.map-panel { min-height:560px; }
#real-map { height:100%; min-height:560px; background:#e8e5df; z-index:1; }
.map-toolbar { z-index:800; }
.map-toolbar .map-title { max-width:70%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.rebuild-btn { border-radius:8px!important; padding:0 11px!important; font-size:9px; font-weight:700; color:var(--violet-dark); }
.map-route-legend { position:absolute; z-index:800; left:12px; right:12px; bottom:12px; display:flex; gap:5px; align-items:stretch; flex-wrap:wrap; pointer-events:none; }
.map-route-legend>span { min-width:125px; display:grid; grid-template-columns:7px auto; column-gap:6px; align-items:center; padding:6px 8px; border:1px solid #e1dce6; border-radius:8px; background:#fffffff2; box-shadow:0 5px 18px #42394d1a; }
.map-route-legend>span>i { width:7px; height:7px; grid-row:1/3; border-radius:50%; }
.map-route-legend>span>b { font-size:8px; }.map-route-legend>span>small { color:#817b86; font-size:7px; }
.map-route-legend>em { align-self:center; padding:7px 9px; border-radius:7px; background:#fff1eb; color:#b34c2a; font-size:8px; font-style:normal; font-weight:700; }
.leaflet-stop,.leaflet-hub { display:grid; place-items:center; color:#fff; background:var(--marker); border:3px solid #fff; border-radius:50% 50% 50% 5px; box-shadow:0 3px 10px #24202b55; font-size:9px; font-weight:800; }
.leaflet-stop { width:29px; height:29px; }.leaflet-hub { width:40px; height:40px; border-radius:12px; font-size:15px; }
.leaflet-popup-content-wrapper { border-radius:10px; box-shadow:0 8px 30px #302a3940; }
.leaflet-popup-content { margin:11px 13px; }
.map-popup { min-width:180px; display:flex; flex-direction:column; gap:3px; }
.map-popup>b { font-size:9px; }.map-popup>strong { margin-top:2px; font-size:10px; }.map-popup>span { color:#6f6975; font-size:8px; }.map-popup>em { margin-top:4px; color:var(--violet-dark); font-size:8px; font-style:normal; font-weight:700; }
.map-popup-actions { display:grid; grid-template-columns:1fr 1fr; gap:5px; margin-top:7px; }
.map-popup-actions a,.map-popup-actions button { min-height:29px; border:0; border-radius:6px; display:grid; place-items:center; background:#f0edfb; color:var(--violet-dark); font-size:8px; font-weight:800; text-decoration:none; cursor:pointer; }
.map-popup-actions a { background:#fff0e8; color:#a94827; }
.map-error { height:100%; display:grid; place-items:center; padding:30px; color:#7d7782; font-size:11px; text-align:center; }
.leaflet-control-attribution { font-size:7px!important; }

/* Shift staffing */
.courier-grid { grid-template-columns:repeat(3,1fr); }
.courier-grid article { position:relative; min-height:88px; padding:13px 14px 13px 38px; transition:opacity .2s,background .2s; }
.courier-grid article:nth-child(3n) { border-right:0; }
.courier-grid article:nth-child(-n+3) { border-bottom:1px solid var(--line); }
.courier-grid article.off-shift { opacity:.58; background:#faf9fb; }
.shift-check { position:absolute; left:12px; top:17px; cursor:pointer; }
.shift-check input { position:absolute; opacity:0; pointer-events:none; }
.shift-check span { width:16px; height:16px; display:grid; place-items:center; border:1px solid #cfc9d4; border-radius:5px; background:#fff; }
.shift-check input:checked+span { border-color:var(--violet); background:var(--violet); }
.shift-check input:checked+span::after { content:"✓"; color:#fff; font-size:10px; font-weight:800; }
.zone-select { margin-left:auto; display:flex; flex-direction:column; gap:3px; min-width:74px; }
.zone-select small { color:#9a949e; font-size:7px; }
.zone-select select { width:100%; height:27px; border:1px solid #e0dce4; border-radius:7px; background:#fff; padding:0 5px; color:#514b56; font-size:8px; outline:none; }
.zone-select select:focus { border-color:var(--violet); box-shadow:0 0 0 2px #6049d71a; }
.zone-select select:disabled { background:#f2f0f3; }
.order-main>span em.timed { color:#a94827; background:#fff0e8; }
.order-main>span em.evening-order { color:#705514; background:#fff1c7; }
.courier-grid>article.dedicated-duty { border-color:#e2c66d; background:#fffdf7; }
.duty-moon { width:19px; height:19px; border-radius:7px; display:grid; place-items:center; color:#705514; background:#fff1c7; font-size:10px; }
.duty-zone { display:flex; flex-direction:column; gap:3px; min-width:115px; }
.duty-zone small { color:#8d8792; font-size:7px; }
.duty-zone b { color:#554817; font-size:8px; }
.dedicated-label { color:#705514; background:#fff1c7; border-radius:5px; padding:4px 6px; font-size:7px; font-weight:800; }

@media(max-width:1050px){.courier-grid{grid-template-columns:repeat(2,1fr)}.courier-grid article:nth-child(3n){border-right:1px solid var(--line)}.courier-grid article:nth-child(2n){border-right:0}.courier-grid article:nth-child(-n+4){border-bottom:1px solid var(--line)}}
@media(max-width:650px){.courier-grid{grid-template-columns:1fr}.courier-grid article{border-right:0!important;border-bottom:1px solid var(--line)}.map-route-legend{max-height:96px;overflow:auto}.map-route-legend>span{min-width:105px}.map-toolbar .map-title{max-width:62%}}

/* Deferred orders and duty courier */
.deferred-panel { margin-bottom:12px; border-color:#f1cdbf; }
.deferred-alert,.duty-note { color:#b34c2a!important; background:#fff0e9; padding:5px 8px; border-radius:7px; font-size:8px!important; font-weight:700; }
.deferred-list { display:grid; grid-template-columns:repeat(2,1fr); }
.deferred-list article { min-height:70px; padding:11px 13px; display:grid; grid-template-columns:30px 1fr auto auto; align-items:center; gap:9px; border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.deferred-list article:nth-child(2n) { border-right:0; }
.deferred-list p { margin:0; display:flex; flex-direction:column; gap:2px; }
.deferred-list p strong { font-size:9px; }.deferred-list p small { color:#85808a; font-size:8px; }.deferred-list p em { color:#b34c2a; font-size:7px; font-style:normal; }
.deferred-list label { display:flex; flex-direction:column; gap:3px; }.deferred-list label small { color:#928d96; font-size:7px; }
.deferred-list input { height:28px; border:1px solid #dfdbe3; border-radius:6px; padding:0 6px; font-size:8px; }
.deferred-list button { border:0; border-radius:7px; background:var(--violet); color:#fff; height:29px; padding:0 8px; font-size:8px; font-weight:700; cursor:pointer; }
.courier-grid article { flex-wrap:wrap; }
.courier-actions { width:100%; display:flex; justify-content:space-between; align-items:center; padding-top:7px; border-top:1px solid #eeeaf0; }
.courier-actions a { color:var(--violet); font-size:8px; font-weight:700; text-decoration:none; }
.duty-radio { display:flex; align-items:center; gap:5px; cursor:pointer; }
.duty-radio input { accent-color:var(--violet); }.duty-radio span { color:#6f6975; font-size:8px; font-weight:650; }

/* Courier mobile workspace */
.courier-body { min-height:100vh; background:#f4f2f6; }
.courier-top { height:66px; max-width:1180px; margin:0 auto; padding:0 24px; display:flex; justify-content:space-between; align-items:center; }
.courier-brand { padding:0; text-decoration:none; color:var(--ink); }
.dispatcher-link { color:var(--violet); font-size:10px; font-weight:700; text-decoration:none; }
.courier-shell { max-width:1180px; margin:0 auto; padding:0 24px 40px; }
.courier-hero { min-height:96px; padding:18px 20px; display:flex; align-items:center; gap:18px; border-radius:16px; color:#fff; background:#292531; }
.courier-person { display:flex; align-items:center; gap:12px; }.courier-person .avatar { width:52px; height:52px; flex-basis:52px; color:#292531; font-size:14px; }
.courier-person p,.courier-person h1 { margin:0; }.courier-person p { color:#aaa4b4; font-size:8px; }.courier-person h1 { margin:2px 0 4px; font-size:21px; }.courier-person span { color:#d2cdd8; font-size:9px; }
.duty-badge { margin-left:auto; padding:7px 10px; border:1px solid #6f667a; border-radius:8px; background:#393342; color:#f3cf74; font-size:9px; font-weight:700; }
.start-route { height:36px; border:0; border-radius:9px; padding:0 14px; background:var(--violet); color:#fff; font-size:9px; font-weight:800; cursor:pointer; }
.start-route.started { background:var(--green); }
.courier-stats { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; margin:12px 0; }
.courier-stats article { min-height:65px; padding:12px 14px; border:1px solid var(--line); border-radius:11px; background:#fff; display:flex; flex-direction:column; gap:5px; }
.courier-stats small { color:#88828d; font-size:8px; }.courier-stats strong { font-size:16px; }
.courier-layout { display:grid; grid-template-columns:1.15fr .85fr; gap:12px; }
.courier-map-card,.courier-orders-card { min-height:580px; }
.courier-map { height:516px; }
.courier-route-list { max-height:516px; overflow:auto; }
.route-reorder-toolbar{position:sticky;top:0;z-index:15;display:grid;grid-template-columns:1fr auto auto auto;align-items:center;gap:7px;padding:9px 12px;border-bottom:1px solid #d9d1ee;background:#f0edfb;box-shadow:0 7px 18px #362a5714}
.route-reorder-toolbar[hidden]{display:none}
.route-reorder-toolbar>div{min-width:0;display:flex;flex-direction:column;gap:2px}.route-reorder-toolbar b{overflow:hidden;font-size:10px;text-overflow:ellipsis;white-space:nowrap}.route-reorder-toolbar span{color:#766e82;font-size:8px}
.route-reorder-toolbar button{height:34px;border:1px solid #d5ccec;border-radius:8px;padding:0 10px;background:#fff;color:var(--violet-dark);font-size:9px;font-weight:800;cursor:pointer}.route-reorder-toolbar button:disabled{opacity:.4;cursor:default}.route-reorder-toolbar #route-selection-close{width:34px;padding:0;color:#776f7d;font-size:18px}
.courier-route-list>article { display:grid; grid-template-columns:30px 1fr; gap:10px; padding:13px 14px; border-bottom:1px solid var(--line); }
.courier-route-list>article.route-reorderable{cursor:pointer;transition:background .16s,box-shadow .16s,transform .16s}.courier-route-list>article.route-reorderable:active{transform:scale(.994)}
.courier-route-list>article.route-selected{position:relative;z-index:2;background:#f0edfb!important;box-shadow:inset 4px 0 0 var(--violet),inset 0 0 0 2px #8b78e8}
.route-order-hint{margin-left:auto;color:var(--violet);font-size:8px;font-weight:800;white-space:nowrap}
.courier-route-list>article.timed-stop { background:#fffaf7; }
.stop-number { width:29px; height:29px; display:grid; place-items:center; border-radius:50% 50% 50% 5px; color:#fff; font-size:10px; font-weight:800; }
.stop-content>div:first-child { display:flex; align-items:center; gap:5px; }.stop-content b { font-size:9px; }.stop-content em { color:#a94827; background:#fff0e8; padding:2px 4px; border-radius:3px; font-size:7px; font-style:normal; }.stop-content em.evening { color:#705514; background:#fff1c7; }
.stop-content>strong { display:block; margin-top:5px; font-size:11px; }.stop-content p { margin:3px 0; color:#6f6974; font-size:9px; }.stop-content>small { color:#918b95; font-size:8px; }
.stop-note { display:block; margin-top:5px; color:#6f6974; font-size:8px; font-style:normal; }
.map-reassign { display:flex; flex-direction:column; gap:4px; margin-top:8px; padding-top:8px; border-top:1px solid #e7e2ea; }
.map-reassign span { color:#77717b; font-size:8px; font-weight:700; }
.map-reassign select { width:100%; height:31px; border:1px solid #d9d3df; border-radius:7px; padding:0 7px; background:#fff; color:#3f3944; font-size:9px; cursor:pointer; }
.stop-actions { margin-top:9px; display:flex; gap:6px; }.stop-actions button { height:29px; border-radius:7px; padding:0 9px; font-size:8px; font-weight:700; cursor:pointer; }
.complete-stop { border:0; background:#e7f7f0; color:#087653; }.defer-stop { border:1px solid #e0dce3; background:#fff; color:#706a74; }
.stop-actions a.yandex-stop { height:29px; border-radius:7px; padding:0 9px; display:flex; align-items:center; background:#ffdd3d; color:#292531; font-size:8px; font-weight:800; text-decoration:none; }
.stop-actions a.call-stop { height:29px; border-radius:7px; padding:0 9px; display:flex; align-items:center; background:#e4f7ef; color:#087653; font-size:8px; font-weight:800; text-decoration:none; }.stop-phone{display:inline-flex;margin-top:6px;color:#087653;font-size:9px;font-weight:800;text-decoration:none}.phone-missing{color:#b04d4d!important}
.evening-panel { margin-top:12px; }.evening-list { display:grid; grid-template-columns:repeat(2,1fr); }
.evening-list article { padding:12px 15px; display:flex; align-items:center; gap:12px; border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.evening-list article:nth-child(2n) { border-right:0; }.evening-list p { margin:0; display:flex; flex-direction:column; gap:3px; }.evening-list strong { font-size:9px; }.evening-list small { color:#807a84; font-size:8px; }
.evening-list button { margin-left:auto; border:0; border-radius:7px; background:#fff1c7; color:#765811; height:30px; padding:0 9px; font-size:8px; font-weight:700; cursor:pointer; }
.empty-route { min-height:120px; display:grid; place-content:center; gap:5px; padding:20px; text-align:center; color:#827c86; }.empty-route b { color:#4d4751; font-size:11px; }.empty-route span { font-size:9px; }
.transfer-modal { width:min(420px,calc(100% - 28px)); border:0; border-radius:16px; padding:0; box-shadow:0 25px 80px #201b294d; }
.transfer-modal::backdrop { background:#211c2b88; backdrop-filter:blur(3px); }.transfer-modal form { padding:24px; display:flex; flex-direction:column; gap:12px; }
.transfer-modal h2,.transfer-modal p { margin:0; }.transfer-modal h2 { font-size:18px; }.transfer-modal p { color:#77717b; font-size:9px; }.modal-icon { width:36px; height:36px; display:grid; place-items:center; border-radius:10px; background:#fff0e9; color:#b34c2a; }
.transfer-modal label { display:flex; flex-direction:column; gap:5px; color:#655f69; font-size:9px; }.transfer-modal select,.transfer-modal input { height:38px; border:1px solid #ddd8e1; border-radius:8px; padding:0 9px; background:#fff; font-size:10px; }
.transfer-modal form>div:last-child { display:flex; gap:8px; margin-top:4px; }.transfer-modal form>div:last-child button { flex:1; height:38px; border-radius:8px; font-size:9px; font-weight:750; cursor:pointer; }
.modal-cancel { border:1px solid #ded9e2; background:#fff; }.modal-confirm { border:0; background:var(--violet); color:#fff; }
.courier-toast { position:fixed; z-index:2000; left:50%; bottom:24px; transform:translate(-50%,20px); opacity:0; pointer-events:none; padding:10px 14px; border-radius:9px; background:#292531; color:#fff; font-size:9px; font-weight:650; transition:.2s; box-shadow:0 8px 25px #201b2944; }
.courier-toast.show { opacity:1; transform:translate(-50%,0); }

@media(max-width:850px){.courier-layout{grid-template-columns:1fr}.courier-map-card,.courier-orders-card{min-height:0}.courier-map{height:440px}.courier-route-list{max-height:none}.deferred-list{grid-template-columns:1fr}.deferred-list article{border-right:0}}
@media(max-width:560px){.courier-top,.courier-shell{padding-left:14px;padding-right:14px}.courier-hero{align-items:flex-start;flex-wrap:wrap}.duty-badge{order:3;margin-left:64px}.start-route{margin-left:auto}.courier-stats{grid-template-columns:repeat(2,1fr)}.courier-map{height:380px}.evening-list{grid-template-columns:1fr}.evening-list article{border-right:0}.deferred-list article{grid-template-columns:30px 1fr}.deferred-list label,.deferred-list button{grid-column:2}}

/* Working sidebar navigation */
.drawer-backdrop { position:fixed; z-index:1090; inset:0; background:#211c2b66; opacity:0; pointer-events:none; transition:opacity .2s; backdrop-filter:blur(2px); }
.drawer-backdrop.open { opacity:1; pointer-events:auto; }
.nav-drawer { position:fixed; z-index:1100; top:0; right:0; width:min(440px,calc(100% - 40px)); height:100vh; padding:0; background:#fff; box-shadow:-20px 0 60px #2a233533; transform:translateX(105%); transition:transform .25s ease; overflow:auto; }
.nav-drawer.open { transform:translateX(0); }
.nav-drawer>header { position:sticky; top:0; z-index:2; height:76px; padding:0 20px; display:flex; justify-content:space-between; align-items:center; border-bottom:1px solid var(--line); background:#fffffff2; backdrop-filter:blur(8px); }
.nav-drawer>header div { display:flex; flex-direction:column; gap:3px; }.nav-drawer>header small { color:#98929c; font-size:8px; }.nav-drawer>header h2 { font-size:16px; }
.nav-drawer>header button { width:32px; height:32px; border:1px solid #e2dde5; border-radius:8px; background:#fff; color:#6f6973; font-size:18px; cursor:pointer; }
.drawer-content { padding:18px 20px 28px; }.drawer-content h3 { margin:22px 0 10px; font-size:10px; }
.drawer-summary { display:flex; justify-content:space-between; align-items:center; margin-bottom:14px; text-transform:capitalize; }.drawer-summary strong { font-size:13px; }.drawer-summary span { color:var(--violet); font-size:8px; font-weight:700; }
.mini-calendar { display:grid; grid-template-columns:repeat(7,1fr); gap:5px; }.mini-calendar>em { padding:5px 0; color:#9a949e; font-size:7px; font-style:normal; text-align:center; }
.mini-calendar>button,.mini-calendar>span { min-height:45px; border:1px solid #ece8ef; border-radius:7px; background:#fff; padding:5px; display:flex; flex-direction:column; gap:4px; cursor:pointer; }.mini-calendar>span { border-color:transparent; }
.mini-calendar>button b { font-size:8px; }.mini-calendar>button i { color:var(--violet); font-size:6px; font-style:normal; }.mini-calendar>button.today { border-color:var(--violet); background:#f1eefd; }
.drawer-note { margin-top:14px; padding:10px 12px; border-radius:8px; background:#f5f3f7; color:#736d78; font-size:8px; line-height:1.5; }
.drawer-metrics { display:grid; grid-template-columns:repeat(3,1fr); gap:8px; }.drawer-metrics article { padding:12px; border:1px solid var(--line); border-radius:9px; display:flex; flex-direction:column; gap:5px; }.drawer-metrics small { color:#928c96; font-size:7px; }.drawer-metrics strong { font-size:18px; }
.analytics-bars { display:flex; flex-direction:column; gap:10px; }.analytics-bars>span { display:grid; grid-template-columns:65px 1fr 18px; align-items:center; gap:8px; }.analytics-bars b,.analytics-bars em { font-size:8px; font-style:normal; }.analytics-bars>span>i { height:6px; border-radius:4px; background:#eeeaf0; overflow:hidden; }.analytics-bars u { display:block; height:100%; border-radius:4px; }
.zone-load { display:grid; grid-template-columns:repeat(2,1fr); gap:7px; }.zone-load span { padding:10px; border-radius:8px; background:#f5f3f7; display:flex; justify-content:space-between; }.zone-load b { font-size:8px; }.zone-load small { color:#89838d; font-size:7px; }
.settings-group { padding:14px; border:1px solid var(--line); border-radius:10px; margin-bottom:10px; }.settings-group h3 { margin:0 0 12px; }.settings-group>label { min-height:42px; display:flex; flex-direction:column; gap:5px; margin-top:9px; }.settings-group>label>span { color:#77717b; font-size:8px; }
.settings-group input:not([type=checkbox]),.settings-group select { height:34px; border:1px solid #dfdbe3; border-radius:7px; padding:0 8px; background:#fff; font-size:9px; }
.order-card-form { display:flex; flex-direction:column; gap:10px; }
.order-workflow { padding:12px; border:1px solid #e1dde5; border-radius:10px; background:#f7f5f8; }
.order-workflow.order-deferred { background:#fff5c7; border-color:#e9d47c; }.order-workflow.order-completed { background:#e2f7ec; border-color:#adddc7; }.order-workflow.order-overdue { background:#ffe1e1; border-color:#e8aaaa; }.order-workflow.order-rescheduled { background:#ffe2f1; border-color:#eab0ce; }.order-workflow.order-stopped { background:#eee4ff; border-color:#cbb4ed; }
.order-workflow>header { display:flex; justify-content:space-between; gap:8px; margin-bottom:10px; }.order-workflow>header b { font-size:9px; }.order-workflow>header span { color:#746e78; font-size:8px; }
.order-workflow>div { display:grid; grid-template-columns:1fr auto auto; align-items:end; gap:6px; }.order-workflow label { display:flex; flex-direction:column; gap:4px; }.order-workflow label span { color:#77717b; font-size:7px; }.order-workflow input { height:32px; border:1px solid #d8d2dc; border-radius:7px; padding:0 7px; background:#fff; font-size:8px; }
.order-workflow button { height:32px; border:0; border-radius:7px; padding:0 9px; font-size:8px; font-weight:800; cursor:pointer; }.order-workflow #card-transfer { background:#f2dc79; color:#58470b; }.order-workflow .complete-order { background:#159b72; color:#fff; }.order-workflow .confirm-order { grid-column:1/-1; background:#d94c4c; color:#fff; }
.order-card-address { display:flex; align-items:center; gap:10px; padding:14px; border-radius:11px; background:#2c2732; color:#fff; }
.order-card-address>div { min-width:0; display:flex; flex:1; flex-direction:column; gap:4px; }.order-card-address small { color:#bdb7c4; font-size:7px; }.order-card-address strong { font-size:10px; line-height:1.4; }
.order-card-address>a { width:58px; height:55px; border-radius:10px; display:grid; place-content:center; gap:2px; background:#ffdd3d; color:#292531; text-align:center; text-decoration:none; }.order-card-address>a b { font-size:18px; }.order-card-address>a span { font-size:7px; font-weight:800; }
.profile-match-note { display:flex; gap:8px; padding:10px 11px; border:1px solid #dceee6; border-radius:9px; background:#f0faf6; }.profile-match-note b { flex:0 0 auto; color:#087653; font-size:8px; }.profile-match-note span { color:#61736b; font-size:7px; line-height:1.45; }
.order-card-section { padding:13px; border:1px solid var(--line); border-radius:10px; }.order-card-section h3 { margin:0 0 11px; display:flex; align-items:center; gap:6px; font-size:10px; }.order-card-section h3 em { color:#9a949e; font-size:7px; font-style:normal; font-weight:500; }
.order-card-section label { display:flex; flex-direction:column; gap:4px; }.order-card-section label span { color:#77717b; font-size:7px; }.order-card-section input,.order-card-section select,.order-card-section textarea { width:100%; border:1px solid #ddd8e1; border-radius:7px; padding:0 8px; background:#fff; color:#413b46; font:inherit; font-size:9px; }.order-card-section input,.order-card-section select { height:34px; }.order-card-section textarea { padding-top:8px; resize:vertical; }
.order-fields { display:grid; grid-template-columns:1fr 1fr; gap:9px; }.order-card-section>.wide { margin-bottom:9px; }.wide-field { grid-column:1/-1; }
.phone-input-action{display:grid;grid-template-columns:1fr auto;gap:7px}.phone-input-action>a{height:34px;padding:0 12px;border-radius:7px;display:flex;align-items:center;background:#e4f7ef;color:#087653;font-size:8px;font-weight:800;text-decoration:none}
.save-profile { height:40px; border:0; border-radius:9px; background:var(--violet); color:#fff; font-size:9px; font-weight:800; cursor:pointer; }.save-profile:disabled { opacity:.65; }
.order-history { margin-top:18px; }.order-history>header { display:flex; justify-content:space-between; align-items:center; margin-bottom:8px; }.order-history h3 { margin:0; font-size:11px; }.order-history>header span { color:#8c8690; font-size:8px; }
.order-history article { min-height:54px; padding:9px 5px; border-bottom:1px solid var(--line); display:flex; align-items:center; gap:9px; }.order-history article p { margin:0; display:flex; flex:1; flex-direction:column; gap:3px; }.order-history article b { font-size:9px; }.order-history article small { color:#8d8791; font-size:7px; }.order-history article>em { color:#087653; background:#e7f7f0; border-radius:5px; padding:3px 5px; font-size:7px; font-style:normal; }
.messenger-future { margin-top:14px; padding:11px 12px; border-radius:9px; background:#f5f3f7; display:flex; flex-direction:column; gap:4px; }.messenger-future b { font-size:8px; }.messenger-future span { color:#7b7580; font-size:7px; line-height:1.45; }
.client-stop-toggle { position:relative; min-height:34px; padding:6px 9px; border:1px solid #ddd8e1; border-radius:7px; }.client-stop-toggle input { position:absolute; inset:0; opacity:0; cursor:pointer; }.client-stop-toggle b { font-size:9px; }.client-stop-toggle:has(input:checked) { background:#eee4ff; border-color:#c8afea; color:#6737a4; }
.client-base-tools { position:sticky; top:76px; z-index:1; display:flex; align-items:center; gap:8px; padding:0 0 12px; background:#fff; }.client-base-tools input { flex:1; height:36px; border:1px solid #ded9e2; border-radius:8px; padding:0 10px; font-size:9px; }.client-base-tools span { color:#817b85; font-size:8px; }
.client-base-list { display:flex; flex-direction:column; }.client-base-list>button { width:100%; min-height:68px; border:0; border-bottom:1px solid var(--line); background:#fff; padding:9px 5px; display:flex; align-items:center; gap:10px; text-align:left; cursor:pointer; }.client-base-list>button:hover { background:#faf9fd; }.client-base-list>button.stopped { background:#eee4ff; }
.client-avatar { width:34px; height:34px; flex:0 0 auto; border-radius:10px; display:grid; place-items:center; background:#e7e0fb; color:#5e3bb1; font-size:12px; font-weight:800; }.client-base-list p { min-width:0; margin:0; flex:1; display:flex; flex-direction:column; gap:3px; }.client-base-list p b { font-size:9px; }.client-base-list p small { overflow:hidden; color:#7f7983; font-size:7px; text-overflow:ellipsis; white-space:nowrap; }.client-base-list p em { color:#159b72; font-size:7px; font-style:normal; }.client-base-list>button.stopped p em,.client-base-list>button.stopped>i { color:#7338ad; }.client-base-list>button>i { color:#817b85; font-size:7px; font-style:normal; }
.workflow-label:empty { display:none; }
.setting-switch { flex-direction:row!important; justify-content:space-between; align-items:center; border-top:1px solid #f0edf2; padding-top:9px; }
.setting-switch>span { display:flex; flex-direction:column; gap:2px; }.setting-switch b { color:#4c4650; font-size:9px; }.setting-switch small { color:#96909a; font-size:7px; }
.setting-switch input { position:absolute; opacity:0; }.setting-switch i { width:32px; height:18px; padding:2px; border-radius:10px; background:#d5d0d8; transition:.2s; }.setting-switch i::after { content:""; display:block; width:14px; height:14px; border-radius:50%; background:#fff; transition:.2s; box-shadow:0 1px 3px #302a3933; }.setting-switch input:checked+i { background:var(--violet); }.setting-switch input:checked+i::after { transform:translateX(14px); }
.save-settings { width:100%; height:38px; border:0; border-radius:9px; background:var(--violet); color:#fff; font-size:9px; font-weight:800; cursor:pointer; }
@media(max-width:560px){.nav-drawer{width:calc(100% - 22px)}.drawer-content{padding-left:14px;padding-right:14px}.mini-calendar{gap:3px}.mini-calendar>button,.mini-calendar>span{min-height:39px;padding:4px}}

/* Admin, new order, calendar and client database */
.calendar-toolbar{display:grid;grid-template-columns:34px 1fr 34px;align-items:center;gap:8px;margin-bottom:12px;text-align:center;text-transform:capitalize}.calendar-toolbar button{height:32px;border:1px solid var(--line);border-radius:8px;background:#fff;cursor:pointer}.calendar-toolbar strong{font-size:12px}
.calendar-day-list{margin-top:14px}.calendar-day-list>p{color:#817b85;font-size:8px}.calendar-day-list>button{width:100%;padding:9px 4px;border:0;border-bottom:1px solid var(--line);background:#fff;display:flex;flex-direction:column;gap:3px;text-align:left;cursor:pointer}.calendar-day-list b{font-size:9px}.calendar-day-list span{color:#817b85;font-size:8px}.calendar-recurring{padding:8px;border-radius:7px;background:#ffe2f1;color:#9c3569!important}
.admin-couriers{display:flex;flex-direction:column;gap:8px}.admin-couriers article{padding:10px;border:1px solid var(--line);border-radius:9px;display:grid;grid-template-columns:1.2fr 1fr 1fr auto;gap:6px}.admin-couriers input,.admin-couriers select{height:34px;min-width:0;border:1px solid #ddd8e1;border-radius:7px;padding:0 7px;background:#fff;font-size:8px}.admin-name{display:grid;grid-template-columns:1fr 48px;gap:5px}.admin-remove{border:0;border-radius:7px;background:#ffe5e5;color:#a73a3a;font-size:8px;cursor:pointer}.admin-add{width:100%;height:36px;margin:10px 0;border:1px dashed #bdb2d7;border-radius:8px;background:#faf8ff;color:var(--violet);font-size:9px;font-weight:700;cursor:pointer}
.new-order-form{display:flex;flex-direction:column;gap:11px}.new-order-form>div{display:grid;grid-template-columns:1fr 1fr;gap:8px}.new-order-form label{display:flex;flex-direction:column;gap:5px;color:#6f6973;font-size:8px}.new-order-form input,.new-order-form select,.new-order-form textarea{border:1px solid #ddd8e1;border-radius:8px;padding:0 9px;background:#fff;font-size:9px}.new-order-form input,.new-order-form select{height:36px}.new-order-form textarea{padding-top:9px;resize:vertical}
.clients-page{min-height:100vh;background:#f4f2f6}.clients-shell{max-width:1180px;margin:auto;padding:24px}.clients-header{display:grid;grid-template-columns:180px 1fr auto;align-items:center;margin-bottom:18px}.clients-header .brand{color:var(--ink);text-decoration:none}.clients-header small{color:#928c96;font-size:8px}.clients-header h1{margin:3px 0;font-size:24px}.back-dispatcher{color:var(--violet);font-size:9px;font-weight:700;text-decoration:none}.clients-tools{padding:12px;display:grid;grid-template-columns:1fr 170px auto;gap:9px;align-items:center}.clients-tools input,.clients-tools select{height:38px;border:1px solid #ddd8e1;border-radius:8px;padding:0 10px;background:#fff;font-size:9px}.clients-tools strong{font-size:9px}.clients-cards{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;margin-top:12px}.client-card{padding:15px}.client-card.stopped{background:#eee4ff;border-color:#cbb4ed}.client-card>header{display:flex;align-items:center;gap:9px}.client-card>header>span{width:36px;height:36px;border-radius:10px;display:grid;place-items:center;background:#e7e0fb;color:#5e3bb1;font-weight:800}.client-card h2{margin:0;font-size:11px}.client-card header small{color:#159b72;font-size:7px}.client-card header a{margin-left:auto;color:var(--violet);font-size:8px;text-decoration:none}.client-card>p{margin:9px 0;color:#716b75;font-size:8px}.client-plan{display:flex;align-items:end;gap:8px;padding-top:10px;border-top:1px solid var(--line)}.client-plan label{flex:1;display:flex;flex-direction:column;gap:4px;color:#817b85;font-size:7px}.client-plan input{height:34px;border:1px solid #ddd8e1;border-radius:7px;padding:0 8px}.client-plan button{height:34px;border:0;border-radius:7px;padding:0 10px;background:var(--violet);color:#fff;font-size:8px;font-weight:750;cursor:pointer}.client-plan button:disabled{background:#a99eb0}.clients-empty{grid-column:1/-1;padding:50px;text-align:center;color:#817b85}
.client-phone,.max-phone{color:#087653;font-weight:800;text-decoration:none}
@media(max-width:760px){.admin-couriers article{grid-template-columns:1fr 1fr}.clients-header{grid-template-columns:1fr auto}.clients-header>div{grid-column:1/-1;grid-row:2;margin-top:15px}.clients-tools{grid-template-columns:1fr}.clients-cards{grid-template-columns:1fr}} 

/* Authentication */
.login-page{min-height:100vh;background:radial-gradient(circle at 20% 15%,#eee9ff 0,transparent 34%),linear-gradient(145deg,#f7f5f9,#ece8f0);color:var(--ink)}
.login-shell{min-height:100vh;display:grid;place-items:center;padding:24px}
.login-card{width:min(420px,100%);padding:34px;border:1px solid #e1dce5;border-radius:22px;background:#ffffffee;box-shadow:0 28px 80px #2b243428;backdrop-filter:blur(12px)}
.login-brand{display:flex;align-items:center;gap:10px;font-size:14px;font-weight:850}.login-brand .brand-mark{width:38px;height:38px}
.login-heading{margin:30px 0 24px}.login-heading p{margin:0 0 7px;color:var(--violet);font-size:9px;font-weight:800;text-transform:uppercase;letter-spacing:.09em}.login-heading h1{margin:0;font-size:29px}.login-heading span{display:block;margin-top:8px;color:#817a86;font-size:10px;line-height:1.5}
.login-card form{display:flex;flex-direction:column;gap:14px}.login-card label{display:flex;flex-direction:column;gap:6px;color:#625c67;font-size:9px;font-weight:700}.login-card input{height:46px;border:1px solid #dcd6e0;border-radius:11px;padding:0 13px;background:#fff;color:#302a34;font-size:14px;outline:none}.login-card input:focus{border-color:var(--violet);box-shadow:0 0 0 3px #6d58e81a}
.login-card form button{height:47px;border:0;border-radius:11px;background:var(--violet);color:#fff;font-size:11px;font-weight:850;cursor:pointer}.login-card form button:disabled{opacity:.65;cursor:wait}.login-error{padding:10px 12px;border-radius:9px;background:#ffe8e8;color:#9e3131;font-size:9px;line-height:1.45}.login-help{display:block;margin-top:18px;color:#98919c;font-size:8px;line-height:1.5}
.session-logout{position:fixed;z-index:1080;right:18px;bottom:18px;height:36px;padding:0 14px;border:1px solid #dcd6e0;border-radius:10px;background:#fff;color:#635d68;font-size:9px;font-weight:750;cursor:pointer;box-shadow:0 8px 24px #241d2c1f}.session-logout:hover{border-color:#baafc2;color:var(--violet)}.session-logout:disabled{opacity:.6}
@media(max-width:560px){.login-shell{padding:14px}.login-card{padding:25px 20px;border-radius:18px}.session-logout{right:12px;bottom:12px}}

/* MAX messenger inbox */
.max-connection{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:13px;border:1px solid #d9d3df;border-radius:11px;background:#f7f5f8}.max-connection.ready{border-color:#b9dfcf;background:#eef9f4}.max-connection>div{display:flex;flex-direction:column;gap:4px}.max-connection b{font-size:10px}.max-connection span{color:#77717b;font-size:8px}.max-connection button{height:34px;border:0;border-radius:8px;padding:0 10px;background:var(--violet);color:#fff;font-size:8px;font-weight:800;cursor:pointer}
.max-inbox-summary{display:flex;justify-content:space-between;gap:10px;margin:16px 0 9px}.max-inbox-summary b{font-size:10px}.max-inbox-summary span{color:#89828d;font-size:8px;text-align:right}.max-inbox-list{display:flex;flex-direction:column;gap:9px}.max-inbox-list.history{opacity:.72}
.max-inbox-card{padding:13px;border:1px solid #ddd8e1;border-radius:11px;background:#fff}.max-inbox-card.processed{background:#f7f6f8}.max-inbox-card>header{display:flex;justify-content:space-between;align-items:flex-start;gap:8px}.max-inbox-card>header div{display:flex;flex-direction:column;gap:3px}.max-inbox-card>header b{font-size:10px}.max-inbox-card>header span{color:#8b8590;font-size:7px}.max-inbox-card>header em{padding:4px 6px;border-radius:6px;background:#eeeafd;color:var(--violet-dark);font-size:7px;font-style:normal;font-weight:800}
.max-inbox-card pre{margin:11px 0;padding:10px;border-radius:8px;background:#f4f2f6;color:#514b56;font:9px/1.55 Inter,"Segoe UI",Arial,sans-serif;white-space:pre-wrap;overflow-wrap:anywhere}.max-parsed-fields{display:grid;grid-template-columns:1fr 1fr;gap:7px}.max-parsed-fields>span{min-width:0;padding:8px;border:1px solid #ece8ef;border-radius:7px;display:flex;flex-direction:column;gap:3px}.max-parsed-fields .wide{grid-column:1/-1}.max-parsed-fields small{color:#928b96;font-size:7px}.max-parsed-fields b{font-size:9px;line-height:1.35}.max-missing,.max-ready{margin:9px 0 0;padding:8px 9px;border-radius:7px;font-size:8px;line-height:1.4}.max-missing{background:#fff1df;color:#8d5b16}.max-ready{background:#eaf8f2;color:#087653}
.max-inbox-card footer{display:grid;grid-template-columns:auto 1fr;gap:7px;margin-top:10px}.max-inbox-card footer button{min-height:36px;border:1px solid #ddd8e1;border-radius:8px;padding:0 10px;background:#fff;color:#6f6974;font-size:8px;font-weight:750;cursor:pointer}.max-inbox-card footer .max-create-order{border:0;background:var(--violet);color:#fff}.max-inbox-empty,.max-inbox-loading{min-height:170px;display:grid;place-content:center;gap:6px;padding:24px;color:#807a85;text-align:center}.max-inbox-empty b{color:#4d4652;font-size:11px}.max-inbox-empty span,.max-inbox-loading{font-size:9px}.max-prefill-note{padding:10px 11px;border-radius:8px;background:#eeeafd;display:flex;flex-direction:column!important;gap:3px!important}.max-prefill-note b{color:var(--violet-dark);font-size:9px}.max-prefill-note span{color:#766e82;font-size:8px}

/* Phone workspace */
html{-webkit-text-size-adjust:100%}
button,a,input,select,textarea{touch-action:manipulation}

@media(max-width:780px){
  body{overflow-x:hidden;padding-bottom:calc(72px + env(safe-area-inset-bottom))}
  .shell{display:block;min-width:0}
  .sidebar{position:fixed;inset:auto 0 0 0;width:100%;height:calc(68px + env(safe-area-inset-bottom));padding:5px 6px env(safe-area-inset-bottom);display:block;border:0;border-top:1px solid var(--line);box-shadow:0 -8px 30px #30283a14;z-index:1050}
  .sidebar .brand,.sidebar .side-bottom{display:none}
  .sidebar nav{height:100%;display:flex;flex-direction:row;gap:3px;overflow-x:auto;scrollbar-width:none}
  .sidebar nav::-webkit-scrollbar{display:none}
  .sidebar .nav-item{position:relative;min-width:68px;height:57px;padding:5px 4px;display:flex;flex-direction:column;justify-content:center;gap:3px;font-size:8px;line-height:1.05;text-align:center;white-space:nowrap}
  .sidebar .nav-item span{width:auto;font-size:19px;line-height:20px}
  .sidebar .nav-item b{display:none}
  .sidebar .nav-item #max-inbox-badge:not([hidden]){position:absolute;top:3px;right:7px;width:18px;min-width:18px;height:18px;display:grid;border:2px solid #fff;background:#e34c4c;color:#fff;font-size:8px}
  .workspace{width:100%;max-width:none;padding:17px 12px 28px}
  .topbar{gap:10px;margin-bottom:16px}
  .topbar h1{max-width:235px;font-size:20px}
  .top-actions{flex:0 0 auto}
  .stats{gap:8px}
  .stats article{padding:11px 12px}
  .stats small{font-size:9px;line-height:1.25}
  .stats strong{font-size:21px}
  .notice{align-items:flex-start;flex-direction:column;gap:10px;padding:13px}
  .notice>span{display:none}
  .notice button{width:100%;min-height:44px}
  .hub-strip{gap:12px;padding:13px}
  .hub-address{width:100%}
  .hub-address strong{font-size:11px;line-height:1.35}
  .route-rules{display:grid;grid-template-columns:1fr;gap:8px}
  .route-rules>span{border-left:0;padding:0}
  .panel-head{min-height:56px;padding:11px 13px;gap:8px}
  .panel-head h2{font-size:13px}
  .panel-head span{font-size:9px;line-height:1.35}
  .filters,.zone-filters{padding-left:11px;padding-right:11px;overflow-x:auto;flex-wrap:nowrap;scrollbar-width:none}
  .filters::-webkit-scrollbar,.zone-filters::-webkit-scrollbar{display:none}
  .filters button,.zone-filters button{min-height:36px;flex:0 0 auto}
  .order-row{padding:13px 12px;gap:10px}
  .order-main b{font-size:12px;line-height:1.35}
  .order-main>small,.order-side small{font-size:10px;line-height:1.35}
  .order-main>span strong,.order-main>span small,.order-main>span em,.status{font-size:9px}
  .order-side>span{font-size:11px}
  .map-panel{min-height:430px}
  #real-map,.map{min-height:430px}
  .map-toolbar{top:9px;left:9px;right:9px;gap:7px}
  .map-toolbar button{height:40px}
  .map-toolbar .map-title{max-width:60%;font-size:9px}
  .rebuild-btn{padding:0 10px!important;font-size:9px}
  .map-route-legend{left:8px;right:8px;bottom:8px;max-height:78px;display:flex;flex-wrap:nowrap;overflow-x:auto;overflow-y:hidden;pointer-events:auto;scrollbar-width:none}
  .map-route-legend::-webkit-scrollbar{display:none}
  .map-route-legend>span{min-width:124px;flex:0 0 auto;padding:7px 8px}
  .map-popup{min-width:210px}
  .map-popup>b,.map-popup>strong{font-size:12px}
  .map-popup>span,.map-popup>em{font-size:10px}
  .map-popup-actions a,.map-popup-actions button{min-height:42px;font-size:10px}
  .courier-grid article{padding-top:14px;padding-bottom:14px;min-height:104px}
  .courier-info strong{font-size:12px}.courier-info small,.courier-actions a,.duty-radio span{font-size:10px}
  .zone-select select{height:40px;font-size:11px}.zone-select small{font-size:9px}
  .nav-drawer{width:100%;max-width:none;height:100dvh}
  .drawer-content{padding-bottom:calc(28px + env(safe-area-inset-bottom))}
  .session-logout{bottom:calc(78px + env(safe-area-inset-bottom));height:42px;padding:0 15px;font-size:10px}
}

@media(max-width:560px){
  .primary-btn{width:44px;height:44px;min-width:44px;font-size:0;border-radius:12px}
  .primary-btn::after{content:"＋";font-size:21px;line-height:1}
  .stats{grid-template-columns:repeat(2,minmax(0,1fr))}
  .stats article{min-height:82px}
  .dashboard-grid{gap:10px}
  .map-panel{order:1}
  .orders-panel{order:2}
  .deferred-alert,.duty-note{font-size:9px!important}
  .order-workflow>div{grid-template-columns:1fr 1fr}
  .order-workflow label{grid-column:1/-1}
  .order-workflow button{height:44px;font-size:10px}
  .order-fields,.new-order-form>div{grid-template-columns:1fr}
  .wide-field{grid-column:auto}
  .admin-couriers article{grid-template-columns:1fr}
  .admin-remove{min-height:42px}
  .clients-shell{padding:16px 12px 88px}
  .clients-header{display:flex;align-items:flex-start;flex-wrap:wrap;gap:10px}
  .clients-header .brand{padding:0}
  .clients-header>div{width:100%;order:3;margin:4px 0 0}
  .clients-header h1{font-size:21px}
  .back-dispatcher{margin-left:auto;min-height:40px;display:flex;align-items:center;font-size:10px}
  .clients-tools input,.clients-tools select{height:46px;font-size:16px}
  .client-card{padding:14px}.client-card h2{font-size:13px}.client-card>p{font-size:10px;line-height:1.4}
  .client-plan{display:grid;grid-template-columns:1fr}.client-plan input{height:44px;font-size:16px}.client-plan button{height:44px;font-size:10px}
  .max-connection{align-items:flex-start;flex-direction:column}.max-connection span{font-size:10px}.max-connection button{width:100%;height:44px;font-size:10px}
  .max-inbox-summary{align-items:flex-start;flex-direction:column}.max-inbox-summary b{font-size:12px}.max-inbox-summary span{font-size:10px;text-align:left}
  .max-inbox-card{padding:12px}.max-inbox-card>header b{font-size:12px}.max-inbox-card>header span,.max-inbox-card>header em{font-size:9px}.max-inbox-card pre{font-size:11px}.max-parsed-fields small{font-size:9px}.max-parsed-fields b{font-size:11px}.max-missing,.max-ready{font-size:10px}.max-inbox-card footer{grid-template-columns:1fr}.max-inbox-card footer button{min-height:44px;font-size:10px}
}

@media(max-width:600px){
  .courier-body{padding-bottom:22px}
  .courier-top{height:58px;padding:0 12px}
  .courier-brand .brand-mark{width:32px;height:32px}.courier-brand{font-size:15px}
  .dispatcher-link{font-size:10px}
  .courier-shell{padding:0 10px 30px}
  .courier-hero{min-height:0;padding:15px;gap:12px;border-radius:14px}
  .courier-person{width:100%}
  .courier-person .avatar{width:48px;height:48px;flex-basis:48px}
  .courier-person p{font-size:10px}.courier-person h1{font-size:22px}.courier-person span{font-size:11px}
  .duty-badge{order:2;width:100%;margin:0;font-size:10px;text-align:center}
  .start-route{order:3;width:100%;height:48px;margin:0;font-size:12px}
  .courier-stats{gap:8px;margin:9px 0}
  .courier-stats article{min-height:76px;padding:12px}
  .courier-stats small{font-size:10px;line-height:1.25}.courier-stats strong{font-size:20px}
  .courier-layout{gap:9px}
  .courier-map-card,.courier-orders-card{border-radius:13px}
  .courier-map{height:330px}
  .courier-route-list>article{grid-template-columns:36px 1fr;gap:10px;padding:15px 12px}
  .route-reorder-toolbar{top:0;grid-template-columns:1fr 1fr 42px;gap:7px;padding:10px;box-shadow:0 8px 22px #362a5724}
  .route-reorder-toolbar>div{grid-column:1/-1}.route-reorder-toolbar b{font-size:12px}.route-reorder-toolbar span{font-size:10px}
  .route-reorder-toolbar button{height:46px;padding:0 8px;font-size:11px}.route-reorder-toolbar #route-selection-close{width:42px}
  .stop-number{width:34px;height:34px;font-size:12px}
  .stop-content>div:first-child{flex-wrap:wrap}
  .route-order-hint{width:100%;margin:3px 0 0;font-size:10px}
  .stop-content b{font-size:11px}.stop-content em{font-size:9px}
  .stop-content>strong{font-size:14px;line-height:1.35}
  .stop-content p{font-size:12px;line-height:1.35}.stop-content>small,.stop-note{font-size:10px;line-height:1.4}
  .stop-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:12px}
  .stop-actions button,.stop-actions a.yandex-stop,.stop-actions a.call-stop{height:44px;justify-content:center;padding:0 8px;font-size:10px}
  .stop-actions a.yandex-stop{grid-column:1/-1}
  .map-reassign span{font-size:10px}.map-reassign select{height:44px;font-size:12px}
  .transfer-modal{width:calc(100% - 20px);border-radius:15px}
  .transfer-modal form{padding:20px 16px}.transfer-modal p,.transfer-modal label{font-size:11px}
  .transfer-modal select,.transfer-modal input{height:48px;font-size:16px}
  .transfer-modal form>div:last-child{display:grid;grid-template-columns:1fr}
  .transfer-modal form>div:last-child button{height:46px;font-size:11px}
  .courier-body .session-logout{top:9px;right:10px;bottom:auto;height:40px;box-shadow:none}
  .courier-toast{bottom:18px;width:calc(100% - 24px);padding:13px 14px;font-size:11px;text-align:center}
  .login-page{padding-bottom:0}
  .login-shell{min-height:100dvh;padding:14px 12px calc(14px + env(safe-area-inset-bottom))}
  .login-card{padding:25px 18px;border-radius:18px}
  .login-heading{margin:24px 0 20px}.login-heading h1{font-size:26px}.login-heading span{font-size:12px}
  .login-card label{font-size:11px}.login-card input{height:52px;font-size:16px}.login-card form button{height:52px;font-size:13px}
  .login-error{font-size:11px}.login-help{font-size:10px}
}
