*{box-sizing:border-box}body{margin:0;background:#f4f5f0;color:#163b32;font-family:system-ui,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif}header{height:94px;max-width:1040px;margin:auto;padding:24px 32px;display:flex;align-items:center;justify-content:space-between}.brand{display:flex;gap:13px;align-items:center;color:inherit;text-decoration:none}.brand>b{font-size:36px;letter-spacing:-3px}.brand>b span{color:#89a537;font-size:28px}.brand>span{font-size:11px;letter-spacing:2px;font-weight:800;border-left:1px solid #bac8bc;padding-left:13px}.brand small{font-size:8px;letter-spacing:1px;font-weight:500}.tag{border:1px solid #c9d3c7;border-radius:20px;padding:7px 13px;font-size:12px}main{width:min(100% - 36px,460px);margin:30px auto}.eyebrow{font-size:10px;font-weight:750;letter-spacing:2px;color:#677b63}h1{font-size:36px;line-height:1.14;letter-spacing:-1.4px;margin:13px 0}p{line-height:1.55;color:#66756e;font-size:14px}.intro>p{margin-bottom:24px}.demo{font-size:11px;color:#78652f;background:#eee9d5;border:1px solid #e0d9bd;padding:9px 12px;border-radius:8px;margin-bottom:14px}.card{background:white;padding:26px;border:1px solid #e0e5dc;border-radius:19px;box-shadow:0 8px 25px #173b3206}.section-top{display:flex;gap:13px;align-items:center;margin-bottom:26px}.step{background:#eaf0dc;color:#4e6e25;font-size:13px;font-weight:750;padding:13px;border-radius:12px}h2{font-size:20px;letter-spacing:-.5px;margin:0}.section-top p{margin:3px 0 0;font-size:12px}label{display:block;font-size:13px;font-weight:650;margin:20px 0 8px}input,select{width:100%;min-height:52px;border:1px solid #ccd5cd;border-radius:9px;background:white;padding:12px;color:#183e32;font:inherit;font-size:16px}input[readonly]{background:#f4f6f1;color:#6a786f}.km-wrap{position:relative}.km-wrap input{padding-right:50px;font-size:24px;font-weight:650}.km-wrap>span{position:absolute;right:16px;top:18px;color:#7b867f;font-size:13px}.help{font-size:11px;margin:8px 0 0}.notice{background:#f5f7f1;border-radius:9px;padding:13px;font-size:12px;line-height:1.6;margin:21px 0;color:#566b59}button{width:100%;min-height:54px;border:0;border-radius:10px;background:#183f32;color:white;font:inherit;font-size:15px;font-weight:650;cursor:pointer;padding:15px 18px}button span{float:right}button:disabled{opacity:.55;cursor:wait}button:hover:enabled{background:#295b44}.center{text-align:center}.ahead{padding:27px 2px}h3{font-size:12px;font-weight:650}ol{display:flex;padding:0;list-style:none;justify-content:space-between;gap:6px}li{font-size:10px;color:#79867d;display:flex;align-items:center;gap:5px}li span{border:1px solid #ccd4c8;width:23px;height:23px;border-radius:50%;display:grid;place-items:center}.current{color:#294d36;font-weight:700}.current span{background:#dfe9c7;border-color:#dfe9c7}footer{text-align:center;font-size:10px;color:#889286;margin:6px 0 25px}footer span{margin:0 8px}#error{color:#a33225;font-size:13px}#error:empty,#connection:empty{display:none}#connection{background:#fff0d0;padding:12px;font-size:13px;border-radius:8px;margin-bottom:14px}.success-mark{font-size:30px;background:#eaf0dc;width:60px;height:60px;display:grid;place-items:center;border-radius:50%;margin-bottom:20px}:focus-visible{outline:3px solid #91af51;outline-offset:3px}[hidden]{display:none!important}@media(max-width:480px){header{padding:18px;height:80px}main{margin-top:20px}h1{font-size:32px}.card{padding:22px}li{font-size:9px}}

@media(max-width:360px){header{flex-wrap:wrap;height:auto;gap:10px}.brand>span{font-size:9px;letter-spacing:1px}.brand small{font-size:7px}.tag{font-size:10px;padding:5px 9px}.card{padding:18px}ol{flex-wrap:wrap;row-gap:10px}li{flex-basis:45%}}
header .tag{width:auto;min-height:36px;background:transparent;color:#183f32}#login-button{margin-top:24px}textarea{width:100%;font:inherit;font-size:16px;border:1px solid #ccd5cd;border-radius:9px;padding:12px;color:#183e32;resize:vertical}fieldset{border:0;padding:0;margin:18px 0}legend{font-size:13px;font-weight:650;margin-bottom:8px}.choice{display:flex;align-items:center;gap:10px;border:1px solid #d4dccf;padding:12px;border-radius:8px;font-size:14px;min-height:50px;margin:8px 0}.choice:has(input:checked){background:#edf2df;border-color:#789544}.choice input{width:20px;min-height:20px;height:20px;flex-shrink:0;accent-color:#28563c}.check-item{border:1px solid #dce3d6;border-radius:12px;margin:14px 0;padding:14px}.check-item summary{font-size:14px;font-weight:650;cursor:pointer;min-height:40px;line-height:1.6}.item-status{display:block;font-size:11px;font-weight:500;color:#667956;padding-left:16px}.check-item p{font-size:12px}.check-item input[type=file]{font-size:12px;padding:10px;min-width:0}input[type=file]::file-selector-button{background:#e9efdd;border:0;border-radius:5px;padding:10px;margin-right:8px;color:#183e32}.photo-preview{width:100%;max-height:280px;object-fit:contain;border-radius:8px;margin:12px 0;background:#f1f3ed}.check-item button{margin-top:16px}.route-summary{font-size:12px;background:#f4f6ef;padding:10px;border-radius:6px}#progress{font-size:12px;font-weight:650;margin:16px 0}.secondary{background:#e9efdd;color:#183e32}.review-item{border-bottom:1px solid #dce3d6;padding:12px 0}main,.card,form,select,input{min-width:0}.check-item input[type=file]{max-width:100%}
#vehicle-gallery{margin-top:28px;padding-top:22px;border-top:1px solid #dce3d6}#photo-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}#photo-grid img{height:100px;margin:0;object-fit:cover}#photo-count{font-weight:650}#upload-photo{margin-top:12px}
#photo-grid figure{margin:0}#photo-grid figcaption{font-size:10px;color:#66756e;line-height:1.5;margin:4px 0 10px}
#delivery-section{padding-top:24px;margin-top:24px;border-top:1px solid #dce3d6}#delivery-content button{margin:18px 0}#delivery-section>details{margin-top:18px}#delivery-content h3{font-size:20px}
.signature-pad{display:block;width:100%;height:160px;border:2px dashed #98ac96;border-radius:10px;background:white;touch-action:none}.signature-pad+button{margin:8px 0}#delivery-content select{margin-bottom:12px}

.route-chart-row p{margin-bottom:4px}.route-chart-row progress{width:100%;height:18px;accent-color:#194c3e}

.brand .official-logo{display:block;width:86px;height:86px;object-fit:contain;background:#000;border-radius:8px;flex-shrink:0}header:has(.official-logo){height:auto;min-height:110px;padding-top:12px;padding-bottom:12px}@media(max-width:480px){.brand .official-logo{width:70px;height:70px}.brand>span{letter-spacing:1px;font-size:9px}header:has(.official-logo){min-height:94px}}

/* Navegação do motorista, disponível após autenticação. */
.driver-navigation{position:relative;margin-left:auto;flex-shrink:0}.driver-navigation #driver-menu-toggle{width:48px;min-height:48px;margin:0;padding:0;font-size:32px;line-height:1}.driver-navigation nav{position:absolute;right:0;top:56px;width:min(280px,85vw);z-index:20;background:#fff;border:1px solid #dce2d8;border-radius:14px;padding:10px;box-shadow:0 10px 35px #0003}.driver-navigation nav button{display:block;width:100%;text-align:left;margin:4px 0;background:#f4f6ef;color:#153d32;padding:12px;border-radius:8px}.driver-navigation nav button[aria-current=page]{background:#153d32;color:#fff}.driver-navigation nav p{margin:6px 10px 12px;font-weight:700;overflow-wrap:anywhere}.driver-navigation [hidden]{display:none!important}

.maps-link{display:block;text-align:center;margin:12px 0;padding:14px;border:1px solid #cdd8cf;border-radius:10px;text-decoration:none;color:#153d32;}

#delivery-overview{margin:16px 0 20px;padding:16px;border:1px solid #dde5db;border-radius:14px;background:#fafbf7}#delivery-overview small{display:block;line-height:1.45;font-size:12px;color:#52635b}.route-received{display:grid;gap:6px}.route-received>strong{font-size:30px;color:#153d32;overflow-wrap:anywhere}.route-chart-row{display:flex;align-items:center;gap:18px;margin:20px 0 14px}.route-pie{width:112px;height:112px;border-radius:50%;flex-shrink:0}.route-pie-legend{flex:1;min-width:0}.route-pie-legend>:is(div,button){display:grid;grid-template-columns:10px 1fr auto;align-items:center;gap:8px;margin:10px 0;font-size:14px}.route-pie-dot{width:10px;height:10px;border-radius:50%}@media(max-width:380px){.route-chart-row{gap:12px}.route-pie{width:84px;height:84px}.route-pie-legend>:is(div,button){font-size:12px}}

.route-expected{padding-bottom:16px;margin-bottom:16px;border-bottom:1px solid #dde5db}

/* Contagens da rota em destaque, inclusive em telas pequenas. */
.route-chart-row{display:grid;grid-template-columns:minmax(0,1fr);gap:8px;margin:10px 0;align-items:center}.route-chart-row>.route-pie-legend{grid-row:1;width:100%}.route-chart-row>.route-pie{grid-row:2;justify-self:center}.route-chart-row>.route-pie{width:80px;height:80px}
.route-pie-legend{flex:1 1 240px}
.route-pie-legend>:is(div,button){padding:14px;border:1px solid transparent;border-radius:12px;gap:10px;font-size:16px;font-weight:700;line-height:1.3}
.route-pie-legend>:is(div,button)>strong{font-size:36px;line-height:1.1;font-weight:800}
.route-pie-legend>.route-count-done{background:#e5f3eb;border-color:#91bba2;color:#124f38}
.route-pie-legend>.route-count-pending{background:#fff1bb;border-color:#d8b744;color:#634900}
.route-pie-legend>.route-count-other{background:#f8eae3;border-color:#d6ad99;color:#783c25}
@media(max-width:480px){.route-chart-row{grid-template-columns:minmax(0,1fr);gap:6px;margin:8px 0}.route-chart-row>.route-pie{width:60px;height:60px}.route-pie-legend>:is(div,button){padding:10px 8px;gap:6px;margin:6px 0;font-size:14px;grid-template-columns:8px minmax(0,1fr) auto}.route-pie-legend>:is(div,button)>strong{font-size:30px}.route-pie-dot{width:8px;height:8px}}

.route-pie-legend>.route-count-returned{background:#ffebee;border-color:#e6a1a8;color:#a01824}.route-pie-legend>.route-count-other{background:#edf0f4;border-color:#b4becb;color:#39475b}

.route-financial{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-bottom:10px}.route-financial .route-received{gap:3px;align-content:start}.route-financial .route-received>span{font-size:13px;font-weight:700}.route-financial .route-received>strong{font-size:22px}.route-financial .route-expected{padding:0;margin:0;border:0}#delivery-overview .route-financial small{font-size:11px}.route-payment-breakdown{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px 12px;margin:8px 0}.route-payment-breakdown>div{display:flex;flex-wrap:wrap;justify-content:space-between;gap:3px 6px;font-size:12px;border-bottom:1px solid #dde5db;padding:5px 0}.route-pie-legend>.route-count-partial{background:#fff0e2;border-color:#e4b17f;color:#8a4308}

.route-financial .route-remaining{grid-column:1/-1;background:#fff1bb;border:1px solid #d8b744;border-radius:10px;padding:10px;grid-template-columns:minmax(0,1fr) auto;align-items:center}.route-remaining small{grid-column:1/-1}.route-financial .route-remaining>strong{color:#634900}

.route-productivity{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;margin-bottom:12px;padding-bottom:12px;border-bottom:1px solid #dde5db;font-size:13px}.route-productivity>strong{color:#17634d;font-size:17px}.route-productivity>progress{grid-column:1/-1;width:100%;height:12px;accent-color:#17634d}.route-productivity>small{grid-column:1/-1}
.route-final-km-alert{margin:0 0 16px;padding:18px;border:2px solid #c36a28;border-radius:12px;background:#fff3e5;color:#643616}.route-final-km-alert strong{display:block;font-size:18px}.route-final-km-alert p{margin:9px 0 14px;font-size:14px;line-height:1.45}.route-final-km-alert button{width:100%}

.daily-verse{margin:10px 0 14px;padding:10px 12px;border-left:3px solid #d8b744;background:#faf8ed;border-radius:0 8px 8px}.daily-verse>span{font-size:10px;text-transform:uppercase;letter-spacing:.7px;color:#64715f}.intro .daily-verse>p{margin:4px 0;font-size:14px;line-height:1.4;color:#153d32}.daily-verse>a{font-size:11px;color:#52635b;text-decoration:none}
/* Início compacto: somente o resumo, sem afetar os formulários das entregas. */
body:has(#day-dashboard:not([hidden])) header{height:58px;min-height:58px;padding:5px 18px}
body:has(#day-dashboard:not([hidden])) .brand .official-logo{width:46px;height:46px}
body:has(#day-dashboard:not([hidden])) main{margin:4px auto 8px;width:min(100% - 24px,460px)}
body:has(#day-dashboard:not([hidden])) .daily-verse{margin:4px 0 6px;padding:5px 9px}
body:has(#day-dashboard:not([hidden])) .daily-verse>span{display:none}
body:has(#day-dashboard:not([hidden])) .intro .daily-verse>p{font-size:13px;margin:0 0 2px}
body:has(#day-dashboard:not([hidden])) .intro>h1{font-size:22px;margin:5px 0}
body:has(#day-dashboard:not([hidden])) .intro>#subtitle{display:none}
body:has(#day-dashboard:not([hidden])) .demo{padding:3px 8px;margin-bottom:5px;font-size:10px}
body:has(#day-dashboard:not([hidden])) #driver-main-card{padding:10px 12px;border-radius:12px}
body:has(#day-dashboard:not([hidden])) .section-top{margin-bottom:4px}
body:has(#day-dashboard:not([hidden])) .section-top .step,body:has(#day-dashboard:not([hidden])) #section-title{display:none}
#day-dashboard>h2{display:none}
#day-dashboard #delivery-overview{margin:0 0 7px;padding:0;border:0;background:transparent}
#day-dashboard .route-productivity{margin-bottom:7px;padding-bottom:6px;gap:3px}
#day-dashboard .route-productivity>strong{font-size:15px}
#day-dashboard .route-productivity>small:last-child{display:none}
#day-dashboard .route-financial{gap:7px;margin-bottom:5px}
#day-dashboard .route-financial .route-received>strong{font-size:20px}
#day-dashboard .route-financial .route-received>span{font-size:12px}
#day-dashboard .route-financial small{display:none}
#day-dashboard .route-financial .route-remaining{padding:7px 9px}
#day-dashboard .route-payment-breakdown{gap:2px 10px;margin:4px 0}
#day-dashboard .route-payment-breakdown>div{padding:3px 0;font-size:11px}
#day-dashboard .route-chart-row{margin:5px 0;gap:4px}
#day-dashboard .route-pie-legend>:is(div,button){margin:4px 0;padding:6px 9px;font-size:13px;line-height:1.2}
#day-dashboard .route-pie-legend>:is(div,button)>strong{font-size:22px}
#day-dashboard .route-chart-row>.route-pie{width:38px;height:38px}
#day-dashboard #delivery-overview>small{font-size:10px;line-height:1.25}
#day-dashboard #go-deliveries{min-height:44px;padding:10px 14px}
body:has(#day-dashboard:not([hidden])) footer{display:none}

.route-privacy-bar{display:flex;align-items:center;justify-content:space-between;margin:0 0 5px;font-size:12px;font-weight:700}.route-privacy-bar .route-privacy-toggle{display:flex;align-items:center;justify-content:center;gap:5px;width:auto;min-height:44px;padding:6px 10px;background:#e9efdd;color:#183e32;font-size:12px}.route-privacy-toggle span{float:none}

/* Início em cartões de serviços, identidade DG. */
body:has(#driver-start:not([hidden])) header{background:#171b18;color:#fff;max-width:none;padding:8px max(16px,calc((100% - 460px)/2));height:64px;min-height:64px}
body:has(#driver-start:not([hidden])) .brand{color:#fff}
body:has(#driver-start:not([hidden])) .brand .official-logo{width:48px;height:48px}
body:has(#driver-start:not([hidden])) #driver-menu-toggle{background:#f7ce00;color:#171b18}
body:has(#driver-start:not([hidden])) main{margin:10px auto;width:min(100% - 24px,460px)}
body:has(#driver-start:not([hidden])) .intro>h1{font-size:22px;margin:8px 0;letter-spacing:-.4px}
body:has(#driver-start:not([hidden])) #subtitle,body:has(#driver-start:not([hidden])) .section-top,body:has(#driver-start:not([hidden])) footer{display:none}
body:has(#driver-start:not([hidden])) .daily-verse{padding:6px 10px;margin:5px 0}
body:has(#driver-start:not([hidden])) .daily-verse>span{display:none}
body:has(#driver-start:not([hidden])) .intro .daily-verse>p{font-size:13px;margin:0}
body:has(#driver-start:not([hidden])) .demo{padding:3px 8px;margin-bottom:8px;font-size:10px}
body:has(#driver-start:not([hidden])) #driver-main-card{padding:0;background:transparent;border:0;box-shadow:none}
.start-vehicle{display:flex;align-items:center;gap:10px;padding:14px;background:#fff;border:1px solid #dce3dc;border-radius:12px;margin-bottom:16px}.start-icon{background:#eef2e9;border-radius:50%;padding:9px;color:#536b57}.start-vehicle strong{font-size:17px}.start-vehicle p{margin:3px 0 0;font-size:12px}.start-active{margin-left:auto;background:#e2f3e8;color:#17634d;border-radius:20px;padding:5px 8px;font-size:11px}.start-help{margin:4px 0 10px;font-size:12px}#driver-start>h2{font-size:17px}
.start-services{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.start-services button{display:grid;align-content:start;gap:5px;text-align:left;background:#fff;color:#163b32;border:1px solid #dce3dc;border-radius:10px;padding:12px;min-height:95px}.start-services button:hover{background:#f7f4dc}.start-services button>span{float:none;color:#806900;font-size:20px;line-height:1}.start-services strong{font-size:13px}.start-services small{font-size:11px;color:#66756e;font-weight:400}.start-services .start-deliveries{grid-column:1/-1;background:#f7ce00;color:#202718;min-height:72px;grid-template-columns:28px 1fr;align-items:center}.start-deliveries>span{grid-row:1/3}.start-deliveries>small{grid-column:2}
#delivery-section{margin-top:8px;padding-top:8px;border:0}#delivery-content>.review-item{border:1px solid #dce3dc;border-radius:10px;padding:12px;margin:10px 0;background:#fff}#delivery-content>.review-item>summary{font-size:14px;font-weight:750;line-height:1.4;min-height:32px}

.day-map-canvas{height:360px;height:min(52dvh,420px);min-height:240px;border-radius:12px;margin:12px 0;z-index:0}.map-notice{font-size:12px;background:#fff4d6;padding:10px;border-radius:8px}.day-map-marker{background:#f7ce00;color:#172a20;border:2px solid #fff;border-radius:16px;padding:5px 8px;min-width:30px;max-width:160px;width:max-content!important;box-shadow:0 2px 6px #0004;font-weight:800;text-align:center;white-space:normal;overflow-wrap:anywhere}.day-map-done{background:#17634d;color:#fff}.day-map-stop{padding:12px 0;border-bottom:1px solid #dce3dc}.day-map-stop>p{margin:5px 0;font-size:12px}.day-map-stop>small{font-size:11px}.day-map-actions{display:flex;flex-wrap:wrap;gap:7px;margin-top:8px}.day-map-actions button,.day-map-actions a{width:auto;flex:1;min-height:44px;padding:10px 8px;font-size:12px;margin:0}.leaflet-popup-content p{font-size:12px}.leaflet-control-zoom a{color:#183f32}
.day-map-missing{background:#fff5e2;border:1px solid #e7c780;border-radius:10px;padding:10px 12px;margin:10px 0;color:#44320c}.day-map-missing p{font-size:12px;margin:5px 0}.day-map-missing summary{font-size:12px;font-weight:700;cursor:pointer}.day-map-missing details button{display:block;width:100%;margin:7px 0 0;text-align:left;white-space:normal}

.route-pie-legend>button{text-align:left;min-height:44px;cursor:pointer}.route-pie-legend>button span{float:none}.route-pie-legend>button:hover:enabled{filter:brightness(.97)}.route-pie-legend>button[aria-expanded=true]{outline:2px solid currentColor;outline-offset:1px}.productivity-orders{margin:10px 0;padding:12px;border:1px solid #dce3dc;border-radius:10px;background:#fff}.productivity-orders h3{font-size:15px;margin:0 0 8px}.productivity-order{padding:10px 0;border-bottom:1px solid #e5e9e0}.productivity-order:last-child{border:0}.productivity-order>strong{font-size:13px}.productivity-order>small{display:block}.productivity-order>p{font-size:12px;margin:5px 0}.productivity-order>button{min-height:44px;padding:8px;font-size:12px}

.map-location-editor{background:#fff4d6;border:1px solid #d8b744;border-radius:10px;padding:12px;margin-top:10px}.map-location-editor>p{font-size:12px;margin:6px 0}.map-location-editor>button{min-height:44px;margin:5px 0;padding:10px}.map-point-confirm{display:flex;align-items:center;gap:8px;margin:10px 0}.map-point-confirm input{width:22px;min-height:22px;height:22px;flex-shrink:0}.map-point-confirm span{font-size:12px}

/* Shared uppercase presentation for driver and manager screens. */
body,body *{text-transform:uppercase!important}input[type="password"],input[type="email"],input[type="url"]{text-transform:none!important}

.photo-actions{display:flex;gap:8px;margin:8px 0}.photo-actions button{flex:1;min-width:0;padding:12px 8px}

.camera-file-input{position:absolute!important;width:1px!important;height:1px!important;min-height:0!important;padding:0!important;border:0!important;overflow:hidden!important;clip-path:inset(50%);pointer-events:none}

.native-camera{position:relative;display:flex;align-items:center;justify-content:center;min-height:54px;border-radius:10px;background:#183f32;color:white;overflow:hidden;cursor:pointer;font-size:15px}.native-camera .camera-file-input{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;opacity:0;clip-path:none!important;pointer-events:auto!important;cursor:pointer}.native-camera:focus-within{outline:3px solid #91af51;outline-offset:3px}

.finish-step{border:1px solid #dce3d6;border-radius:12px;padding:14px;margin:14px 0}.finish-step>summary{cursor:pointer;font-weight:750;padding:8px 0}.finish-step:not([open]){background:#edf2df}

.route-pdf{display:flex;align-items:center;justify-content:center;min-height:48px;margin-top:16px;padding:10px 16px;border-radius:10px;background:#174f40;color:#fff;font-weight:800;text-decoration:none;text-align:center}.route-pdf:active{transform:translateY(1px)}

.route-report-actions{display:grid;gap:10px;margin-top:16px}.route-report-actions .route-pdf,.route-report-actions .route-share{width:100%;margin:0;box-sizing:border-box}.route-share{min-height:48px;border:2px solid #174f40;background:#fff;color:#174f40;border-radius:10px;font-weight:800}.route-share-status{margin:10px 0 0;font-size:14px}

.route-pdf-secondary{background:#fff!important;color:#174f40!important;border:2px solid #174f40}


#connection.offline-ready{background:#e8f3e5;color:#245f35;border:1px solid #bdd6b8;font-weight:700}

/* Visualizador do PDF de fechamento */
.pdf-viewer-page{margin:0;min-height:100dvh;background:#eef2ed;color:#153d32;display:flex;flex-direction:column}
.pdf-viewer-toolbar{position:sticky;top:0;z-index:10;display:grid;grid-template-columns:auto minmax(160px,1fr) auto;align-items:center;gap:14px;padding:12px max(14px,env(safe-area-inset-right)) 12px max(14px,env(safe-area-inset-left));background:#153d32;color:#fff;box-shadow:0 2px 12px #0003}
.pdf-viewer-toolbar button,.pdf-viewer-toolbar a{width:auto;margin:0;min-height:44px;padding:10px 14px;text-decoration:none;text-align:center;border-radius:10px}
.pdf-viewer-toolbar .secondary{background:#fff;color:#153d32;border:1px solid #d8e0da}
.pdf-viewer-title{display:flex;flex-direction:column;min-width:0}.pdf-viewer-title strong{font-size:1.05rem}.pdf-viewer-title span{font-size:.82rem;color:#e4eee8}
.pdf-viewer-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap}
.pdf-viewer-status{margin:0;padding:10px 16px;background:#fff3cf;color:#604f16;text-align:center}.pdf-viewer-status.ready{background:#e5f4e9;color:#185b3e}
.pdf-viewer-document{flex:1;min-height:0;padding:10px}.pdf-viewer-document iframe{display:block;width:100%;height:calc(100dvh - 142px);min-height:520px;border:0;border-radius:10px;background:#fff;box-shadow:0 2px 14px #173d3420}
@media(max-width:760px){.pdf-viewer-toolbar{position:relative;grid-template-columns:1fr}.pdf-viewer-title{order:-1;text-align:center}.pdf-viewer-actions{display:grid;grid-template-columns:1fr 1fr}.pdf-viewer-actions a{grid-column:1/-1}.pdf-viewer-toolbar>button{width:100%}.pdf-viewer-document{padding:0}.pdf-viewer-document iframe{height:calc(100dvh - 300px);min-height:480px;border-radius:0}}
@media print{.pdf-viewer-toolbar,.pdf-viewer-status{display:none!important}.pdf-viewer-document{padding:0}.pdf-viewer-document iframe{height:100vh;box-shadow:none}}

/* Correção do visualizador no celular */
@media(max-width:760px){
 .pdf-viewer-toolbar{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:10px!important;padding:14px!important}
 .pdf-viewer-title{order:-1;text-align:center;margin-bottom:2px}
 .pdf-viewer-actions{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:10px!important;width:100%!important}
 .pdf-viewer-toolbar button,.pdf-viewer-toolbar a,.pdf-viewer-actions button,.pdf-viewer-actions a{position:static!important;display:flex!important;align-items:center!important;justify-content:center!important;float:none!important;transform:none!important;width:100%!important;max-width:none!important;min-width:0!important;min-height:50px!important;margin:0!important;box-sizing:border-box!important;white-space:normal!important}
 .pdf-viewer-document iframe{height:70dvh;min-height:540px}
}

.route-finish-share{width:100%;margin-top:16px;min-height:54px;background:#174f40;color:#fff;border:0;font-size:16px}.route-share-hint{margin-top:10px}

/* Login limpo e saudacao do motorista apos autenticar. */
body:has(#login-form:not([hidden])) .intro,body:has(#login-form:not([hidden])) .demo,body:has(#login-form:not([hidden])) .ahead,body:has(#login-form:not([hidden]))>main>footer{display:none!important}
body:has(#login-form:not([hidden])) main{margin:clamp(36px,12vh,110px) auto;width:min(100% - 28px,460px)}
body:has(#login-form:not([hidden])) #driver-main-card{box-shadow:0 12px 34px #173b3215}
body:has(#driver-start:not([hidden])) .intro{background:#171b18;color:#fff;border-radius:14px;padding:12px 15px;margin:8px 0}
body:has(#driver-start:not([hidden])) .intro>h1{color:#fff;margin:0 0 6px}
body:has(#driver-start:not([hidden])) .intro .daily-verse{background:transparent;border-left-color:#f7ce00;margin:0;padding:4px 9px}
body:has(#driver-start:not([hidden])) .intro .daily-verse>p,body:has(#driver-start:not([hidden])) .intro .daily-verse>a{color:#fff}
/* A barra ocupa seu próprio espaço e nunca cobre o PDF. */
.pdf-viewer-toolbar{position:relative!important;top:auto!important;height:auto!important;min-height:0!important;max-width:none!important;width:100%!important;margin:0!important;flex-shrink:0}
.pdf-viewer-status{flex-shrink:0}.pdf-viewer-document{position:relative;z-index:0}
@media(max-width:760px){.pdf-viewer-toolbar{position:relative!important;height:auto!important}.pdf-viewer-document iframe{height:70dvh!important;min-height:480px!important}}

/* Identidade no acesso e saudacao no topo depois do login. */
body:has(#login-form:not([hidden]))>header{display:flex!important;justify-content:center;height:auto;min-height:112px;padding:14px 18px;background:#171b18;color:#fff}
body:has(#login-form:not([hidden]))>header .brand{color:#fff}
body:has(#login-form:not([hidden]))>header .brand .official-logo{width:76px;height:76px}
body:has(#login-form:not([hidden]))>header .brand>span{font-size:12px;line-height:1.5;letter-spacing:1.5px}
body:has(#login-form:not([hidden])) main{margin:24px auto 40px}
body:has(#driver-navigation:not([hidden])) .intro{background:#171b18;color:#fff;border-radius:14px;padding:12px 15px;margin:8px 0 12px}
body:has(#driver-navigation:not([hidden])) .intro>h1{color:#fff;margin:0 0 6px;font-size:24px;letter-spacing:-.4px}
body:has(#driver-navigation:not([hidden])) .intro>#subtitle{display:none}
body:has(#driver-navigation:not([hidden])) .intro .daily-verse{background:transparent;border-left-color:#f7ce00;margin:0;padding:4px 9px}
body:has(#driver-navigation:not([hidden])) .intro .daily-verse>span{color:#dce5df}
body:has(#driver-navigation:not([hidden])) .intro .daily-verse>p,body:has(#driver-navigation:not([hidden])) .intro .daily-verse>a{color:#fff}
@media(max-width:480px){body:has(#login-form:not([hidden]))>header .brand .official-logo{width:66px;height:66px}body:has(#login-form:not([hidden]))>header .brand>span{font-size:10px}}

/* Saudacao e mensagem diaria dentro do cabecalho autenticado. */
.driver-header-welcome{flex:1;min-width:0;margin:0 18px;padding:5px 14px;border-left:3px solid #f7ce00;color:#fff}
.driver-header-welcome>strong{display:block;font-size:18px;line-height:1.2;margin-bottom:3px}.driver-header-welcome>div{display:flex;align-items:baseline;gap:8px;min-width:0}.driver-header-welcome span{font-size:9px;font-weight:800;letter-spacing:.7px;text-transform:uppercase;color:#d4ddd7;flex-shrink:0}.driver-header-welcome p{margin:0;color:#fff;font-size:12px;line-height:1.35;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.driver-header-welcome a{font-size:10px;color:#f7ce00;text-decoration:none;flex-shrink:0}
body:has(#driver-header-welcome:not([hidden]))>header{background:#171b18;color:#fff;max-width:none;width:100%;height:auto;min-height:76px;padding:8px max(16px,calc((100% - 1040px)/2))}body:has(#driver-header-welcome:not([hidden]))>header .brand{color:#fff}body:has(#driver-header-welcome:not([hidden]))>header .official-logo{width:58px;height:58px}body:has(#driver-header-welcome:not([hidden])) .intro{display:none!important}body:has(#driver-header-welcome:not([hidden])) main{margin-top:14px}
@media(max-width:680px){body:has(#driver-header-welcome:not([hidden]))>header{display:grid;grid-template-columns:auto 48px;gap:7px 10px;padding:8px 12px}.driver-header-welcome{grid-column:1/-1;grid-row:2;margin:0;padding:6px 10px}.driver-navigation{grid-column:2;grid-row:1}.driver-header-welcome>strong{font-size:16px}.driver-header-welcome>div{display:block}.driver-header-welcome span{display:block;margin-bottom:2px}.driver-header-welcome p{font-size:12px;white-space:normal}.driver-header-welcome a{display:block;margin-top:2px}body:has(#driver-header-welcome:not([hidden]))>header .official-logo{width:48px;height:48px}}

.channel-start{margin:12px 0 20px}.channel-new-form{margin:16px 0 24px;padding:16px;border:1px solid #dce3dc;border-radius:12px;background:#fafbf7}.channel-new-form h3{font-size:18px;margin:0 0 10px}.channel-form-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:16px}.channel-form-actions button{margin:0}.channel-history{margin-top:20px;padding-top:16px;border-top:1px solid #dce3dc}.channel-history>h2{font-size:18px}

.photo-viewer{width:min(94vw,720px);max-width:720px;max-height:92dvh;padding:0;border:0;border-radius:14px;background:#f8faf6;color:#173f35;box-shadow:0 18px 70px #0008}.photo-viewer::backdrop{background:#07130fcc;backdrop-filter:blur(2px)}.photo-viewer-top{position:sticky;top:0;z-index:2;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;background:#171b18;color:#fff}.photo-viewer-top button{width:auto;min-height:44px;margin:0;padding:9px 14px;background:#f7ce00;color:#171b18}.photo-viewer>img{display:block;width:100%;max-height:calc(92dvh - 112px);object-fit:contain;background:#0d110f}.photo-viewer>p{margin:0;padding:8px 12px;text-align:center;font-size:11px}.photo-preview[src*="/api/v1/photos/"]{cursor:zoom-in}

.driver-header-actions{display:flex;align-items:center;gap:8px;margin-left:auto}.notification-bell{position:relative;width:48px;min-height:48px;margin:0;padding:0;background:#f7ce00;color:#171b18;font-size:20px}.notification-bell span{position:absolute;right:-5px;top:-5px;display:grid;place-items:center;min-width:22px;height:22px;padding:0 5px;border-radius:12px;background:#c62828;color:#fff;font-size:11px;font-weight:800}.notification-center{width:min(94vw,520px);max-height:88dvh;padding:0;border:0;border-radius:14px;background:#f8faf6;color:#173f35}.notification-center::backdrop{background:#07130fcc}.notification-top{display:flex;align-items:center;justify-content:space-between;padding:10px 12px;background:#171b18;color:#fff}.notification-top button{width:auto;min-height:44px;margin:0;background:#f7ce00;color:#171b18}.notification-center>#notification-status{padding:0 14px}.notification-center>#notification-read-all{width:calc(100% - 28px);margin:12px 14px}.notification-item{display:flex;flex-direction:column;align-items:flex-start;width:calc(100% - 28px);margin:8px 14px;padding:12px;background:#fff;color:#173f35;border:1px solid #dce3dc;text-align:left}.notification-item.unread{border-left:5px solid #f7ce00;background:#fffbed}.notification-item span,.notification-item small{float:none;margin-top:4px}.notification-item small{color:#66756e}@media(max-width:680px){.driver-header-actions{grid-column:2;grid-row:1}.driver-navigation{grid-column:auto;grid-row:auto}.notification-bell{width:42px;min-height:42px}.driver-header-actions .driver-navigation #driver-menu-toggle{width:42px;min-height:42px}}

/* Mantém sino e menu visíveis lado a lado no celular. */
@media(max-width:680px){body:has(#driver-header-welcome:not([hidden]))>header{grid-template-columns:minmax(0,1fr) auto!important}.driver-header-actions{display:flex!important;grid-column:2;grid-row:1;width:auto;margin-left:0;gap:6px}.driver-header-actions .notification-bell,.driver-header-actions #driver-menu-toggle{display:grid;place-items:center;flex:0 0 42px;width:42px!important;min-height:42px!important;padding:0!important}}

/* O sino acompanha obrigatoriamente o menu autenticado. */
.notification-bell{display:grid;grid-template-columns:auto auto;align-items:center;justify-content:center;gap:4px;width:auto!important;padding:0 10px!important}.notification-bell[hidden]{display:none!important}.notification-bell small{font-size:10px;font-weight:800}.notification-bell>span{float:none}@media(max-width:390px){.notification-bell{grid-template-columns:1fr!important;width:42px!important;padding:0!important}.notification-bell small{font-size:8px;line-height:1}}

/* Sino fixo e centralizado no cabeçalho do motorista. */
.driver-header-actions .notification-bell{display:flex;align-items:center;justify-content:center;flex:0 0 44px;width:44px!important;height:44px;min-height:44px;padding:0!important;border-radius:50%;font-family:"Apple Color Emoji","Segoe UI Emoji",sans-serif;font-size:21px;line-height:1;text-align:center}.driver-header-actions .notification-bell[hidden]{display:none!important}.driver-header-actions .notification-bell>span{position:absolute;right:-4px;top:-5px}

.delivery-location-confirm{margin:12px 0;padding:12px;border:1px solid #c8d9d2;border-radius:10px;background:#f3f8f5}.delivery-location-confirm p{margin:6px 0;font-size:13px}.delivery-location-confirm button{margin-top:6px}
.delivery-sequence-reasons{margin-top:12px;padding:12px;border:1px solid #dfbe42;border-radius:10px;background:#fffbed}.delivery-sequence-reasons p{margin:6px 0 10px;font-size:13px}.delivery-sequence-reasons button{width:100%;margin:6px 0;text-align:left}
.delivery-quick-facts{display:grid;gap:8px;margin:12px 0 16px;padding:12px;border:1px solid #d7e2d7;border-radius:10px;background:#f6f8f2}.delivery-quick-facts>div{display:flex;justify-content:space-between;align-items:baseline;gap:12px}.delivery-quick-facts span{font-size:11px;color:#53685b}.delivery-quick-facts strong{font-size:13px;text-align:right;color:#173f35;overflow-wrap:anywhere}.delivery-defer-options{margin:18px 0 4px;padding-top:14px;border-top:1px solid #dce4df}.delivery-defer-options .delivery-defer{display:block;width:100%;margin:0;background:#eef3e5;border:2px solid #58765d;color:#173f35;font-size:14px;font-weight:800;min-height:50px;border-radius:10px}.delivery-defer-options .help{display:block;margin-top:5px;font-size:11px}.finish-observations{margin:16px 0}

/* Preparação da saída em etapas */
.route-opening-steps{display:grid;gap:10px;margin-top:16px}.opening-step{border:1px solid #d8e0d7;border-radius:12px;background:#fafbf7;overflow:hidden}.opening-step[open]{background:#fff;border-color:#93aa9c;box-shadow:0 5px 18px #173b3210}.opening-step>summary{display:grid;grid-template-columns:34px minmax(0,1fr);gap:2px 10px;align-items:center;padding:14px;cursor:pointer;list-style:none}.opening-step>summary::-webkit-details-marker{display:none}.opening-step>summary>span{grid-row:1/3;display:grid;place-items:center;width:32px;height:32px;border-radius:50%;background:#e7ecdf;color:#173f35;font-weight:900}.opening-step>summary>strong{font-size:15px}.opening-step>summary>small{color:#66756e;font-size:11px}.opening-step.is-complete>summary>span{background:#173f35;color:#f5d000}.opening-step.is-complete>summary small{color:#28644e;font-weight:700}.opening-step-body{padding:0 14px 16px;border-top:1px solid #e6ebe4}.opening-step-body>button{margin-top:14px}

#delivery-section.delivery-focused>#back-dashboard,#delivery-section.delivery-focused>h2,#delivery-section.delivery-focused>#delivery-progress{display:none}#delivery-section.delivery-focused{margin-top:0;padding-top:0}#delivery-section.delivery-focused #delivery-content>.review-item{margin-top:4px}
body:has(#delivery-section.delivery-focused:not([hidden])) #driver-main-card>.section-top,body:has(#delivery-section.delivery-focused:not([hidden])) .demo{display:none}body:has(#delivery-section.delivery-focused:not([hidden])) #driver-main-card{padding:12px}

/* Recebimento compacto: uma etapa, sem salvar pagamentos separadamente. */
#delivery-content>.review-item:has(.finish-payment-active)>.delivery-quick-facts{display:none}
.finish-payment-active .finish-step{margin:0 0 8px;padding:5px 10px;border-radius:9px}
.finish-payment-active .finish-step>summary{padding:4px 0;font-size:12px}
.finish-payment-active .finish-payment-box h3{font-size:15px;margin:0 0 7px}
.finish-payment-summary{display:grid;grid-template-columns:1fr 1fr;gap:2px 8px;padding:8px 10px;margin-bottom:9px;border-radius:9px;background:#f3f7ee}
.finish-payment-summary>*{font-size:12px;line-height:1.3;margin:0;color:#173f35}
.finish-payment-summary>:last-child{grid-column:1/-1;color:#173f35}
.finish-payment-fields{display:grid;gap:7px}
.finish-payment-row{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr);gap:7px;align-items:center}
.finish-payment-row>select,.finish-payment-row>input{width:100%;min-width:0;min-height:46px;height:46px;padding:8px;font-size:13px}
.finish-payment-row>button{grid-column:1/-1;min-height:34px!important;padding:5px!important;font-size:11px!important}
.finish-payment-active .finish-add-payment{min-height:38px!important;margin:7px 0 0!important;padding:6px!important;font-size:12px!important}
.finish-payment-active .finish-observations{margin:8px 0;padding:8px 10px;border:1px solid #dce3d6;border-radius:9px}
.finish-payment-active .finish-observations>summary{font-size:12px;font-weight:700;cursor:pointer}
.finish-payment-active .finish-observations label{margin:8px 0 3px;font-size:11px}
.finish-payment-active .finish-observations textarea{min-height:58px;height:58px;padding:7px;font-size:13px}
#delivery-content .finish-payment-active>button[type=submit]{min-height:46px;margin:8px 0 0;font-size:14px;padding:8px}
body:has(.finish-payment-active) #driver-header-welcome{display:none!important}
body:has(.finish-payment-active) #driver-main-card{padding:8px 12px}
@media(max-width:360px){.finish-payment-row{grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr)}.finish-payment-row>select,.finish-payment-row>input{font-size:12px}}

/* Primeira etapa curta: resultado completo em uma tela comum de celular. */
@media(max-width:680px){
 body:has(.finish-result-short)>header{display:flex!important;align-items:center;min-height:58px!important;height:58px!important;padding:4px 10px!important}
 body:has(.finish-result-short) #driver-header-welcome{display:none!important}
 body:has(.finish-result-short) main{margin:6px auto 0}
 body:has(.finish-result-short) #connection.offline-ready{display:none}
 body:has(.finish-result-short) #connection:not(.offline-ready){margin:0 0 6px;padding:6px 8px;font-size:11px}
 body:has(.finish-result-short) #driver-main-card{padding:0;border:0;box-shadow:none;background:transparent}
 body:has(.finish-result-short) #delivery-content>.review-item{padding:10px 11px;margin:0;border-radius:12px}
 body:has(.finish-result-short) #delivery-content>.review-item>summary{min-height:28px;font-size:13px}
 body:has(.finish-result-short) .delivery-quick-facts{gap:3px;margin:7px 0;padding:8px}
 body:has(.finish-result-short) .delivery-quick-facts span{font-size:10px}
 body:has(.finish-result-short) .delivery-quick-facts strong{font-size:12px}
 .finish-result-short .finish-step{margin:7px 0;padding:8px 10px}
 .finish-result-short .finish-step>summary{padding:3px 0;font-size:14px}
 .finish-result-short .finish-step label{margin:8px 0 4px;font-size:11px}
 .finish-result-short .finish-step select,.finish-result-short .finish-step input:not([type=file]){min-height:44px;height:44px;padding:8px;font-size:14px}
 #delivery-content .finish-result-short .finish-step>button{min-height:48px;margin:10px 0 0;padding:8px;font-size:13px}
 body:has(.finish-result-short) .delivery-defer-options{margin:8px 0 0;padding-top:8px}
 body:has(.finish-result-short) .delivery-defer-options .delivery-defer{min-height:42px;font-size:12px;padding:7px}
 body:has(.finish-result-short) .delivery-defer-options .help{margin-top:3px;font-size:10px}
 body:has(.finish-result-short) footer{display:none}
}

/* Alinhamento do recebimento em duas colunas iguais. */
.finish-payment-summary{grid-template-columns:repeat(2,minmax(0,1fr));gap:0 8px;padding:0;overflow:hidden}
.finish-payment-summary>div{display:grid;align-content:center;gap:2px;min-width:0;padding:8px 10px}
.finish-payment-summary>div+div{border-left:1px solid #d8e5d3}
.finish-payment-summary span{font-size:10px;line-height:1.15;color:#54695a;font-weight:700}
.finish-payment-summary>div strong{font-size:16px;line-height:1.15;white-space:nowrap;color:#173f35}
.finish-payment-summary>p{grid-column:1/-1;margin:0;padding:5px 10px 7px;border-top:1px solid #d8e5d3;font-size:11px;font-weight:750;line-height:1.2}
.finish-payment-row{align-items:start}
#delivery-content .finish-payment-row>select,#delivery-content .finish-payment-row>input{margin:0!important;align-self:start}

#delivery-content .finish-payment-row>button{grid-column:2;justify-self:end;width:auto;min-height:28px!important;margin:0!important;padding:3px 8px!important;font-size:11px!important}

/* Lista de entregas: deixar somente a ação necessária e os pedidos. */
body:has(#delivery-section:not([hidden]):not(.delivery-focused)) #driver-home,
body:has(#delivery-section:not([hidden]):not(.delivery-focused)) .demo,
body:has(#delivery-section:not([hidden]):not(.delivery-focused)) #connection.offline-ready,
body:has(#delivery-section:not([hidden]):not(.delivery-focused)) #driver-main-card>.section-top,
#delivery-section:not(.delivery-focused)>h2,
#delivery-section:not(.delivery-focused)>#delivery-progress{display:none!important}
body:has(#delivery-section:not([hidden]):not(.delivery-focused)) #driver-main-card{padding:12px}
#delivery-section:not(.delivery-focused){margin:0;padding:0}
#delivery-section:not(.delivery-focused) #delivery-content>h3{margin:4px 0 12px}

#delivery-section:not(.delivery-focused)>#back-dashboard{min-height:42px;margin:0 0 12px;padding:8px 12px;font-size:13px}

/* Entrega parcial: primeira etapa compacta; identificação de quem recebeu na etapa seguinte. */
.finish-partial-active .finish-step>p{margin:5px 0;font-size:11px;line-height:1.3}
.finish-partial-active .finish-step label{margin:8px 0 3px;font-size:11px}
.finish-partial-active .finish-step .review-item{padding:8px;margin:7px 0}
.finish-partial-active .finish-step .review-item label{margin:5px 0 3px}
.finish-partial-active .finish-step .review-item input{min-height:42px;padding:8px}
.finish-partial-active .finish-step .review-item button{min-height:38px;margin:7px 0;padding:7px;font-size:12px}
.finish-receiver-box{margin:8px 0;padding:9px 10px;border:1px solid #dce3d6;border-radius:9px}
.finish-receiver-box label{margin:0 0 5px;font-size:12px}
.finish-receiver-box input{min-height:44px;padding:8px;font-size:14px}

/* Erro de validação visível junto ao botão Continuar. */
.finish-step-error{display:grid;gap:5px;margin:12px 0 2px;padding:14px 15px;border:2px solid #bb3426;border-radius:11px;background:#fff0eb;color:#762218;box-shadow:0 4px 12px #7b241b1a}
.finish-step-error strong{font-size:15px;line-height:1.2;letter-spacing:.2px}
.finish-step-error span{font-size:16px;font-weight:750;line-height:1.35}
.finish-step-error:focus{outline:3px solid #bb3426;outline-offset:2px}

/* Aviso de pagamento legível logo após Salvar atendimento. */
.finish-payment-error:empty{display:none}
.finish-payment-error:not(:empty){display:block;margin:10px 0 2px;padding:14px 15px;border:2px solid #bb3426;border-radius:11px;background:#fff0eb;color:#762218;font-size:16px;font-weight:750;line-height:1.35;box-shadow:0 4px 12px #7b241b1a}
.finish-payment-error:not(:empty)::before{content:'ATENÇÃO: FALTA PREENCHER';display:block;margin-bottom:5px;font-size:15px;line-height:1.2;letter-spacing:.2px}
.finish-payment-error:focus{outline:3px solid #bb3426;outline-offset:2px}

/* Desconto por avaria fica recolhido até o motorista optar por usá-lo. */
.finish-payment-active .finish-discount-toggle{min-height:38px!important;margin:7px 0 0!important;padding:6px!important;font-size:12px!important}
.finish-discount-box{margin:8px 0;padding:9px 10px;border:1px solid #dce3d6;border-radius:9px;background:#f8faf6}
.finish-discount-box label{margin:7px 0 4px;font-size:11px}
.finish-discount-box input:not([type=file]){min-height:44px;padding:8px;font-size:14px}
.finish-discount-box .photo-preview{max-height:120px;object-fit:contain}
.finish-payment-summary>p[hidden]{display:none}

.completed-delivery-entry{border-bottom:1px solid #dce3d6;padding-bottom:8px}.completed-delivery-entry>.review-item{border-bottom:0}.payment-adjustment{margin:0 0 8px;padding:8px 10px;border:1px solid #d7e4d4;border-radius:9px;background:#f7faf4}.payment-adjustment>summary{cursor:pointer;font-weight:750;color:#173f35}.payment-adjustment form{display:grid;gap:7px;margin-top:8px}.payment-adjustment .finish-payment-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:7px}.payment-adjustment .finish-payment-row>select,.payment-adjustment .finish-payment-row>input{width:100%;margin:0;min-height:44px}.payment-adjustment .finish-payment-row>button{grid-column:2;justify-self:end;width:auto}.payment-adjustment form>button{margin:2px 0}.payment-adjustment .finish-payment-error:empty{display:none}

.route-closing-panel{border:1px solid #dbe5dd;border-radius:14px;background:#fff;padding:15px;margin:10px 0}.route-closing-panel h3{margin:0 0 12px;font-size:19px;color:#173f35}.route-closing-panel h4{margin:16px 0 8px;color:#173f35}.route-closing-grid{display:grid;gap:0}.route-closing-grid>div{display:flex;justify-content:space-between;align-items:baseline;gap:12px;padding:8px 0;border-bottom:1px solid #e5ebe4;font-size:13px;line-height:1.3}.route-closing-grid>div span{color:#52645a}.route-closing-grid>div strong{text-align:right;color:#173f35;font-size:15px;white-space:nowrap}.route-closing-grid>.route-closing-total{margin-top:4px;padding:11px 0;border-top:2px solid #b4c8b5;font-weight:800}.route-closing-grid>.route-closing-total span,.route-closing-grid>.route-closing-total strong{color:#173f35;font-size:16px}.route-closing-grid>.route-closing-cash-expected{background:#f0f6e9;border-radius:8px;padding:10px 8px;margin-top:7px;border-bottom:0}.route-closing-reasons{margin-top:9px;font-size:12px}.route-closing-cash>form{margin-top:16px;border-top:1px solid #dbe5dd;padding-top:14px}.route-closing-cash>form label{font-weight:800}
.cash-count-declaration{display:flex!important;align-items:flex-start;gap:10px;margin:14px 0!important;padding:12px;border:1px solid #cbd9cf;border-radius:10px;background:#f7faf7;font-weight:650!important;line-height:1.4}.cash-count-declaration input{width:22px!important;min-height:22px!important;height:22px;margin:1px 0 0;padding:0;flex:0 0 22px;accent-color:#183f32}.cash-count-declaration span{font-size:13px}.cash-count-feedback{font-weight:750;color:#173f35}.route-closing-cash textarea{min-height:92px}

/* Checklist: keep every blocking item visible and actionable. */
#checklist-help.checklist-pending{border:2px solid #ba3729;background:#fff1eb;padding:18px;color:#782116;scroll-margin-top:120px}
#checklist-help.checklist-pending>strong{display:block;font-size:21px;line-height:1.25;font-weight:900}
#checklist-help.checklist-pending>p{font-size:16px;color:inherit;margin:8px 0;font-weight:650}
#checklist-help.checklist-pending ul{display:grid;gap:7px;margin:10px 0 0;padding:0;list-style:none}
#checklist-help.checklist-pending li{display:block;color:inherit;font-size:16px;font-weight:700;line-height:1.4}
#checklist-help .checklist-pending-link{display:block;text-align:left;width:100%;min-height:44px;padding:9px 10px;background:#fff;color:#782116;border:1px solid #e5aea4;font-size:16px;line-height:1.35;font-weight:750}
.check-item,#vehicle-gallery{scroll-margin-top:110px}
.delivery-order-hint{font-size:12px;margin:6px 0;color:#4c665d}
.delivery-order-feedback{font-size:14px;font-weight:750;margin:8px 0;color:#174d3c}
.delivery-order-feedback:empty{display:none}
.delivery-order-feedback[role=alert]{padding:12px;border:2px solid #ba3729;background:#fff1eb;color:#782116;border-radius:9px}
#delivery-content{overflow-anchor:none}
#delivery-content .delivery-reorderable{overflow-anchor:none}
#delivery-content .delivery-reorderable>summary{position:relative;min-height:44px;overflow-wrap:anywhere}
.delivery-order-controls{display:flex;align-items:center;justify-content:flex-end;grid-column:2;grid-row:1/3;align-self:center}
#delivery-content .delivery-order-controls button{width:39px;min-width:39px;min-height:44px;height:44px;margin:0;padding:3px;border:1px solid #c4d2c8;border-radius:8px;color:#174536;background:#edf4e9;font-size:21px;line-height:1}
#delivery-content .delivery-order-controls button:disabled{opacity:.3;cursor:default}
#delivery-content .delivery-order-controls .delivery-drag-handle{width:44px;min-width:44px;touch-action:none;user-select:none;-webkit-user-select:none;cursor:grab;background:#174536;color:white}
#delivery-content .delivery-reorderable.is-dragging{outline:3px solid #c99e19;box-shadow:0 5px 18px #203c3233;background:#fffced}
#delivery-content .delivery-reorderable.is-dragging .delivery-drag-handle{cursor:grabbing}


.finish-return-authorization{padding:12px;border:1px solid #ccdacf;border-radius:12px;background:#f4f8f4;margin:10px 0}
.finish-authorization-header{display:grid;gap:3px;margin-bottom:10px;min-width:0}.finish-authorization-header strong{font-size:13px;line-height:1.3}.finish-authorization-header small{font-size:11px;line-height:1.3;color:#52675a;overflow-wrap:anywhere}
.finish-authorization-row{display:grid;grid-template-columns:118px minmax(0,1fr);gap:10px;align-items:end}.finish-authorization-field{min-width:0}.finish-authorization-field>label{display:block;margin:0 0 5px;font-size:11px;line-height:1.3}.finish-authorization-field>input{box-sizing:border-box;display:block;width:100%;max-width:none;min-height:48px;height:48px;margin:0;padding:8px 10px;font-size:22px!important;letter-spacing:.22em;font-weight:800;font-variant-numeric:tabular-nums;text-align:center;border:1px solid #91ac98;border-radius:9px;background:#fff}.finish-authorization-field>input:focus{outline:2px solid #245c47;outline-offset:2px}
.finish-authorization-row>.finish-authorization-status{box-sizing:border-box;min-width:0;min-height:48px;margin:0;padding:9px;display:flex;align-items:center;font-size:12px;line-height:1.3;font-weight:650;color:#52675a;overflow-wrap:anywhere;border-radius:9px}
.finish-authorization-row>.finish-authorization-status[data-state="error"]{color:#852519;background:#fff0eb;border:2px solid #bb3426;font-size:15px;font-weight:800}.finish-authorization-row>.finish-authorization-status[data-state="valid"]{color:#174934;background:#e5f4df;border:1px solid #87ab76;font-size:14px;font-weight:800}.finish-authorization-row>.finish-authorization-status[data-state="pending"]{color:#42504a;background:#edf0ed}
.finish-return-authorization>button{width:auto;margin:10px 0 0;min-height:40px;padding:8px 12px;font-size:12px}.finish-return-authorization[hidden]{display:none!important}@media(max-width:350px){.finish-authorization-row{grid-template-columns:104px minmax(0,1fr);gap:7px}.finish-return-authorization{padding:10px}.finish-authorization-row>.finish-authorization-status{padding:7px}}

:is(#delivery-content,#delivery-list) .delivery-list-summary{display:grid;grid-template-columns:minmax(0,1fr);gap:5px 12px;padding:0;list-style:none;cursor:pointer;min-width:0;min-height:44px;align-content:center}
:is(#delivery-content,#delivery-list) .delivery-list-summary::-webkit-details-marker{display:none}#delivery-content .delivery-reorderable>.delivery-list-summary{grid-template-columns:minmax(0,1fr) 44px}
.delivery-list-title{grid-column:1;min-width:0;font-size:14px;font-weight:750;line-height:1.35;overflow-wrap:anywhere}.delivery-list-title::before{content:'▸ ';color:#365b48}details[open]>.delivery-list-summary>.delivery-list-title::before{content:'▾ '}
.delivery-list-address{display:block;grid-column:1;min-width:0;color:#596d61;font-size:12px;font-weight:500;line-height:1.45;overflow-wrap:anywhere}
@media(max-width:380px){:is(#delivery-content,#delivery-list) .delivery-list-summary{column-gap:9px}.delivery-list-title{font-size:13px}.delivery-list-address{font-size:11px}}

body .brand img.official-logo{background:transparent!important;border:0!important;border-radius:0!important;box-shadow:none!important;padding:0!important;object-fit:contain}

.destination-required{padding:16px;margin:0 0 18px;background:#edf5e5;border-left:5px solid #1b5745;border-radius:10px;color:#173f35}.destination-required h3{margin:0 0 8px;font-size:21px}.destination-required p{margin:0;font-size:15px;line-height:1.5}

#destination-picker{box-sizing:border-box;width:calc(100% - 28px);max-width:480px;max-height:90dvh;overflow:auto;border:0;border-radius:16px;padding:22px;color:#173f35;background:#fff}#destination-picker::backdrop{background:#14291dcc}#destination-picker h2{font-size:23px;line-height:1.25;margin:0 0 14px}#destination-picker select{width:100%;font-size:16px;min-height:50px}#destination-picker button{width:100%;margin:16px 0 0;min-height:52px}#destination-picker .picker-error{color:#a12020;font-weight:700;font-size:17px}

#driver-document-viewer{box-sizing:border-box;width:100%;max-width:100%;height:100dvh;max-height:100dvh;margin:0;padding:0;border:0;background:#f4f7f6;color:#173f35;overflow:hidden}#driver-document-viewer[open]{display:flex;flex-direction:column}#driver-document-viewer header{flex:none;background:#fff;padding:12px 16px;padding-top:max(12px,env(safe-area-inset-top));border-bottom:1px solid #d9e3df}#driver-document-viewer header button{margin:0;min-height:48px}#driver-document-viewer h2{font-size:18px;margin:8px 0 0}#driver-document-viewer .document-viewer-body{flex:1;min-height:0;overflow:auto;padding:12px;padding-bottom:max(12px,env(safe-area-inset-bottom))}#driver-document-viewer img{display:block;width:100%;height:auto;max-width:1000px;margin:auto}#driver-document-viewer iframe{display:block;width:100%;height:calc(100% - 100px);min-height:300px;border:0;background:white}#driver-document-viewer a{display:block;margin:8px 0 16px}
.finish-redelivery-box,.finish-missing-box{padding:12px;margin:10px 0;border:1px solid #d5ded9;border-radius:10px;background:#f5f8f6}.finish-redelivery-box p,.finish-missing-box p{margin:5px 0;color:#53655f}.finish-missing-box label{display:grid;grid-template-columns:minmax(0,1fr) 82px;align-items:center;gap:10px;margin:8px 0}.finish-missing-box input{margin:0;min-width:0}

/* Pagamento único de pedido e vasilhames, com etapas anteriores recolhidas. */
#delivery-content>.review-item:has(.finish-unified-ready)>.delivery-quick-facts{display:none}
.finish-unified-ready .rd-returnable-summary:not([hidden]){display:flex;justify-content:flex-start;padding:0;border:0;background:transparent;margin:10px 0}
.finish-unified-ready .rd-returnable-summary>strong{display:none}
.finish-unified-ready .rd-returnable-summary>button{max-width:100%;white-space:normal;min-height:42px}
.finish-unified-ready .returnable-driver:not(.rd-dialog-open){margin:0}
.finish-unified-ready>.finish-back{display:block;width:auto;min-height:40px;margin:0 0 12px!important;padding:8px 12px;font-size:13px}
.finish-unified-facts{display:grid;gap:8px;background:#f7f8f3;border:1px solid #dce3d6;border-radius:11px;padding:13px 14px;margin:0 0 17px}
.finish-unified-fact{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:13px}
.finish-unified-fact strong{font-size:16px;white-space:nowrap;font-variant-numeric:tabular-nums}
.finish-unified-facts small{font-size:11px;color:#65766a}
.finish-unified-ready .finish-payment-box h3{font-size:18px;margin:0 0 10px}
.finish-unified-ready .finish-payment-summary{border:1px solid #d5e0cf;border-radius:10px;background:#f0f5e9;margin-bottom:12px}
.finish-unified-ready .finish-payment-summary>div{padding:11px 13px}
.finish-unified-ready .finish-payment-summary span{font-size:11px;line-height:1.3}
.finish-unified-ready .finish-payment-summary strong{font-size:23px;line-height:1.3}
.finish-unified-ready .finish-payment-summary>p{font-size:12px;padding:7px 13px}
.finish-unified-ready .finish-payment-row>select,.finish-unified-ready .finish-payment-row>input{font-size:16px;min-height:48px;padding:9px 11px}
.finish-unified-ready .finish-payment-row>input{text-align:right;font-variant-numeric:tabular-nums}
.finish-unified-ready .finish-add-payment{min-height:41px!important;margin:9px 0 12px!important;font-size:13px!important}
.finish-unified-ready .finish-observations{padding:12px;margin:12px 0}
.finish-unified-ready .finish-observations>summary{font-size:12px}
#delivery-content .finish-unified-ready>button[type=submit]{min-height:50px;font-size:15px}

.finish-unified-ready .secondary:hover:enabled{background:#e9efdd;color:#183e32}
.finish-payment-labels{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr);gap:7px;margin:12px 0 6px;font-size:11px;font-weight:650;color:#617669}
@media(max-width:360px){.finish-payment-labels{grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr)}}

#connection strong{display:block}#connection p{margin:8px 0;overflow-wrap:anywhere}#connection .sync-actions{display:flex;flex-wrap:wrap;gap:8px}#connection .sync-actions button{flex:1 1 140px;min-height:44px;white-space:normal}

#connection details{width:100%}#connection summary{cursor:pointer;font-weight:700;padding:8px 0}#connection .sync-pending-list{max-height:200px;overflow:auto;margin:0;padding-left:18px;overflow-wrap:anywhere}#connection .sync-pending-list li{padding:6px 0}
/* Nome visível e mensagem breve no início; telas de trabalho priorizam a rotina. */
body:has(#driver-header-welcome:not([hidden])):not(:has(#driver-start:not([hidden]))) #driver-header-welcome>div{display:none}
body:has(#driver-header-welcome:not([hidden])):not(:has(#driver-start:not([hidden]))) #driver-header-welcome{padding-block:2px}
body:has(#driver-start:not([hidden])) #header-daily-text{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;white-space:normal}
@media(max-width:680px){
 body:has(#driver-header-welcome:not([hidden])) #driver-header-greeting{font-size:15px;line-height:1.25;margin-bottom:0}
 body:has(#driver-start:not([hidden])) .driver-header-welcome{padding:4px 10px}
 body:has(#driver-start:not([hidden])) .driver-header-welcome span{display:none}
 body:has(#driver-start:not([hidden])) .driver-header-welcome p{font-size:11px;line-height:1.35}
 body:has(#driver-start:not([hidden])) .driver-header-welcome a{font-size:10px;margin-top:1px}
}
