*{box-sizing:border-box}body{margin:0;font-family:Arial,sans-serif;background:#f5f7fa;color:#172033}header{background:#12233f;color:#fff;padding:15px 24px;display:flex;justify-content:space-between;font-size:20px}header>div{display:flex;align-items:baseline;gap:14px}.company-name{font-size:13px;color:#cfe1f7;font-weight:normal}nav{background:#fff;padding:10px 20px;border-bottom:1px solid #ddd;display:flex;gap:10px;flex-wrap:wrap}nav a{color:#173d73;text-decoration:none;font-weight:bold;padding:7px 9px}main{padding:24px;max-width:1500px;margin:auto}h1{margin-top:0}.flash{background:#e7f4e9;padding:10px;border-radius:6px;margin:10px 0}.cards{display:flex;gap:15px;flex-wrap:wrap}.cards a{background:#fff;border:1px solid #ddd;border-radius:10px;padding:18px;min-width:145px;text-decoration:none;color:#172033}.cards b{font-size:28px;display:block}.cards span{color:#657087}.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px;padding:15px 0}label{font-weight:bold;font-size:14px}input,select{width:100%;padding:9px;margin-top:5px;border:1px solid #bbb;border-radius:5px}button{padding:10px 18px;background:#1d5da8;color:white;border:0;border-radius:6px;font-weight:bold;align-self:end}details{background:white;border:1px solid #ddd;border-radius:8px;padding:12px;margin-bottom:18px}summary{font-weight:bold;cursor:pointer}.tablewrap{overflow:auto}table{width:100%;border-collapse:collapse;background:white}th,td{border:1px solid #d9dee7;padding:9px;text-align:left;white-space:nowrap}th{background:#edf2f8;text-align:center}.login{max-width:420px;margin:10vh auto;background:white;padding:30px;border:1px solid #ddd;border-radius:12px}.login label{display:block;margin:15px 0}.login button{width:100%}@media(max-width:700px){main{padding:12px}header{font-size:16px}header>div{display:block}.company-name{display:block;margin-top:3px}.grid{grid-template-columns:1fr}.cards a{min-width:45%;}}

.pagehead{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;flex-wrap:wrap}.pagehead h1{margin-bottom:4px}.muted{color:#657087;margin-top:0}.btnlink{background:#1d5da8;color:#fff;text-decoration:none;padding:9px 14px;border-radius:6px;font-weight:bold}.accountingtable th a,.accountingtable td a{color:#173d73;text-decoration:none}.accountingtable th a:hover,.accountingtable td a:hover{text-decoration:underline}.accountingtable th small{display:block;font-weight:normal;color:#657087;margin-top:4px}.money{text-align:right!important}.strongrow th,.strongrow td{font-weight:bold;background:#f7f9fc}.totalcell{font-weight:bold}.summarycards{margin:12px 0 24px}.summarycards a{cursor:default}@media(max-width:700px){.accountingtable{min-width:850px}}
/* V1.02 left navigation + editing */
.shell{display:flex;min-height:calc(100vh - 54px)}nav{width:225px;min-width:225px;background:#fff;border-right:1px solid #d9dee7;border-bottom:0;padding:18px 10px;display:flex;flex-direction:column;gap:4px}nav a{display:block;padding:11px 12px;border-radius:6px}nav a:hover{background:#edf2f8}main{flex:1;min-width:0;margin:0;max-width:none}.editlink{display:inline-block;background:#1d5da8;color:#fff!important;text-decoration:none!important;padding:6px 11px;border-radius:5px;font-weight:bold}.editcard{background:#fff;border:1px solid #ddd;border-radius:9px;padding:18px}.actions{display:flex;align-items:end;gap:10px}.cancel{padding:10px 16px;text-decoration:none;color:#173d73;font-weight:bold}@media(max-width:700px){.shell{display:block}nav{width:100%;min-width:0;flex-direction:row;overflow-x:auto;border-right:0;border-bottom:1px solid #ddd;padding:8px}nav a{white-space:nowrap;padding:8px 10px}}
/* V1.03 standard Back / Edit / Delete controls */
.backbar{display:flex;justify-content:flex-start;margin:0 0 14px}.backbtn{background:#5f6b7a;padding:8px 14px;cursor:pointer}.recordactions{display:flex;gap:7px;align-items:center;justify-content:center}.recordactions form{margin:0}.deletebtn{background:#b42318;color:#fff;padding:6px 11px;cursor:pointer}.deletebtn:hover{background:#8f1c13}
.valid{font-weight:700}.warning{font-weight:700}.urgent{font-weight:800}.expired{font-weight:800;text-decoration:underline}

/* V1.07 driver CDL / Medical expiration status */
.expiration-legend{display:flex;gap:7px;flex-wrap:wrap;align-items:center}.exp-badge{display:inline-block;padding:5px 8px;border-radius:5px;font-weight:700;white-space:nowrap;border:1px solid transparent}.exp-green{background:#d9f2df;color:#176b2c;border-color:#8fd39e}.exp-yellow{background:#fff3bf;color:#705400;border-color:#e8cf64}.exp-red{background:#ffd9d6;color:#9d1c12;border-color:#ee9188}.exp-none{background:#edf1f5;color:#596675;border-color:#cbd2da}label small{display:block;margin-top:5px;font-weight:normal}

/* V1.08 Compliance & Document all-in-one summary */
.compliance-cards{display:flex;gap:10px;flex-wrap:wrap;margin:12px 0 18px}.compliance-card{min-width:145px;padding:12px 16px;border-radius:8px;border:1px solid;display:flex;flex-direction:column}.compliance-card b{font-size:26px}.compliance-card span{font-weight:700}.compliance-table a:not(.editlink){color:#173d73;text-decoration:none}.compliance-table a:not(.editlink):hover{text-decoration:underline}

/* V1.09 Compliance control center: filters, attention list, quick upload, inline expiration edit */
.compliance-card{text-decoration:none;color:inherit}.compliance-card:hover{filter:brightness(.98);box-shadow:0 1px 4px rgba(0,0,0,.08)}
.filterbar{display:grid;grid-template-columns:minmax(220px,2fr) minmax(150px,1fr) minmax(170px,1fr) auto auto;gap:10px;align-items:end;background:#fff;border:1px solid #d9dee7;border-radius:8px;padding:12px;margin:12px 0 18px}.filterbar label{margin:0}.filterbar button{height:38px}.clearfilter{height:38px;display:flex;align-items:center;padding:0 12px;color:#173d73;font-weight:bold;text-decoration:none}.attention{border-left:5px solid #b42318}.attention summary{color:#8f1c13}.quickupload{border-left:5px solid #1d5da8}.quickgrid{grid-template-columns:repeat(auto-fit,minmax(180px,1fr))}.inline-date{display:flex;gap:6px;align-items:center;margin:0}.inline-date input{margin:0;min-width:145px;padding:6px}.inline-date button{padding:7px 10px}.attention table a:not(.editlink){color:#173d73;text-decoration:none}
@media(max-width:900px){.filterbar{grid-template-columns:1fr 1fr}.filterbar .clearfilter{align-self:end}}@media(max-width:600px){.filterbar{grid-template-columns:1fr}.inline-date{min-width:220px}}

.entity-summary{display:grid;grid-template-columns:repeat(3,minmax(150px,1fr));gap:12px;margin:12px 0 16px}.mini-card{background:#fff;border:1px solid #d9dee7;border-radius:10px;padding:14px;display:flex;flex-direction:column;gap:4px}.mini-card b{font-size:24px}.mini-card span{font-size:13px;color:#5f6875}.small{font-size:13px;font-weight:normal}@media(max-width:760px){.entity-summary{grid-template-columns:1fr}}

/* V1.12: side-by-side Driver CDL and Medical Card compliance dashboard */
.compliance-head{align-items:center}.driver-summary-cards{display:grid;grid-template-columns:repeat(5,minmax(135px,1fr));gap:10px;margin:12px 0 18px}.driver-summary-card{background:#fff;border:1px solid #d9dee7;border-radius:9px;padding:14px;text-align:center;text-decoration:none;color:#172033;display:flex;flex-direction:column;gap:5px}.driver-summary-card span{font-weight:700;font-size:13px}.driver-summary-card b{font-size:27px}.summary-blue{background:#eaf4ff;border-color:#bcd8f4}.summary-red{background:#fff0ef;border-color:#efc0bc}.summary-red b{color:#b42318}.summary-yellow{background:#fff8dc;border-color:#ebd88c}.summary-yellow b{color:#8a6500}.driver-compliance-panel{background:#fff;border:1px solid #d9dee7;border-radius:10px;padding:0;margin:18px 0;overflow:hidden}.section-title{display:flex;justify-content:space-between;align-items:center;padding:16px 18px 8px}.section-title h2{margin:0 0 4px}.driver-compliance-table{min-width:1100px;border:0}.driver-compliance-table th,.driver-compliance-table td{text-align:center}.driver-compliance-table thead th{font-size:14px}.driver-compliance-table .cdl-group{background:#eaf4ff}.driver-compliance-table .medical-group{background:#edf9ef}.driver-compliance-table .driver-name{text-align:left}.driver-compliance-table .driver-name a{color:#173d73;text-decoration:none}.driver-compliance-table td small{display:block;color:#657087;margin-top:3px}.docicon{display:inline-flex;align-items:center;justify-content:center;width:34px;height:32px;border:1px solid #58708f;border-radius:5px;text-decoration:none;color:#173d73;background:#fff;font-weight:bold}.driver-compliance-panel .expiration-legend{padding:0 16px 14px;margin-bottom:0}.driver-compliance-table .exp-badge{min-width:90px;text-align:center}.driver-compliance-table .exp-green{background:#2e9b42;color:#fff;border-color:#237a34}.driver-compliance-table .exp-yellow{background:#ffd22e;color:#4f3a00;border-color:#d8ac00}.driver-compliance-table .exp-red{background:#e52b24;color:#fff;border-color:#bd201a}
@media(max-width:1100px){.driver-summary-cards{grid-template-columns:repeat(3,1fr)}}@media(max-width:700px){.driver-summary-cards{grid-template-columns:1fr 1fr}.compliance-head .btnlink{width:100%;text-align:center}}

/* V1.13 expandable compliance sections */
.driver-compliance-panel{padding:0}.driver-compliance-panel>summary{list-style:none}.driver-compliance-panel>summary::-webkit-details-marker{display:none}.driver-section-summary{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:14px 16px;background:#fff;cursor:pointer}.driver-section-summary:before{content:'▶';font-size:13px;color:#173d73;flex:0 0 auto}.driver-compliance-panel[open] .driver-section-summary:before{content:'▼'}.driver-summary-title{display:flex;align-items:center;gap:12px;min-width:0}.driver-summary-title h2{margin:0}.compact-legend{margin:0;justify-content:flex-end}.expand-hint{font-size:12px;color:#657087;font-weight:700;white-space:nowrap}.driver-subtitle{margin:0;padding:0 18px 12px}.entity-compliance-panel{padding:0;overflow:hidden}.entity-compliance-panel>summary{list-style:none}.entity-compliance-panel>summary::-webkit-details-marker{display:none}.entity-section-summary{display:flex;align-items:center;gap:10px;padding:14px 16px}.entity-section-summary:before{content:'▶';font-size:13px;color:#173d73}.entity-compliance-panel[open] .entity-section-summary:before{content:'▼'}.entity-section-summary h2{margin:0;flex:1}@media(max-width:900px){.driver-section-summary{align-items:flex-start;flex-direction:column}.compact-legend{justify-content:flex-start}.driver-summary-title{width:100%}}


/* V1.14: align expandable compliance heading and status legend on one row */
.driver-section-summary{display:flex;align-items:center;justify-content:flex-start;gap:12px;width:100%;}
.driver-section-summary:before{margin-right:2px;}
.driver-summary-title{display:flex;align-items:center;gap:10px;min-width:0;flex:0 1 auto;margin-right:auto;text-align:left;}
.driver-summary-title h2{margin:0;text-align:left;white-space:nowrap;}
.compact-legend{display:flex;align-items:center;justify-content:flex-end;gap:7px;margin-left:auto;flex:0 0 auto;}
.compact-legend b{white-space:nowrap;}
@media(max-width:1100px){.driver-section-summary{flex-wrap:wrap}.compact-legend{margin-left:0;width:100%;justify-content:flex-start;padding-left:27px}.driver-summary-title{margin-right:0}}
@media(max-width:700px){.driver-summary-title{flex-wrap:wrap}.driver-summary-title h2{white-space:normal}.compact-legend{padding-left:0}}
/* V1.15 Compliance & Document count/alignment design */
.v115-pagehead{display:flex;align-items:flex-start;gap:16px}.v115-pagehead>div:first-child{min-width:330px}.overall-counts{margin-left:auto}.v115-panel{padding:0;overflow:hidden}.v115-panel>summary{list-style:none}.v115-panel>summary::-webkit-details-marker{display:none}.v115-section-summary{display:flex;align-items:center;gap:14px;padding:16px 18px;background:#fff;cursor:pointer;width:100%;box-sizing:border-box}.v115-section-summary:before{content:'▶';font-size:18px;color:#173d73;flex:0 0 auto}.v115-panel[open]>.v115-section-summary:before{content:'▼'}.v115-section-title{display:flex;align-items:center;gap:10px;min-width:0}.v115-section-title h2{margin:0;text-align:left;white-space:nowrap}.section-icon{font-size:27px;line-height:1;flex:0 0 auto}.status-counts{display:flex;align-items:center;gap:8px;margin-left:auto;white-space:nowrap}.status-counts b{margin-right:2px}.count-badge{display:inline-block;padding:7px 12px;border-radius:6px;border:1px solid;font-weight:800}.count-green{background:#e8f7ec;border-color:#9bd8a7;color:#087425}.count-yellow{background:#fff5d8;border-color:#efcf67;color:#795600}.count-red{background:#fde8e8;border-color:#f1a0a0;color:#b41616}.v115-pagehead .btnlink{white-space:nowrap}
@media(max-width:1250px){.v115-section-summary{flex-wrap:wrap}.status-counts{width:100%;margin-left:42px;justify-content:flex-start}.overall-counts{width:auto;margin-left:0}.v115-pagehead{flex-wrap:wrap}}
@media(max-width:750px){.v115-section-title{flex-wrap:wrap}.v115-section-title h2{white-space:normal}.status-counts{margin-left:0;flex-wrap:wrap}.overall-counts{width:100%}.count-badge{padding:6px 9px}}

/* V1.23 aligned Create Load form */
.load-grid{align-items:start}
.load-grid>label,.load-grid>.create-load-cell{display:flex;flex-direction:column;min-width:0}
.load-label{display:flex;align-items:flex-end;min-height:36px;line-height:18px;font-weight:bold}
.load-grid input,.load-grid select{margin-top:5px;height:38px}
.customer-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;align-items:end}
.customer-row input{min-width:0}
.small-blue{height:38px;padding:8px 12px;white-space:nowrap}
.datetime-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;align-items:end}
.datetime-row input{min-width:0}
.donebtn{height:38px;padding:8px 12px;background:#5f6b7a}
.create-load-cell{justify-content:flex-start}
.create-load-btn{height:38px;width:100%;margin-top:5px;align-self:stretch}
.load-error{grid-column:1/-1;background:#fff0ef;border:1px solid #ef9188;color:#9d1c12;font-weight:bold;padding:10px;border-radius:6px}
@media(max-width:700px){.load-label{min-height:0}.customer-row,.datetime-row{grid-template-columns:1fr auto}}

/* V1.24 date/time popup with Done inside */
.schedule-field{position:relative}
.schedule-display{position:relative;cursor:pointer}
.schedule-display input{padding-right:38px;cursor:pointer;background:#fff}
.calendar-button{position:absolute;right:10px;top:50%;transform:translateY(-50%);font-size:18px;pointer-events:none}
.schedule-popup{display:none;position:absolute;z-index:1000;top:calc(100% + 5px);left:0;width:280px;background:#fff;border:1px solid #9aa8ba;border-radius:8px;padding:12px;box-shadow:0 6px 20px rgba(0,0,0,.18)}
.schedule-popup>b{display:block;margin-bottom:8px}
.schedule-popup label{display:block;margin:7px 0}
.schedule-popup input{height:38px}
.picker-done{display:block;width:100%;margin-top:10px;height:40px}
.equipment-assignment-title{grid-column:1/-1;background:#eaf4ff;border:1px solid #bcd8f4;border-radius:7px;padding:10px 12px}
.equipment-assignment-title b{display:block;font-size:15px}
.equipment-assignment-title small{display:block;margin-top:4px;font-weight:normal;color:#46576b}
@media(max-width:700px){.schedule-popup{width:min(280px,calc(100vw - 50px))}}

/* V1.25 global popup notices + clearer calendar icon */
.notice-overlay{position:fixed;inset:0;background:rgba(18,35,63,.28);z-index:5000;display:flex;align-items:center;justify-content:center;padding:20px}
.notice-popup{width:min(430px,92vw);background:#fff;border:1px solid #cfd7e3;border-radius:12px;box-shadow:0 14px 40px rgba(0,0,0,.25);padding:18px;display:flex;gap:14px;align-items:flex-start}
.notice-icon{font-size:28px;line-height:1}
.notice-body{flex:1}
.notice-body h3{margin:0 0 8px;font-size:19px}
.notice-body button{margin-top:14px;min-width:90px}
.calendar-button{background:#edf2f8;border-left:1px solid #c5cfdb;right:1px;top:6px;bottom:1px;transform:none;width:36px;height:36px;display:flex;align-items:center;justify-content:center;border-radius:0 5px 5px 0;font-size:18px}
.schedule-display input{padding-right:44px}

/* V1.29 multi-company platform owner */
.platform-link{background:#eaf4ff;color:#0e4d8c!important;border:1px solid #bcd8f4}.company-form{grid-template-columns:repeat(auto-fit,minmax(190px,1fr))}.current-company td{background:#eef8ff}.current-label{display:block;color:#176b2c;margin-top:4px}.company-active{color:#176b2c}.company-inactive{color:#b42318}.center{text-align:center}.open-company,.activate-company{padding:7px 11px}.deactivate-company{padding:7px 11px;background:#b42318}.company-note{margin-top:14px}

/* V1.30 site-wide compact centered table headers + responsive screen fitting */
html,body{width:100%;max-width:100%;overflow-x:hidden}
.shell{width:100%;max-width:100%}
main{width:100%;max-width:100%;min-width:0;padding:clamp(12px,1.6vw,24px)}
.tablewrap{width:100%;max-width:100%;overflow-x:auto;overflow-y:visible;-webkit-overflow-scrolling:touch}
table{width:100%;max-width:100%;border-collapse:collapse}
th{background:#edf2f8;text-align:center!important;vertical-align:top!important;white-space:normal!important;line-height:1.12;padding:8px 7px}
th .th-wrap{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;min-height:2.24em;line-height:1.12;text-align:center;width:100%}
th .th-line{display:block;white-space:nowrap;text-align:center}
th .th-single{min-height:2.24em;justify-content:flex-start}
th .th-single .th-line{line-height:1.12}
td{padding:8px;vertical-align:top}

/* Keep ordinary desktop tables compact while letting the browser use the full screen. */
@media(max-width:1400px){
  th,td{font-size:14px;padding:7px 6px}
  nav{width:205px;min-width:205px}
}
@media(max-width:1100px){
  th,td{font-size:13px;padding:6px 5px}
  nav{width:185px;min-width:185px}
  nav a{padding:9px 8px;font-size:14px}
  .exp-badge{padding:4px 6px}
}
@media(max-width:850px){
  .shell{display:block}
  nav{width:100%;min-width:0;max-width:100%;flex-direction:row;overflow-x:auto;border-right:0;border-bottom:1px solid #ddd;padding:8px;gap:2px}
  nav a{white-space:nowrap;padding:8px 9px}
  main{width:100%;max-width:100%;padding:12px}
  th,td{font-size:12px;padding:5px 4px}
  td{white-space:normal;overflow-wrap:anywhere}
  td .exp-badge,.exp-badge,.recordactions,.recordactions a,.recordactions button{white-space:nowrap}
  .tablewrap table{min-width:max-content}
}
@media(max-width:600px){
  header{padding:10px 12px}
  main{padding:10px}
  h1{font-size:24px}
  .pagehead{gap:8px}
  th,td{font-size:11px;padding:5px 4px}
  .grid{grid-template-columns:1fr}
  input,select,button{font-size:16px} /* prevents mobile browser input zoom */
}

/* V1.32 custom time selector: avoids browser time flyout covering Done */
.time-parts{display:grid;grid-template-columns:1fr auto 1fr 1fr;gap:6px;align-items:center;width:100%}
.time-parts select{height:38px;min-width:0;width:100%;padding:5px 7px}
.time-colon{text-align:center;font-weight:bold}
.schedule-popup .picker-done{position:relative;z-index:2;background:#1769c2;color:#fff;border:none;border-radius:4px;font-weight:bold}
/* V1.33 compact document status buttons */
.docbuttons{display:flex;gap:4px;align-items:center;justify-content:center;flex-wrap:nowrap}.docbtn{display:inline-block;padding:5px 7px;border-radius:5px;font-size:12px;font-weight:700;text-decoration:none;color:#111!important;border:1px solid rgba(0,0,0,.18);white-space:nowrap}.doc-green{background:#b7e4c7}.doc-yellow{background:#ffe69c}.doc-red{background:#f5b7b1}.docbtn:hover{filter:brightness(.95);transform:translateY(-1px)}.other-doc-row{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin:10px 0;padding:8px;border-top:1px solid #ddd}.other-doc-row form{margin:0}.other-doc-row select{margin:0;min-width:170px}.backlink{display:inline-block;margin-bottom:12px;background:#64748b;color:white;text-decoration:none;padding:7px 12px;border-radius:6px;font-weight:bold}

/* V1.34 ultra-compact Documents / Invoice header + color legend */
.docs-invoice-head{min-width:150px;width:150px;padding:5px 4px!important;white-space:nowrap!important;vertical-align:top!important}
.docs-invoice-head>span{display:block;font-size:11px;font-weight:800;line-height:1.05;white-space:nowrap;text-align:center}
.doc-legend{display:flex;align-items:center;justify-content:center;gap:5px;margin-top:4px;font-size:8px;font-weight:600;line-height:1;white-space:nowrap;color:#334155}
.doc-legend>span{display:inline-flex;align-items:center;gap:2px}
.legend-dot{display:inline-block;width:7px;height:7px;border-radius:50%;border:1px solid rgba(0,0,0,.2);flex:0 0 7px}
.legend-green{background:#4caf66}.legend-yellow{background:#f2c94c}.legend-red{background:#d94a44}
.docbuttons{gap:3px!important}
.docbtn{padding:4px 5px!important;font-size:10px!important;border-radius:4px!important}
@media(max-width:1100px){.docs-invoice-head{min-width:138px;width:138px}.docs-invoice-head>span{font-size:10px}.doc-legend{font-size:7px;gap:4px}.legend-dot{width:6px;height:6px;flex-basis:6px}.docbtn{padding:3px 4px!important;font-size:9px!important}}

/* V1.35 direct document review buttons */
.doc-review-line{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin:8px 0 12px;padding:8px 10px;background:#f8fafc;border:1px solid #d7dee8;border-radius:6px}
.doc-review-line form{margin:0}.review-btn{padding:6px 10px;background:#27823b;color:#fff;border:0;border-radius:5px;font-size:12px;font-weight:800;white-space:nowrap}.review-btn:hover{filter:brightness(.94)}.review-undo{background:#64748b}.review-ok{color:#237334}.review-pending{color:#9a6700}.other-doc-line{margin-top:10px}
@media(max-width:600px){.review-btn{font-size:12px;padding:6px 8px}.doc-review-line{align-items:flex-start}}

/* V1.36 choose reviewer from dropdown when Mark Reviewed is clicked */
.inline-review-form{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.review-picker{display:inline-flex;align-items:center;gap:5px}
.review-picker[hidden]{display:none!important}
.review-picker select{min-width:170px;height:32px;padding:4px 6px;font-size:12px;margin:0}
.review-confirm{height:32px;padding:5px 9px;background:#1769c2;color:#fff;border:0;border-radius:5px;font-size:12px;font-weight:800;white-space:nowrap}
@media(max-width:600px){.review-picker{width:100%;flex-wrap:wrap}.review-picker select{flex:1;min-width:160px}}

/* V1.37 reviewer name shown beside reviewed status */
.reviewed-by{margin-left:4px;color:#1769c2;font-size:12px;white-space:nowrap}.reviewed-by b{color:#1769c2;font-weight:800}

/* V1.39 reviewer identity */
.reviewed-by{margin-left:8px;color:#163a8a;font-weight:600}.reviewed-by strong{color:#1656b8;font-weight:800}.reviewed-by b{color:#163a8a}


/* V1.41 DOC dropdown background status highlighting */
#reviewDoc option[data-status="reviewed"]{background:#b7e4c7;color:#12351c;font-weight:700}
#reviewDoc option[data-status="pending"]{background:#ffe69c;color:#5b4500;font-weight:700}
#reviewDoc option[data-status="missing"]{background:#f5b7b1;color:#6d1712;font-weight:700}
#reviewDoc.review-doc-green{background:#b7e4c7;color:#12351c;font-weight:700}
#reviewDoc.review-doc-yellow{background:#ffe69c;color:#5b4500;font-weight:700}
#reviewDoc.review-doc-red{background:#f5b7b1;color:#6d1712;font-weight:700}


/* V1.42 custom DOC status dropdown - reliable full-row colors in Chrome */
.review-doc-native{position:absolute!important;width:1px!important;height:1px!important;opacity:0!important;pointer-events:none!important;overflow:hidden!important}
.review-doc-custom{position:relative;width:100%}
.review-doc-toggle{width:100%;height:38px;display:flex;align-items:center;justify-content:space-between;text-align:left;border:1px solid #b8c2cf;border-radius:5px;padding:7px 10px;font-weight:700;color:#172033}
.review-doc-menu{position:absolute;z-index:2500;top:calc(100% + 3px);left:0;right:0;background:#fff;border:1px solid #aeb8c5;border-radius:5px;box-shadow:0 8px 22px rgba(0,0,0,.18);overflow:hidden}
.review-doc-option{display:block;width:100%;border:0;border-bottom:1px solid rgba(0,0,0,.12);border-radius:0;text-align:left;padding:9px 11px;font-size:13px;font-weight:700;color:#172033;cursor:pointer}
.review-doc-option:last-child{border-bottom:0}
.review-doc-option:hover:not(:disabled){filter:brightness(.94)}
.review-doc-option:disabled{cursor:not-allowed;opacity:.72;color:#6d1712}
.review-doc-neutral{background:#fff!important;color:#172033!important}
.review-doc-green{background:#b7e4c7!important;color:#12351c!important}
.review-doc-yellow{background:#ffe69c!important;color:#5b4500!important}
.review-doc-red{background:#f5b7b1!important;color:#6d1712!important}

/* V1.43 ultra-compact Loads table for high-volume dispatching */
.loads-compact th,.loads-compact td{padding:4px 7px!important;line-height:1.05;vertical-align:middle}
.loads-compact td{font-size:12px}
.loads-compact th{font-size:12px}
.loads-compact .load-address{white-space:nowrap!important;max-width:360px;overflow:hidden;text-overflow:ellipsis}
.loads-compact .recordactions{gap:3px}
.loads-compact .load-action-btn{display:inline-flex!important;align-items:center;justify-content:center;height:24px!important;min-width:42px!important;padding:3px 5px!important;border-radius:4px!important;font-size:10px!important;font-weight:700!important;line-height:1!important}
.loads-compact button.load-action-btn{margin:0!important}
.loads-compact .docbtn{height:24px;display:inline-flex;align-items:center;justify-content:center}
@media(max-width:1100px){.loads-compact th,.loads-compact td{padding:3px 5px!important}.loads-compact td,.loads-compact th{font-size:11px}.loads-compact .load-action-btn{height:22px!important;min-width:38px!important;font-size:9px!important;padding:2px 4px!important}.loads-compact .docbtn{height:22px}}

/* V1.46 required review validation */
.req-star{color:#d71920;font-size:17px;font-weight:900;margin-left:2px}
.review-form{position:relative}
.review-form .review-validation{grid-column:1/-1;background:#fff0f0;border:2px solid #d71920;border-left:7px solid #d71920;color:#c00000;font-size:18px;font-weight:900;line-height:1.35;padding:12px 15px;border-radius:7px;margin:0 0 2px;box-shadow:0 2px 7px rgba(190,0,0,.10)}
.review-form .review-validation div+div{margin-top:5px}
.review-form .required-missing{border:2px solid #d71920!important;background:#fff5f5!important;box-shadow:0 0 0 2px rgba(215,25,32,.08)}
@media(max-width:700px){.review-form .review-validation{font-size:16px}}
/* V1.47 compact reusable add-new controls */
.inline-select-add{display:flex;gap:6px;align-items:center}.inline-select-add select{flex:1;min-width:0}.small-add-btn{width:auto!important;white-space:nowrap;padding:7px 10px!important;font-size:12px!important;background:#1769c2!important;color:#fff!important;border:0!important;border-radius:5px!important}.doc-add-btn{margin-top:6px}.other-upload-form{display:grid;grid-template-columns:minmax(130px,180px) 1fr auto;gap:8px;align-items:center}.review-form{grid-template-columns:1.25fr 1.4fr 1.4fr 1fr auto!important}@media(max-width:900px){.review-form{grid-template-columns:1fr!important}.inline-select-add{align-items:stretch}.other-upload-form{grid-template-columns:1fr}}

/* V1.50 document delete controls */
.doc-review-line{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.inline-delete-form{display:inline;margin:0}
.delete-doc-btn{background:#c62828!important;color:#fff!important;border:0!important;border-radius:4px!important;padding:5px 10px!important;font-size:12px!important;font-weight:700!important;min-height:auto!important;width:auto!important}
.delete-doc-btn:hover{background:#a61f1f!important}

/* V1.51 place Delete beside Upload / Replace */
.doc-upload-actions{display:flex;align-items:flex-end;gap:7px;flex-wrap:wrap}
.doc-upload-actions form:first-child{margin:0}
.doc-upload-actions .delete-beside-upload{margin:0}
.doc-upload-actions .delete-doc-btn{height:35px;padding:6px 14px}
.doc-button-row{display:inline-block}

/* V1.52 keep Delete immediately next to Upload / Replace */
.doc-upload-actions{display:block}
.doc-upload-actions .upload-primary-form{display:inline-block;margin:0}
.doc-upload-actions .doc-button-row{display:flex;align-items:center;justify-content:flex-start;gap:5px;margin-top:0}
.doc-upload-actions .doc-button-row button{width:auto!important;margin:0!important}
.doc-upload-actions .adjacent-delete{height:auto!important;padding:10px 14px!important}
.hidden-delete-form{display:none!important}

/* V1.53 compact review row + 2x2 document upload grid */
.review-form{
  grid-template-columns:minmax(210px,1.2fr) minmax(250px,1.35fr) minmax(220px,1.2fr) minmax(170px,.9fr) auto!important;
  gap:10px!important;
  align-items:end!important;
}
.review-form>label{min-width:0;margin:0!important}
.review-form .inline-select-add{gap:4px!important}
.review-form .small-add-btn{padding:7px 8px!important;font-size:11px!important}
.review-form .doc-add-btn{margin-top:4px!important}
.review-form .review-doc-custom{min-width:0}
.review-form .review-doc-toggle{height:36px!important}
.review-form select{height:36px!important}
.review-save-btn{
  background:#1f9d45!important;
  color:#fff!important;
  border:0!important;
  border-radius:5px!important;
  font-weight:800!important;
  width:auto!important;
  min-width:105px!important;
  height:36px!important;
  padding:7px 18px!important;
  margin:0!important;
}
.review-save-btn:hover{background:#178238!important}
.load-doc-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
  align-items:start;
  margin-top:10px;
}
.load-doc-grid .load-doc-card{margin:0!important;min-width:0}
.load-doc-card h2{margin-top:0}
.load-doc-card .doc-review-line{margin:6px 0 8px!important;padding:6px 8px!important;font-size:12px}
.load-doc-card .upload-primary-form{display:block!important;width:100%}
.load-doc-card .upload-primary-form>input[type=file]{width:100%;max-width:100%;box-sizing:border-box;margin-bottom:5px}
.load-doc-card .doc-button-row{display:flex!important;gap:5px!important;align-items:center!important;justify-content:flex-start!important}
.load-doc-card .doc-button-row button{font-size:11px!important;padding:7px 10px!important}
.load-doc-card .other-upload-form{grid-template-columns:minmax(110px,150px) minmax(0,1fr) auto!important;gap:6px!important}
.load-doc-card .other-upload-form button{font-size:11px!important;padding:7px 9px!important}
@media(max-width:1200px){
  .review-form{grid-template-columns:1fr 1fr!important}
  .review-save-btn{width:100%!important}
}
@media(max-width:900px){
  .load-doc-grid{grid-template-columns:1fr}
  .review-form{grid-template-columns:1fr!important}
}
\n\n/* V1.54 aligned review controls + uniform light-gray document cards + reusable Other document names */\n.review-form{\n  display:grid!important;\n  grid-template-columns:minmax(230px,1.05fr) minmax(300px,1.25fr) minmax(250px,1.15fr) minmax(190px,.9fr) 110px!important;\n  gap:10px!important;\n  align-items:end!important;\n}\n.review-form>label{display:flex!important;flex-direction:column!important;justify-content:flex-end!important;gap:4px!important;height:100%!important}\n.review-form>label>.inline-select-add,.review-form>label>.review-doc-custom{margin-top:auto!important}\n.review-form .doc-add-btn{margin-top:4px!important;align-self:flex-start!important}\n.review-save-btn{align-self:end!important;background:#1f9d45!important}\n.load-doc-grid{align-items:stretch!important}\n.load-doc-card{\n  background:#f5f7fa!important;\n  border:1px solid #d7dde5!important;\n  border-radius:8px!important;\n  padding:14px!important;\n  box-shadow:0 1px 2px rgba(0,0,0,.03)!important;\n  min-height:235px;\n}\n.load-doc-card h2{margin:0 0 10px!important;padding-bottom:8px;border-bottom:1px solid #dde3ea}\n.load-doc-card p{margin:8px 0 10px}\n.load-doc-card .doc-upload-actions,.load-doc-card .other-upload-form{margin-top:8px}\n.other-type-add-form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;align-items:center;margin:8px 0 10px}\n.other-type-add-form input[type=text]{height:36px;box-sizing:border-box;margin:0;padding:7px 9px;border:1px solid #b8c2cf;border-radius:5px;background:#fff}\n.other-type-add-form .small-add-btn{height:36px!important;margin:0!important}\n@media(max-width:1200px){.review-form{grid-template-columns:1fr 1fr!important}.review-save-btn{width:100%!important}.load-doc-card{min-height:auto}}\n@media(max-width:900px){.review-form{grid-template-columns:1fr!important}.other-type-add-form{grid-template-columns:1fr}.other-type-add-form .small-add-btn{width:100%!important}}\n
/* V1.55 universal auto-fit layout for desktop, laptop, tablet and phone */
html,body{max-width:100%;overflow-x:hidden}
body{min-width:0}
.shell{width:100%;max-width:100%;min-width:0}
main{width:100%;max-width:100%;min-width:0;padding:clamp(10px,1.5vw,22px)!important;overflow-x:hidden}
header{width:100%;max-width:100%;padding:clamp(10px,1.2vw,15px) clamp(12px,1.5vw,24px)}
nav{flex:0 0 clamp(165px,14vw,225px);width:clamp(165px,14vw,225px);min-width:clamp(165px,14vw,225px)}
nav a{font-size:clamp(11px,.85vw,14px);padding:clamp(7px,.65vw,11px) clamp(7px,.7vw,12px)}

/* All common page containers stay inside the available viewport */
.pagehead,.cards,.grid,.filterbar,.entity-summary,.driver-summary-cards,.driver-compliance-panel,
.editcard,details,.load-doc-grid,.review-form,.other-upload-form,.other-type-add-form,.actions,.recordactions{
  max-width:100%;min-width:0;
}
.grid>* ,.filterbar>* ,.entity-summary>* ,.driver-summary-cards>* ,.load-doc-grid>* ,.review-form>*{min-width:0}
input,select,textarea,button{max-width:100%;min-width:0}
input[type=file]{width:100%;min-width:0}

/* Tables automatically use the screen width instead of forcing the page wider */
.tablewrap{width:100%;max-width:100%;overflow-x:auto;overflow-y:visible;-webkit-overflow-scrolling:touch}
.tablewrap table,table{max-width:100%}
th,td{font-size:clamp(9px,.78vw,13px);padding:clamp(3px,.45vw,7px) clamp(3px,.4vw,6px);line-height:1.15}
th{white-space:normal!important;overflow-wrap:anywhere;word-break:normal}
td{white-space:normal;overflow-wrap:anywhere;word-break:normal}
.accountingtable,.compliance-table,.driver-compliance-table{width:100%!important;min-width:0!important;table-layout:auto}
.driver-compliance-table .exp-badge{min-width:0!important;width:100%;padding-left:3px;padding-right:3px}
.docs-invoice-head{min-width:0!important;width:auto!important}
.loads-compact .load-address{max-width:22vw!important}

/* Large-screen forms compress before they wrap */
.review-form{
  grid-template-columns:minmax(155px,1.05fr) minmax(190px,1.25fr) minmax(175px,1.15fr) minmax(135px,.9fr) minmax(82px,105px)!important;
  gap:clamp(5px,.7vw,10px)!important;
}
.review-form label{font-size:clamp(11px,.8vw,14px)}
.review-form select,.review-form .review-doc-toggle{font-size:clamp(11px,.8vw,13px);padding-left:7px;padding-right:7px}
.review-form .small-add-btn{font-size:clamp(9px,.7vw,11px)!important;padding-left:6px!important;padding-right:6px!important}
.review-save-btn{min-width:82px!important;padding-left:10px!important;padding-right:10px!important}
.load-doc-card{padding:clamp(9px,1vw,14px)!important}
.load-doc-card h2{font-size:clamp(17px,1.4vw,24px)}

@media(max-width:1200px){
  nav{flex-basis:175px;width:175px;min-width:175px}
  main{padding:12px!important}
  .review-form{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .review-save-btn{width:100%!important}
  .driver-summary-cards{grid-template-columns:repeat(auto-fit,minmax(120px,1fr))!important}
  .filterbar{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}

@media(max-width:850px){
  .shell{display:block}
  nav{width:100%;min-width:0;max-width:100%;flex:0 0 auto;display:flex;flex-direction:row;overflow-x:auto;white-space:nowrap;border-right:0;border-bottom:1px solid #ddd;padding:6px}
  nav a{flex:0 0 auto;font-size:12px;padding:7px 8px}
  main{width:100%;max-width:100%;padding:10px!important}
  .cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  .cards a{min-width:0!important;width:100%}
  .load-doc-grid{grid-template-columns:1fr!important}
  .review-form,.filterbar,.entity-summary{grid-template-columns:1fr!important}
  .other-upload-form,.other-type-add-form{grid-template-columns:1fr!important}
  .inline-select-add{width:100%;display:grid;grid-template-columns:minmax(0,1fr) auto}
  .pagehead{align-items:stretch}
  .pagehead .btnlink{max-width:100%;text-align:center}
  .recordactions{flex-wrap:wrap}
  .tablewrap{overflow-x:auto}
  .tablewrap table{min-width:0!important;width:100%!important}
  th,td{font-size:10px!important;padding:4px 3px!important}
  .loads-compact .load-address{max-width:28vw!important}
}

@media(max-width:600px){
  header{font-size:15px;gap:8px}
  header>div{min-width:0}
  header b{font-size:15px}
  .company-name{font-size:10px}
  main{padding:8px!important}
  h1{font-size:21px;margin-bottom:8px}
  h2{font-size:18px}
  .cards{grid-template-columns:1fr 1fr;gap:7px}
  .cards a{padding:10px}
  .cards b{font-size:22px}
  .grid{grid-template-columns:1fr!important;gap:8px}
  label{font-size:12px}
  input,select,textarea,button{font-size:16px}
  .review-form{grid-template-columns:1fr!important}
  .inline-select-add{grid-template-columns:minmax(0,1fr) auto}
  .small-add-btn{font-size:11px!important}
  .load-doc-card{min-height:0!important}
  .doc-button-row{flex-wrap:wrap!important}
  .doc-upload-actions .doc-button-row button{max-width:100%}
  .driver-summary-cards{grid-template-columns:1fr 1fr!important}
  th,td{font-size:9px!important;padding:3px 2px!important}
  .docbtn{font-size:8px!important;padding:3px!important}
  .loads-compact .load-address{max-width:24vw!important}
}

/* V1.56 Loads list: keep each record on one line as much as possible */
.loads-compact{
  width:100%!important;
  table-layout:fixed!important;
}
.loads-compact th,
.loads-compact td{
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  overflow-wrap:normal!important;
  word-break:normal!important;
  vertical-align:middle!important;
}
.loads-compact th{font-size:clamp(9px,.78vw,13px)!important}
.loads-compact td{font-size:clamp(9px,.82vw,13px)!important}
/* V2.168: these widths follow the 15 columns the table now has. Invoice Date
   and Invoice # were added at the front, so every width below moved along with
   them. The table also keeps a floor width: on a small or scaled-up screen it
   slides sideways instead of crushing Status down to "Re..." */
.loads-compact{min-width:1340px!important}
.loads-compact th:nth-child(2),.loads-compact td:nth-child(2){width:5%}
.loads-compact th:nth-child(3),.loads-compact td:nth-child(3){width:4.5%}
.loads-compact th:nth-child(4),.loads-compact td:nth-child(4){width:6%}
.loads-compact th:nth-child(5),.loads-compact td:nth-child(5){width:6%}
.loads-compact th:nth-child(6),.loads-compact td:nth-child(6){width:9.5%}
.loads-compact th:nth-child(7),.loads-compact td:nth-child(7){width:5%}
.loads-compact th:nth-child(8),.loads-compact td:nth-child(8){width:7%}
.loads-compact th:nth-child(9),.loads-compact td:nth-child(9){width:9.5%}
.loads-compact th:nth-child(10),.loads-compact td:nth-child(10){width:9.5%}
.loads-compact th:nth-child(11),.loads-compact td:nth-child(11){width:4.5%}
.loads-compact th:nth-child(12),.loads-compact td:nth-child(12){width:6%}
.loads-compact th:nth-child(13),.loads-compact td:nth-child(13){width:9.5%}
.loads-compact th:nth-child(14),.loads-compact td:nth-child(14){width:5%}
.loads-compact th:nth-child(15),.loads-compact td:nth-child(15){width:5%}
.loads-compact th:nth-child(16),.loads-compact td:nth-child(16){width:8%}
/* Status is a short phrase, so let it use two lines rather than be cut off. */
.loads-compact td:nth-child(5){white-space:normal!important;text-overflow:clip!important;line-height:1.15}
/* The Driver and Truck boxes must never be clipped by the cell. */
.loads-compact td:nth-child(6),.loads-compact td:nth-child(7){overflow:visible!important;text-overflow:clip!important}
.loads-compact .assign-driver,.loads-compact .assign-truck{width:100%!important;max-width:none!important;
 height:28px!important;font-size:clamp(9px,.72vw,12px)!important;padding:2px 4px!important}
.loads-compact .load-address{max-width:none!important}
.loads-compact .docbuttons,.loads-compact .load-actions{white-space:nowrap!important;flex-wrap:nowrap!important;gap:4px!important}
.loads-compact .docbtn,.loads-compact .load-action-btn{font-size:clamp(8px,.68vw,11px)!important;padding:clamp(4px,.45vw,7px) clamp(4px,.5vw,8px)!important}
.loads-compact .doc-legend{white-space:nowrap!important;font-size:clamp(7px,.55vw,9px)!important;gap:4px!important}

@media(max-width:1100px){
  .loads-compact th,.loads-compact td{font-size:9px!important;padding:3px 2px!important}
  .loads-compact .docbtn,.loads-compact .load-action-btn{font-size:8px!important;padding:4px 3px!important}
  .loads-compact .doc-legend{font-size:7px!important;gap:2px!important}
}

/* V1.57 Loads: prevent Documents and Action controls from overlapping */
.loads-compact th:nth-child(7),.loads-compact td:nth-child(7){width:18%}
.loads-compact th:nth-child(8),.loads-compact td:nth-child(8){width:18%}
.loads-compact th:nth-child(9),.loads-compact td:nth-child(9){width:6%}
.loads-compact th:nth-child(10),.loads-compact td:nth-child(10){width:16%}
.loads-compact th:nth-child(11),.loads-compact td:nth-child(11){width:9%}
.loads-compact td:nth-child(10),.loads-compact td:nth-child(11){overflow:visible!important}
.loads-compact .docbuttons{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:3px!important;width:100%!important;min-width:0!important}
.loads-compact .docbtn{display:block!important;min-width:0!important;width:100%!important;box-sizing:border-box!important;text-align:center!important;padding-left:2px!important;padding-right:2px!important;overflow:hidden!important;text-overflow:clip!important}
.loads-compact .load-actions{display:grid!important;grid-template-columns:1fr 1fr!important;gap:4px!important;width:100%!important;min-width:0!important}
.loads-compact .load-actions form{margin:0!important;min-width:0!important;width:100%!important}
.loads-compact .load-action-btn{display:block!important;width:100%!important;min-width:0!important;box-sizing:border-box!important;text-align:center!important;padding-left:3px!important;padding-right:3px!important}
@media(max-width:1100px){
 .loads-compact th:nth-child(7),.loads-compact td:nth-child(7){width:17%}
 .loads-compact th:nth-child(8),.loads-compact td:nth-child(8){width:17%}
 .loads-compact th:nth-child(10),.loads-compact td:nth-child(10){width:17%}
 .loads-compact th:nth-child(11),.loads-compact td:nth-child(11){width:10%}
}


/* V1.58 site-wide error popup */
.flash{font-size:15px;}
.site-error-popup{position:fixed;inset:0;z-index:99999;display:flex;align-items:flex-start;justify-content:center;padding:72px 18px 18px;background:rgba(17,32,51,.16);}
.site-error-popup-box{position:relative;width:min(760px,94vw);background:#fff7f7;border:2px solid #dc3545;border-radius:10px;box-shadow:0 12px 34px rgba(0,0,0,.24);padding:22px 48px 22px 24px;}
.site-error-message{color:#c51f2d;font-size:20px;line-height:1.38;font-weight:700;margin:0;}
.site-error-message+.site-error-message{margin-top:12px;padding-top:12px;border-top:1px solid #efb6bc;}
.site-error-close{position:absolute;right:10px;top:8px;width:32px;height:32px;padding:0;margin:0;border-radius:50%;background:#dc3545;color:white;font-size:24px;line-height:30px;font-weight:700;cursor:pointer;}
@media(max-width:700px){.site-error-popup{padding-top:46px}.site-error-popup-box{padding:18px 42px 18px 18px}.site-error-message{font-size:18px}}


/* V1.59 Create Load: clearly separated field cards with white gutters */
.create-load-panel{
  background:#ffffff!important;
  border:1px solid #d6dee8!important;
  border-radius:10px!important;
  padding:0 10px 12px!important;
  overflow:visible;
}
.create-load-summary{
  margin:0 -10px 10px!important;
  padding:9px 12px!important;
  background:#17385f;
  color:#fff;
  border-radius:9px 9px 0 0;
  font-size:15px;
  font-weight:800;
}
.create-load-panel .load-grid{
  background:#ffffff!important;
  gap:10px!important;
  padding:0!important;
  align-items:stretch!important;
}
.create-load-panel .load-grid>label,
.create-load-panel .load-grid>.create-load-cell{
  background:#e4ebf3!important;
  border:1px solid #cbd6e2;
  border-radius:9px;
  padding:10px!important;
  min-width:0;
  box-shadow:0 1px 2px rgba(23,56,95,.05);
}
.create-load-panel .load-grid>label{
  justify-content:flex-start;
}
.create-load-panel .load-label{
  color:#153659;
  font-weight:800;
  line-height:1.15;
  margin-bottom:3px;
}
.create-load-panel input,
.create-load-panel select{
  background:#fff;
  border-color:#bac7d5;
}
.create-load-panel label small{
  color:#526274;
  margin-top:5px;
}
.create-load-panel .create-load-cell{
  justify-content:flex-end;
}
.create-load-panel .create-load-btn{
  width:100%;
  min-height:38px;
  background:#1d63b7;
}
.create-load-panel .customer-row{
  gap:6px;
}
.create-load-panel .schedule-popup{
  z-index:3000;
}
@media(max-width:900px){
  .create-load-panel .load-grid{gap:8px!important}
  .create-load-panel .load-grid>label,.create-load-panel .load-grid>.create-load-cell{padding:9px!important}
}

/* V1.62 clean Drivers dashboard */
.drivers-pagehead{align-items:flex-start!important;gap:18px}
.driver-summary{display:flex;gap:10px;align-items:stretch;justify-content:flex-end;flex-wrap:nowrap}
.driver-summary-col{display:flex;flex-direction:column;gap:5px;min-width:150px;text-align:center}
.driver-summary-col .exp-badge{display:block;font-size:16px;padding:8px 10px;white-space:nowrap}
.driver-count{display:block;border-radius:8px;padding:7px 10px;font-size:17px;font-weight:800;white-space:nowrap}
.driver-summary-col.green .driver-count{background:#e7f7eb;color:#08752c;border:1px solid #a9dfb7}
.driver-summary-col.yellow .driver-count{background:#fff4cf;color:#815900;border:1px solid #efd16c}
.driver-summary-col.red .driver-count{background:#ffe2e2;color:#b51d1d;border:1px solid #f1a5a5}
.driver-clean-table{width:100%;table-layout:fixed}
.driver-clean-table th:nth-child(2){width:25%}.driver-clean-table th:nth-child(3){width:15%}.driver-clean-table th:nth-child(4){width:14%}.driver-clean-table th:nth-child(5){width:16%}.driver-clean-table th:nth-child(6){width:10%}.driver-clean-table th:nth-child(7){width:20%}
.driver-clean-table th,.driver-clean-table td{text-align:center;vertical-align:middle;padding:9px 8px}
.driver-clean-table .driver-name{text-align:left;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.driver-info-btn{border:0;cursor:pointer;font-weight:800;min-width:100px}
.driver-active-badge{display:inline-block;background:#e1f5e6;color:#08752c;border:1px solid #a9dfb7;border-radius:8px;padding:6px 12px;font-weight:800}.driver-active-badge.inactive{background:#eee;color:#555;border-color:#ccc}
.driver-actions{display:flex!important;justify-content:center;align-items:center;gap:7px;flex-wrap:nowrap}.driver-actions form{margin:0}.driver-actions .editlink,.driver-actions .deletebtn{white-space:nowrap;padding:8px 12px}
.driver-info-modal{display:none;position:fixed;inset:0;z-index:100000;background:rgba(18,35,56,.38);align-items:center;justify-content:center;padding:18px}.driver-info-modal.open{display:flex}
.driver-info-box{position:relative;width:min(650px,94vw);max-height:88vh;overflow:auto;background:#fff;border-radius:12px;border:1px solid #cbd6e2;box-shadow:0 18px 50px rgba(0,0,0,.25);padding:20px}.driver-info-box h2{margin:0 42px 14px 0;color:#14213a}.driver-info-close{position:absolute;right:12px;top:10px;width:34px;height:34px;padding:0;border-radius:50%;font-size:25px;line-height:30px;background:#c8241d;color:#fff;cursor:pointer}.driver-info-list{border:1px solid #d8e0e9;border-radius:9px;overflow:hidden}.driver-info-list>div{display:grid;grid-template-columns:42% 58%;gap:10px;padding:9px 12px;border-bottom:1px solid #e3e8ee;background:#f7f9fb}.driver-info-list>div:nth-child(even){background:#fff}.driver-info-list>div:last-child{border-bottom:0}.driver-info-list b{color:#17385f}.driver-popup-actions{display:flex;gap:8px;margin-top:14px;justify-content:flex-end}
@media(max-width:900px){.drivers-pagehead{display:block!important}.driver-summary{justify-content:flex-start;margin-top:12px;overflow-x:auto}.driver-summary-col{min-width:135px}.driver-clean-table th,.driver-clean-table td{font-size:12px;padding:7px 4px}.driver-actions .editlink,.driver-actions .deletebtn{padding:6px 7px;font-size:11px}}

/* V1.63 Drivers: compact rows/buttons, larger names, compact summary beside heading */
.drivers-pagehead{display:flex!important;align-items:flex-start!important;justify-content:space-between!important;gap:16px!important}
.drivers-pagehead>div:first-child{min-width:0;flex:1 1 auto}
.driver-summary{flex:0 0 auto!important;gap:7px!important}
.driver-summary-col{min-width:128px!important;gap:4px!important}
.driver-summary-col .exp-badge{font-size:13px!important;padding:6px 8px!important}
.driver-count{font-size:14px!important;padding:5px 8px!important}
.driver-clean-table th,.driver-clean-table td{padding:5px 7px!important;height:38px!important;line-height:1.12!important}
.driver-clean-table .driver-name{font-size:15px!important;font-weight:800!important}
.driver-info-btn{min-width:0!important;padding:6px 10px!important;font-size:12px!important;line-height:1.1!important}
.driver-actions{gap:5px!important}
.driver-actions .editlink,.driver-actions .deletebtn{padding:6px 9px!important;font-size:12px!important;line-height:1.1!important;min-height:0!important}
.driver-clean-table .exp-badge,.driver-clean-table .driver-active-badge{padding:5px 9px!important;font-size:12px!important;line-height:1.1!important}
.driver-table-wrap .driver-clean-table tr{height:40px!important}
.driver-table-wrap .driver-clean-table td{border-top-width:1px!important;border-bottom-width:1px!important}
@media(max-width:900px){
 .drivers-pagehead{display:block!important}
 .driver-summary{margin-top:8px!important}
 .driver-summary-col{min-width:116px!important}
 .driver-summary-col .exp-badge{font-size:12px!important;padding:5px 6px!important}
 .driver-count{font-size:13px!important;padding:4px 6px!important}
 .driver-clean-table .driver-name{font-size:14px!important}
}


/* V1.64 Drivers final header/accordion layout */
.drivers-pagehead{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:18px!important;
  margin-bottom:8px!important;
}
.drivers-pagehead h1{margin-bottom:2px!important}
.drivers-pagehead .muted{margin:0!important}
.driver-summary{
  display:flex!important;
  flex:0 0 auto!important;
  gap:7px!important;
  align-items:stretch!important;
  justify-content:flex-end!important;
}
.driver-summary-col{min-width:118px!important;gap:3px!important}
.driver-summary-col .exp-badge{font-size:12px!important;padding:5px 7px!important;border-radius:7px!important}
.driver-count{font-size:13px!important;padding:4px 7px!important;border-radius:7px!important}

/* Driver add area starts closed by default; compact when closed */
.drivers-pagehead + details{margin-top:5px!important}
.drivers-pagehead + details > summary{
  padding:8px 12px!important;
  font-size:14px!important;
  font-weight:800!important;
  cursor:pointer!important;
}
.drivers-pagehead + details:not([open]){padding-bottom:0!important}

@media(max-width:900px){
  .drivers-pagehead{display:block!important}
  .driver-summary{justify-content:flex-start!important;margin-top:8px!important;overflow-x:auto!important}
  .driver-summary-col{min-width:108px!important}
}

/* V1.65 Trucks: important compliance buttons + All Docs popup */
.truck-add-panel>summary{font-weight:800;cursor:pointer}
.truck-clean-table{width:100%!important;table-layout:fixed!important}
.truck-clean-table th,.truck-clean-table td{padding:6px 5px!important;vertical-align:middle!important;text-align:center!important;font-size:12px!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
.truck-clean-table th:nth-child(2){width:7%}.truck-clean-table th:nth-child(3){width:5%}.truck-clean-table th:nth-child(4){width:13%}.truck-clean-table th:nth-child(5){width:14%}.truck-clean-table th:nth-child(6){width:8%}.truck-clean-table th:nth-child(7){width:10%}.truck-clean-table th:nth-child(8){width:8%}.truck-clean-table th:nth-child(9){width:9%}.truck-clean-table th:nth-child(10){width:8%}.truck-clean-table th:nth-child(11){width:18%}
.truck-clean-table .truck-unit{font-size:15px!important;font-weight:800!important;text-align:left!important}
.truck-doc-btn{display:inline-block;min-width:66px;padding:6px 8px;border-radius:7px;text-decoration:none!important;font-weight:800;font-size:11px;line-height:1.1;border:1px solid transparent}
.truck-doc-btn.exp-green{background:#e1f5e6;color:#08752c;border-color:#9edbad}.truck-doc-btn.exp-yellow{background:#fff2c8;color:#805a00;border-color:#edcd58}.truck-doc-btn.exp-red{background:#ffdede;color:#b51d1d;border-color:#ef9999}.truck-doc-btn.exp-none{background:#eef1f4;color:#59697c;border-color:#cbd3dc}
.truck-all-docs-btn{border:0;cursor:pointer;padding:6px 9px!important;font-size:11px!important;font-weight:800!important}
.truck-status-badge{display:inline-block;background:#e1f5e6;color:#08752c;border:1px solid #a9dfb7;border-radius:7px;padding:5px 8px;font-weight:800;font-size:11px}.truck-status-badge.inactive{background:#eee;color:#555;border-color:#ccc}
.truck-actions{display:flex!important;justify-content:center!important;gap:5px!important;flex-wrap:nowrap!important}.truck-actions form{margin:0!important}.truck-actions .editlink,.truck-actions .deletebtn{padding:6px 9px!important;font-size:11px!important;line-height:1.1!important;white-space:nowrap!important}
.truck-docs-box{width:min(820px,95vw)!important}.truck-doc-popup-summary{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:12px}.truck-doc-popup-summary>div{display:grid;grid-template-columns:1fr auto;gap:6px 10px;align-items:center;background:#f4f7fa;border:1px solid #d6dfe8;border-radius:8px;padding:10px}.truck-doc-popup-summary small{grid-column:1/-1;color:#59697c}.truck-doc-list{border:1px solid #d8e0e9;border-radius:9px;overflow:hidden}.truck-doc-row{display:grid;grid-template-columns:42% 38% 20%;gap:8px;align-items:center;padding:8px 10px;border-bottom:1px solid #e3e8ee}.truck-doc-row:nth-child(even){background:#f7f9fb}.truck-doc-row:last-child{border-bottom:0}.truck-doc-row>div:nth-child(2){display:flex;align-items:center;gap:7px;justify-content:center}.truck-doc-row>div:last-child{text-align:right}.truck-doc-row small{display:block;color:#667789;margin-top:2px}
@media(max-width:1000px){.truck-clean-table th,.truck-clean-table td{font-size:10px!important;padding:5px 3px!important}.truck-doc-btn,.truck-all-docs-btn,.truck-actions .editlink,.truck-actions .deletebtn{font-size:9px!important;padding:5px 5px!important}.truck-clean-table .truck-unit{font-size:13px!important}.truck-doc-popup-summary{grid-template-columns:1fr}.truck-doc-row{grid-template-columns:1fr}.truck-doc-row>div:nth-child(2){justify-content:flex-start}.truck-doc-row>div:last-child{text-align:left}}
\n\n/* V1.66 Trucks: associated driver + day-status wording */\n.truck-clean-table th:nth-child(2){width:7%!important}\n.truck-clean-table th:nth-child(3){width:11%!important}\n.truck-clean-table th:nth-child(4){width:5%!important}\n.truck-clean-table th:nth-child(5){width:11%!important}\n.truck-clean-table th:nth-child(6){width:12%!important}\n.truck-clean-table th:nth-child(7){width:7%!important}\n.truck-clean-table th:nth-child(8){width:11%!important}\n.truck-clean-table th:nth-child(9){width:10%!important}\n.truck-clean-table th:nth-child(10){width:8%!important}\n.truck-clean-table th:nth-child(11){width:7%!important}\n.truck-clean-table th:nth-child(12){width:11%!important}\n.truck-driver{font-size:13px!important;font-weight:700!important;color:#17385f!important}\n.truck-doc-btn{min-width:92px!important;padding:6px 9px!important;font-size:11px!important}\n@media(max-width:1000px){\n .truck-driver{font-size:11px!important}\n .truck-doc-btn{min-width:76px!important;font-size:9px!important;padding:5px 5px!important}\n}\n

/* V1.67 Trucks: compact proportional columns, clickable Truck Info, last 6 VIN */
.truck-clean-table th:nth-child(2),.truck-clean-table td:nth-child(2){width:6%!important}
.truck-clean-table th:nth-child(3),.truck-clean-table td:nth-child(3){width:11%!important}
.truck-clean-table th:nth-child(4),.truck-clean-table td:nth-child(4){width:6%!important}
.truck-clean-table th:nth-child(5),.truck-clean-table td:nth-child(5){width:13%!important}
.truck-clean-table th:nth-child(6),.truck-clean-table td:nth-child(6){width:7%!important}
.truck-clean-table th:nth-child(7),.truck-clean-table td:nth-child(7){width:8%!important}
.truck-clean-table th:nth-child(8),.truck-clean-table td:nth-child(8){width:11%!important}
.truck-clean-table th:nth-child(9),.truck-clean-table td:nth-child(9){width:9%!important}
.truck-clean-table th:nth-child(10),.truck-clean-table td:nth-child(10){width:8%!important}
.truck-clean-table th:nth-child(11),.truck-clean-table td:nth-child(11){width:8%!important}
.truck-clean-table th:nth-child(12),.truck-clean-table td:nth-child(12){width:13%!important}
.truck-clean-table th,.truck-clean-table td{font-size:clamp(10px,.78vw,13px)!important;padding:6px 5px!important}
.truck-clean-table .truck-driver{overflow:visible!important;text-overflow:clip!important;white-space:nowrap!important;font-size:clamp(11px,.82vw,14px)!important}
.truck-unit-btn{border:0;background:transparent;color:#0d4f9a;font:inherit;font-size:clamp(14px,1.15vw,18px)!important;font-weight:900!important;padding:0!important;cursor:pointer;text-decoration:underline;text-underline-offset:2px}
.truck-vin-short{font-weight:700;letter-spacing:.2px}
.truck-clean-table .truck-doc-btn{min-width:0!important;width:auto!important;max-width:100%!important;padding:6px 8px!important;white-space:nowrap!important;font-size:clamp(9px,.7vw,11px)!important}
.truck-clean-table .truck-all-docs-btn{padding:6px 8px!important;font-size:clamp(9px,.7vw,11px)!important;white-space:nowrap!important}
.truck-clean-table .truck-status-badge{padding:5px 8px!important;font-size:clamp(9px,.7vw,11px)!important}
.truck-clean-table .truck-actions .editlink,.truck-clean-table .truck-actions .deletebtn{padding:6px 8px!important;font-size:clamp(9px,.7vw,11px)!important}
.truck-info-box{width:min(700px,94vw)!important}
.truck-info-list{display:grid;grid-template-columns:1fr 1fr;gap:0;border:1px solid #d7e0e9;border-radius:9px;overflow:hidden;margin:10px 0 14px}
.truck-info-list>div{display:grid;grid-template-columns:42% 58%;gap:8px;padding:9px 11px;border-bottom:1px solid #e2e8ef;background:#fff;align-items:center}
.truck-info-list>div:nth-child(even){background:#f6f8fb}
.truck-info-list>div:nth-last-child(-n+2){border-bottom:0}
.truck-info-list b{color:#18365a}
.truck-info-list span{min-width:0;overflow-wrap:anywhere}
@media(max-width:900px){.truck-info-list{grid-template-columns:1fr}.truck-info-list>div:nth-last-child(-n+2){border-bottom:1px solid #e2e8ef}.truck-info-list>div:last-child{border-bottom:0}.truck-clean-table th,.truck-clean-table td{font-size:9px!important;padding:4px 3px!important}.truck-clean-table .truck-driver{font-size:10px!important}}


/* V1.68 Truck #: tiny detail hint + arrow */
.truck-unit-btn{display:inline-flex!important;flex-direction:column!important;align-items:flex-start!important;justify-content:center!important;line-height:1.05!important;text-decoration:none!important}
.truck-unit-main{text-decoration:underline;text-underline-offset:2px;white-space:nowrap}
.truck-detail-arrow{font-size:.62em!important;text-decoration:none!important;display:inline-block!important;margin-left:2px!important;vertical-align:middle!important}
.truck-detail-hint{display:block!important;font-size:8px!important;font-weight:600!important;color:#6c7887!important;letter-spacing:0!important;margin-top:3px!important;white-space:nowrap!important;text-decoration:none!important}


/* V1.71 Customers/Brokers compact follow-up action dashboard */
.customer-add-panel{background:#fff;border:1px solid #d8dee7;border-radius:10px;margin-bottom:12px}.customer-add-panel>summary{font-weight:800;padding:10px 12px;cursor:pointer}.customer-add-grid label{background:#eef3f8;border:1px solid #d4dde8;border-radius:8px;padding:8px}.customer-clean-table{width:100%;table-layout:fixed}.customer-clean-table th,.customer-clean-table td{padding:7px 6px!important;vertical-align:middle!important;font-size:12px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.customer-clean-table th:nth-child(2){width:15%}.customer-clean-table th:nth-child(3){width:10%}.customer-clean-table th:nth-child(4){width:12%}.customer-clean-table th:nth-child(5){width:10%}.customer-clean-table th:nth-child(6){width:16%}.customer-clean-table th:nth-child(7){width:17%}.customer-clean-table th:nth-child(8){width:10%}.customer-clean-table th:nth-child(9){width:10%}.customer-days-btn,.customer-days-inline{display:inline-block;border-radius:8px;padding:6px 9px;font-weight:800;font-size:11px;white-space:nowrap;border:1px solid transparent}.customer-days-btn{cursor:pointer}.customer-days-btn.exp-green,.customer-days-inline.exp-green{background:#e1f5e6;color:#08752c;border-color:#9edbad}.customer-days-btn.exp-yellow,.customer-days-inline.exp-yellow{background:#fff2c8;color:#805a00;border-color:#edcd58}.customer-days-btn.exp-red,.customer-days-inline.exp-red{background:#ffdede;color:#b51d1d;border-color:#ef9999}.customer-days-btn.exp-none,.customer-days-inline.exp-none{background:#eef1f4;color:#59697c;border-color:#cbd3dc}.customer-actions{display:flex!important;gap:5px!important;justify-content:center!important;flex-wrap:nowrap!important}.customer-actions form{margin:0!important}.customer-actions .editlink,.customer-actions .deletebtn{font-size:11px!important;padding:6px 9px!important}.customer-action-modal{display:none;position:fixed;inset:0;background:rgba(15,28,45,.38);z-index:9999;align-items:center;justify-content:center;padding:20px}.customer-action-box{position:relative;background:#fff;width:min(680px,94vw);border-radius:12px;padding:18px;box-shadow:0 16px 50px rgba(0,0,0,.25)}.customer-action-close{position:absolute;right:12px;top:8px;border:0;background:transparent;font-size:28px;cursor:pointer}.customer-action-list{border:1px solid #d7e0e9;border-radius:9px;overflow:hidden}.customer-action-list>div{display:grid;grid-template-columns:32% 68%;gap:8px;padding:10px 12px;border-bottom:1px solid #e2e8ef;background:#f5f8fb}.customer-action-list>div:nth-child(even){background:#fff}.customer-action-list>div:last-child{border-bottom:0}.customer-note-full span{white-space:normal;overflow-wrap:anywhere}.customer-note{color:#344b65}
/* V1.72 customer action workflow */
.customer-action-type-line{display:flex;gap:6px;align-items:center}.customer-action-type-line select{min-width:0;flex:1}.customer-add-type-btn,.customer-action-type-btn{background:#1769aa;color:#fff;border:0;border-radius:6px;font-weight:700;font-size:11px;padding:6px 10px;white-space:nowrap}.customer-add-type-btn{padding:7px 9px}.customer-action-type-btn:hover,.customer-add-type-btn:hover{filter:brightness(.94)}

/* V1.73 Customers/Brokers: conversation notes + next action column */
.customer-v173-table th:nth-child(2),.customer-v173-table td:nth-child(2){width:13%!important}.customer-v173-table th:nth-child(3),.customer-v173-table td:nth-child(3){width:9%!important}.customer-v173-table th:nth-child(4),.customer-v173-table td:nth-child(4){width:10%!important}.customer-v173-table th:nth-child(5),.customer-v173-table td:nth-child(5){width:9%!important}.customer-v173-table th:nth-child(6),.customer-v173-table td:nth-child(6){width:14%!important}.customer-v173-table th:nth-child(7),.customer-v173-table td:nth-child(7){width:9%!important}.customer-v173-table th:nth-child(8),.customer-v173-table td:nth-child(8){width:10%!important}.customer-v173-table th:nth-child(9),.customer-v173-table td:nth-child(9){width:12%!important}.customer-v173-table th:nth-child(10),.customer-v173-table td:nth-child(10){width:14%!important}
.customer-note-btn,.customer-next-action-btn{border:1px solid #bfcbd8;border-radius:7px;padding:6px 9px;font-weight:800;font-size:11px;white-space:nowrap;cursor:pointer}.customer-note-btn{background:#e7f0fa;color:#174f86}.customer-next-action-btn.has-action{background:#e8f2fb;color:#125c99;border-color:#a9cbe5}.customer-next-action-btn.no-action{background:#eef1f4;color:#59697c;border-color:#cbd3dc}.customer-note-history-box{width:min(820px,96vw)!important;max-height:92vh;overflow:auto}.customer-current-action{display:flex;gap:10px;align-items:center;flex-wrap:wrap;background:#eef3f8;border:1px solid #d4dde8;border-radius:8px;padding:9px 11px;margin:6px 0 12px}.customer-next-action-inline{font-weight:900;color:#174f86}.customer-note-entry-form{display:grid;grid-template-columns:1.2fr .8fr .9fr auto;gap:8px;align-items:end;background:#f4f7fa;border:1px solid #d7e0e9;border-radius:9px;padding:10px}.customer-note-entry-form label{font-weight:700;color:#243e5c}.customer-note-entry-form input,.customer-note-entry-form select,.customer-note-entry-form textarea{width:100%;box-sizing:border-box;margin-top:4px}.customer-note-wide{grid-column:1/-1}.customer-note-entry-form textarea{min-height:82px;resize:vertical}.customer-save-note-btn{background:#1f7a3f;color:#fff;border:0;border-radius:7px;padding:8px 12px;font-weight:800;white-space:nowrap}.customer-note-history-title{margin:14px 0 7px}.customer-note-history{border:1px solid #d7e0e9;border-radius:9px;overflow:hidden}.customer-history-item{padding:10px 12px;border-bottom:1px solid #e2e8ef;background:#fff}.customer-history-item:nth-child(even){background:#f7f9fb}.customer-history-item:last-child{border-bottom:0}.customer-history-top{display:flex;justify-content:space-between;gap:12px;color:#294766;font-size:12px}.customer-history-top span{color:#6b7887;font-size:11px}.customer-history-message{white-space:pre-wrap;overflow-wrap:anywhere;margin:7px 0;color:#1f2f40}.customer-history-next{font-size:12px;color:#4a5d70;background:#eef3f8;border-radius:6px;padding:5px 7px;display:inline-block}.customer-no-notes{padding:14px;color:#687789;text-align:center;background:#f8fafc}
@media(max-width:900px){.customer-note-entry-form{grid-template-columns:1fr 1fr}.customer-note-wide{grid-column:1/-1}.customer-save-note-btn{width:100%}.customer-v173-table th,.customer-v173-table td{font-size:9px!important;padding:4px 3px!important}.customer-note-btn,.customer-next-action-btn,.customer-days-btn{font-size:9px!important;padding:5px 5px!important}}


/* V1.74 Customers/Brokers: large, polished note entry popup */
.customer-note-history-box{
  width:min(1040px,97vw)!important;
  max-height:94vh!important;
  padding:24px!important;
  border:1px solid #cbd8e6;
  border-radius:16px!important;
  box-shadow:0 24px 70px rgba(13,35,60,.30)!important;
}
.customer-note-history-box h2{
  margin:0 42px 14px 0;
  padding:0 0 12px;
  border-bottom:2px solid #dbe5ef;
  color:#173b63;
  font-size:24px;
}
.customer-note-history-box .customer-action-close{
  width:36px;height:36px;line-height:32px;
  border-radius:50%;background:#eef3f8;color:#36536f;
  top:16px;right:16px;font-size:26px;font-weight:700;
}
.customer-note-history-box .customer-action-close:hover{background:#dfe8f1;color:#173b63}
.customer-current-action{
  background:#edf4fb!important;
  border-color:#c8d9ea!important;
  padding:11px 13px!important;
  margin-bottom:14px!important;
}
.customer-note-entry-form{
  grid-template-columns:1fr 1fr 1fr auto!important;
  gap:12px!important;
  padding:16px!important;
  background:#f5f8fc!important;
  border:1px solid #cad8e6!important;
  border-radius:12px!important;
}
.customer-note-entry-form label{font-size:13px!important;color:#173b63!important}
.customer-note-entry-form input,.customer-note-entry-form select,.customer-note-entry-form textarea{
  border:1px solid #b8c8d8!important;
  border-radius:8px!important;
  background:#fff!important;
  padding:9px 10px!important;
  font-size:13px!important;
}
.customer-note-entry-form textarea{
  min-height:210px!important;
  max-height:420px;
  resize:vertical;
  line-height:1.5;
  font-size:14px!important;
  padding:13px!important;
}
.customer-note-entry-form textarea:focus,.customer-note-entry-form input:focus,.customer-note-entry-form select:focus{
  outline:none;
  border-color:#5a91c5!important;
  box-shadow:0 0 0 3px rgba(73,132,188,.13);
}
.customer-note-wide{grid-column:1/-1!important}
.customer-save-note-btn{
  min-height:40px;
  padding:9px 18px!important;
  border-radius:8px!important;
  box-shadow:0 2px 7px rgba(31,122,63,.18);
}
.customer-note-history-title{
  color:#173b63;
  font-size:17px;
  margin-top:18px!important;
}
.customer-note-history{border-radius:11px!important;border-color:#cedae6!important}
.customer-history-item{padding:13px 15px!important}
.customer-history-message{font-size:13px;line-height:1.5}
@media(max-width:900px){
  .customer-note-history-box{width:98vw!important;padding:14px!important;max-height:96vh!important}
  .customer-note-entry-form{grid-template-columns:1fr 1fr!important;padding:12px!important}
  .customer-note-entry-form textarea{min-height:180px!important}
}
@media(max-width:620px){
  .customer-note-entry-form{grid-template-columns:1fr!important}
  .customer-note-wide{grid-column:1!important}
  .customer-save-note-btn{width:100%}
  .customer-note-history-box h2{font-size:20px}
}

/* V1.75: notes modal is a true full-screen popup, matching Driver Info proportions */
.customer-action-modal{position:fixed!important;inset:0!important;width:100vw!important;height:100vh!important;z-index:10050!important;background:rgba(20,37,57,.48)!important;align-items:center!important;justify-content:center!important;padding:30px 42px!important;box-sizing:border-box!important;overflow:auto!important}
.customer-note-history-box{position:relative!important;width:min(1140px,96vw)!important;max-height:92vh!important;overflow-y:auto!important;margin:auto!important;background:#fff!important;border-radius:16px!important;padding:28px 34px!important}
.customer-note-entry-form textarea{display:block!important;width:100%!important;min-height:240px!important;font-size:16px!important;line-height:1.55!important}
@media(max-width:700px){.customer-action-modal{padding:10px!important}.customer-note-history-box{width:98vw!important;padding:18px!important}.customer-note-entry-form textarea{min-height:200px!important}}

/* V1.79: note history name emphasis + clear popup exit button */
.customer-history-top b{color:#16833f!important;font-weight:900!important;font-size:14px!important}
.customer-note-history-box .customer-action-close{
  position:fixed!important;
  right:20px!important;
  top:18px!important;
  width:52px!important;
  height:52px!important;
  border-radius:50%!important;
  border:0!important;
  background:#cf2117!important;
  color:#fff!important;
  font-size:34px!important;
  font-weight:900!important;
  line-height:48px!important;
  text-align:center!important;
  cursor:pointer!important;
  box-shadow:0 4px 12px rgba(0,0,0,.18)!important;
}
.customer-note-history-box .customer-action-close:hover{background:#a91810!important;color:#fff!important}
.customer-note-history-box h2{padding-right:72px!important}
/* V1.79 note accountability, timed locking, and admin controls */
.customer-lock-policy{margin-left:12px;padding:5px 9px;border-radius:6px;background:#eef3f8;color:#536579;font-size:12px;font-weight:700}
.customer-note-controls{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-top:9px}.customer-note-controls form{margin:0}.note-locked-badge{background:#edf1f5;color:#5a6674;border:1px solid #cbd2da;border-radius:6px;padding:5px 8px;font-weight:800;font-size:12px}.note-edit-window{background:#fff5d8;color:#795600;border:1px solid #efcf67;border-radius:6px;padding:5px 8px;font-weight:800;font-size:12px}.note-manager-badge{background:#e8f7ec;color:#087425;border:1px solid #9bd8a7;border-radius:6px;padding:5px 8px;font-weight:800;font-size:12px}.note-edit-btn,.note-cancel-btn{padding:6px 10px;border-radius:6px;font-size:12px}.note-edit-btn{background:#1d5da8}.note-cancel-btn{background:#64748b}.note-delete-btn,.note-delete-all-btn{background:#b42318;color:#fff;padding:6px 10px;border-radius:6px;font-size:12px}.customer-note-edit-form{margin-top:10px;background:#f5f8fb;border:1px solid #d2dce7;border-radius:8px;padding:12px}.customer-note-edit-form textarea{width:100%;min-height:150px;resize:vertical;margin-top:5px;padding:10px;font:inherit}.customer-note-edit-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:8px 0}.clear-note-history-form{text-align:right;margin-top:12px}.note-delete-all-btn{padding:8px 12px;font-weight:800}

.note-disabled-btn{background:#d7dce2!important;color:#7b8490!important;border:1px solid #c2c8cf!important;padding:6px 10px;border-radius:6px;font-size:12px;font-weight:700;cursor:not-allowed!important;opacity:.78;box-shadow:none!important;pointer-events:none}

/* V1.85 clean Compliance & Documents center */
.compliance-section{margin:18px 0 24px;border:1px solid #cfd8e3;border-radius:14px;background:#f8fafc;overflow:hidden}
.compliance-section-head{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 18px;background:#e8eef6;border-bottom:1px solid #cfd8e3}.compliance-section-head h2{margin:0}
.compliance-addtype{display:flex;gap:8px;align-items:center}.compliance-addtype input{min-width:220px}.compliance-addtype button{white-space:nowrap}
.compliance-entity{margin:12px 16px 18px;background:#fff;border:1px solid #d8e0ea;border-radius:12px;overflow:hidden}.compliance-entity h3{margin:0;padding:11px 14px;background:#f1f5f9;border-bottom:1px solid #d8e0ea}
.compliance-doc-row{display:grid;grid-template-columns:minmax(180px,240px) 1fr;gap:12px;padding:10px 14px;border-bottom:1px solid #edf1f5}.compliance-doc-row:last-child{border-bottom:0}.compliance-doc-title{font-weight:800;padding-top:8px}
.compliance-doc-form{display:grid;grid-template-columns:minmax(170px,1.2fr) 160px 130px minmax(150px,1fr) auto auto;gap:10px;align-items:end}.compliance-doc-form label{font-size:12px;font-weight:700}.compliance-doc-form input{width:100%}.compliance-days{align-self:center;padding-bottom:3px}.compliance-doc-form .savebtn{background:#16833f;color:white;border:0}.compliance-doc-form .editlink{align-self:center;white-space:nowrap}
@media(max-width:1000px){.compliance-doc-row{grid-template-columns:1fr}.compliance-doc-form{grid-template-columns:1fr 1fr}.compliance-section-head{align-items:flex-start;flex-direction:column}.compliance-addtype{width:100%}.compliance-addtype input{min-width:0;flex:1}}

/* V1.87: collapsible Driver / Truck / Trailer / Zebra Trucking LLC compliance sections */
.compliance-collapsible{overflow:hidden}
.compliance-summary{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 18px;background:#e8eef6;font-size:22px;font-weight:900;cursor:pointer;list-style:none;user-select:none}
.compliance-summary::-webkit-details-marker{display:none}
.compliance-summary:hover{background:#dde7f2}
.compliance-arrow{font-size:18px;transition:transform .18s ease}
.compliance-collapsible[open] .compliance-arrow{transform:rotate(180deg)}
.compliance-collapsible-body{padding-bottom:6px}
.compliance-collapsible-body .compliance-section-head{border-top:1px solid #cfd8e3;border-bottom:1px solid #cfd8e3;justify-content:flex-end}
.compliance-empty{padding:0 16px 14px}

/* V1.88 Compliance: visible upload controls, row colors, section and grand totals */
.compliance-total-summary{display:grid;grid-template-columns:repeat(5,minmax(130px,1fr));gap:10px;margin:14px 0 18px}
.compliance-total-card{border:1px solid #cfd8e3;border-radius:10px;padding:10px 12px;text-align:center;background:#fff;display:flex;flex-direction:column;gap:3px}
.compliance-total-card span{font-size:12px;font-weight:800}.compliance-total-card b{font-size:24px}
.compliance-total-green{background:#e6f6e9;border-color:#9bd8a7}.compliance-total-green b{color:#16833f}
.compliance-total-yellow{background:#fff8d9;border-color:#e9cf65}.compliance-total-yellow b{color:#7a5a00}
.compliance-total-red{background:#ffe6e3;border-color:#ee9c95}.compliance-total-red b{color:#b42318}
.compliance-total-none{background:#eef2f6;border-color:#cbd2da}.compliance-total-none b{color:#596675}
.compliance-section-counts{display:flex;gap:5px;flex-wrap:wrap;align-items:center;margin-left:auto}
.count-pill{font-size:11px;font-weight:900;border-radius:999px;padding:4px 7px;border:1px solid transparent;white-space:nowrap}
.count-green{background:#d9f2df;color:#176b2c;border-color:#8fd39e}.count-yellow{background:#fff3bf;color:#705400;border-color:#e8cf64}.count-red{background:#ffd9d6;color:#9d1c12;border-color:#ee9188}.count-none{background:#edf1f5;color:#596675;border-color:#cbd2da}.count-total{background:#e7eef8;color:#173d73;border-color:#b9cbe1}
.compliance-doc-row{border-left:7px solid #cbd2da!important}
.compliance-doc-row.exp-green{border-left-color:#2e9b42!important;background:#f6fcf7}.compliance-doc-row.exp-yellow{border-left-color:#e1b600!important;background:#fffdf3}.compliance-doc-row.exp-red{border-left-color:#e52b24!important;background:#fff8f7}.compliance-doc-row.exp-none{border-left-color:#a9b3bf!important;background:#fbfcfd}
.compliance-doc-title{display:flex;align-items:center;gap:8px}.compliance-status-dot{width:13px;height:13px;border-radius:50%;display:inline-block;flex:0 0 13px;background:#a9b3bf}.compliance-status-dot.exp-green{background:#2e9b42}.compliance-status-dot.exp-yellow{background:#ffd22e}.compliance-status-dot.exp-red{background:#e52b24}.compliance-status-dot.exp-none{background:#a9b3bf}
.compliance-doc-form{grid-template-columns:minmax(180px,1.2fr) 110px 160px 130px minmax(150px,1fr) 86px!important}
.compliance-upload-btn{background:#16833f!important;color:#fff!important;border:0!important;font-weight:900!important;white-space:nowrap!important;min-height:38px!important}.compliance-upload-btn:hover{background:#116c34!important}
.compliance-open-file{display:inline-flex;align-items:center;justify-content:center;min-height:36px;padding:6px 8px;border-radius:6px;background:#eaf2fb;text-decoration:none;font-weight:800;white-space:nowrap}.compliance-no-file{align-self:center;text-align:center;white-space:nowrap}
.compliance-doc-form .exp-badge{min-width:118px;text-align:center}.compliance-doc-form .exp-green{background:#2e9b42;color:#fff;border-color:#237a34}.compliance-doc-form .exp-yellow{background:#ffd22e;color:#4f3a00;border-color:#d8ac00}.compliance-doc-form .exp-red{background:#e52b24;color:#fff;border-color:#bd201a}
@media(max-width:1100px){.compliance-doc-form{grid-template-columns:1fr 110px 160px 130px!important}.compliance-doc-form label:nth-of-type(3){grid-column:1/3}.compliance-section-counts{display:none}}
@media(max-width:700px){.compliance-total-summary{grid-template-columns:1fr 1fr}.compliance-total-all{grid-column:1/-1}.compliance-doc-form{grid-template-columns:1fr!important}.compliance-upload-btn,.compliance-open-file{width:100%}.compliance-doc-form label:nth-of-type(3){grid-column:auto}}

/* V1.89 compliance file picker visibility fix */
.compliance-file-picker{display:grid;grid-template-columns:minmax(150px,220px) minmax(130px,1fr);gap:8px;align-items:center;margin-top:4px}
.compliance-file-input{width:100%!important;min-width:0!important;padding:5px!important;background:#fff!important;border:1px solid #aebdca!important;border-radius:6px!important;cursor:pointer!important}
.compliance-selected-file{display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:8px 10px;border-radius:6px;background:#eef2f6;border:1px solid #ccd6df;color:#596b7c;font-weight:700}
.compliance-selected-file.has-file{background:#e6f5e9;border-color:#64ad72;color:#17672b}
@media(max-width:700px){.compliance-file-picker{grid-template-columns:1fr}.compliance-selected-file{white-space:normal}}


/* V1.91 compliance notes + file management */
.compliance-note-input{width:100%;min-height:38px;padding:8px 10px;border:1px solid #b7c4d0;border-radius:7px;background:#fff;font:inherit}
.compliance-note-input::placeholder{color:#788796}
.compliance-delete-file{background:#b42318!important;color:#fff!important;border:0!important;font-weight:800!important;white-space:nowrap!important;min-height:36px!important}
.compliance-delete-file:hover{background:#8f1b13!important}
.compliance-replace-file{background:#e7eef8!important;color:#173d73!important;border:1px solid #b9cbe1!important;font-weight:800!important;white-space:nowrap!important;min-height:36px!important}
.compliance-replace-file:hover{background:#dce7f5!important}
.compliance-doc-form{grid-template-columns:minmax(180px,1.15fr) 150px 155px 125px minmax(150px,1fr) 90px 100px 105px!important}
@media(max-width:1250px){.compliance-doc-form{grid-template-columns:1fr 150px 155px 125px!important}.compliance-note-input{grid-column:1/3}.compliance-open-file,.compliance-delete-file,.compliance-replace-file{width:100%}}
@media(max-width:700px){.compliance-note-input{grid-column:auto}.compliance-delete-file,.compliance-replace-file{width:100%}}

/* V1.92: per-record View Docs controls + familiar green/yellow/red compliance colors */
.compliance-entity-details{overflow:hidden}
.compliance-entity-summary{display:grid;grid-template-columns:minmax(180px,1fr) auto auto;gap:14px;align-items:center;padding:12px 14px;background:#f1f5f9;cursor:pointer;list-style:none;user-select:none}
.compliance-entity-summary::-webkit-details-marker{display:none}
.compliance-entity-summary:hover{background:#eaf0f6}
.compliance-entity-name{font-size:20px;font-weight:900;color:#10233f}
.compliance-entity-counts{display:grid;grid-template-columns:repeat(4,minmax(105px,1fr));gap:8px}
.entity-count{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:50px;padding:5px 10px;border-radius:10px;border:1px solid;font-weight:900;text-align:center}
.entity-count b{font-size:20px;line-height:1}.entity-count small{font-size:11px;margin-top:4px;white-space:nowrap}
.entity-green{background:#e7f7ea;border-color:#8ed49c;color:#067d22}
.entity-yellow{background:#fff5ca;border-color:#f0c850;color:#7b5900}
.entity-red{background:#ffe3e1;border-color:#ff9d94;color:#b01812}
.entity-none{background:#edf2f6;border-color:#c6d0da;color:#596878}
.compliance-view-docs{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-width:112px;padding:9px 12px;border-radius:8px;background:#1d5da8;color:#fff;font-weight:900;white-space:nowrap}
.compliance-entity-details[open] .compliance-view-docs{background:#64748b}
.compliance-entity-details[open] .entity-arrow{transform:rotate(180deg)}
.entity-arrow{display:inline-block;transition:transform .18s ease}
.compliance-entity-docs{border-top:1px solid #d8e0ea;background:#fff}
@media(max-width:1100px){.compliance-entity-summary{grid-template-columns:1fr auto}.compliance-entity-counts{grid-column:1/-1;grid-row:2}.compliance-view-docs{grid-column:2;grid-row:1}}
@media(max-width:700px){.compliance-entity-summary{grid-template-columns:1fr}.compliance-view-docs{grid-column:auto;grid-row:auto;width:100%}.compliance-entity-counts{grid-column:auto;grid-row:auto;grid-template-columns:1fr 1fr}.entity-count small{white-space:normal}}

/* V1.93: file actions always visible under every compliance item */
.compliance-doc-form{grid-template-columns:minmax(180px,1.15fr) 150px 155px 125px minmax(180px,1fr)!important}
.compliance-file-actions{grid-column:1/-1;display:flex;gap:10px;align-items:center;flex-wrap:wrap;padding-top:2px}
.compliance-open-file{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-height:38px!important;padding:7px 16px!important;border-radius:7px!important;background:#1d5da8!important;color:#fff!important;border:1px solid #174d8c!important;text-decoration:none!important;font-weight:900!important;white-space:nowrap!important}
.compliance-open-file:hover{background:#174d8c!important;color:#fff!important}
.compliance-open-disabled{background:#d9e0e7!important;color:#667584!important;border-color:#c2ccd6!important;cursor:not-allowed!important}
.compliance-open-disabled:hover{background:#d9e0e7!important;color:#667584!important}
@media(max-width:1250px){.compliance-doc-form{grid-template-columns:1fr 150px 155px 125px!important}.compliance-file-actions{grid-column:1/-1}}
@media(max-width:700px){.compliance-doc-form{grid-template-columns:1fr!important}.compliance-file-actions{grid-column:auto;display:grid;grid-template-columns:1fr}.compliance-open-file,.compliance-delete-file,.compliance-replace-file{width:100%!important}}

/* V1.94: Compliance page auto-fit to available screen width */
.compliance-section,.compliance-entity-details,.compliance-entity-docs,.compliance-doc-row{max-width:100%!important;box-sizing:border-box!important;overflow:hidden!important}
.compliance-doc-row{grid-template-columns:minmax(120px,16%) minmax(0,1fr)!important;gap:10px!important}
.compliance-doc-form{min-width:0!important;width:100%!important;max-width:100%!important;grid-template-columns:minmax(150px,1.25fr) minmax(125px,.8fr) minmax(120px,.72fr) minmax(110px,.7fr) minmax(130px,1fr)!important;gap:8px!important;align-items:end!important}
.compliance-doc-form>*{min-width:0!important;max-width:100%!important;box-sizing:border-box!important}
.compliance-file-picker{max-width:100%!important;overflow:hidden!important}
.compliance-file-input{max-width:100%!important;font-size:12px!important}
.compliance-selected-file{overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important;display:block!important}
.compliance-upload-btn,.compliance-open-file,.compliance-delete-file,.compliance-replace-file{font-size:12px!important;padding:7px 9px!important;min-width:0!important}
.compliance-file-actions{grid-column:1/-1!important;display:flex!important;gap:8px!important;align-items:center!important;flex-wrap:wrap!important;max-width:100%!important}
.compliance-note-input{min-width:0!important;width:100%!important}
.compliance-entity-summary{max-width:100%!important}
.compliance-entity-counts{min-width:0!important}
@media(max-width:1200px){.compliance-doc-row{grid-template-columns:1fr!important}.compliance-doc-form{grid-template-columns:minmax(140px,1.2fr) minmax(120px,.8fr) minmax(120px,.75fr) minmax(105px,.7fr)!important}.compliance-note-input{grid-column:1/-1!important}}
@media(max-width:800px){.compliance-doc-form{grid-template-columns:1fr 1fr!important}.compliance-upload-btn,.compliance-days{width:100%!important}.compliance-note-input{grid-column:1/-1!important}.compliance-file-actions{grid-template-columns:none!important}}
@media(max-width:560px){.compliance-doc-form{grid-template-columns:1fr!important}.compliance-note-input,.compliance-file-actions{grid-column:auto!important}.compliance-file-actions{display:grid!important;grid-template-columns:1fr!important}.compliance-open-file,.compliance-delete-file,.compliance-replace-file{width:100%!important}}

/* V1.95: compact Compliance layout for laptop + phone */
.compliance-section{margin:10px 0 14px!important;border-radius:10px!important}
.compliance-summary{min-height:42px!important;padding:8px 12px!important}
.compliance-collapsible-body{padding:8px!important}
.compliance-section-head{padding:8px 10px!important;gap:8px!important}
.compliance-addtype{gap:6px!important;margin:0!important}
.compliance-addtype input,.compliance-addtype button{min-height:32px!important;padding:5px 8px!important;font-size:12px!important}

.compliance-entity-details{margin:7px 0!important;border-radius:9px!important}
.compliance-entity-summary{padding:7px 10px!important;gap:8px!important;grid-template-columns:minmax(150px,1fr) auto auto!important}
.compliance-entity-name{font-size:15px!important;line-height:1.15!important}
.compliance-entity-counts{grid-template-columns:repeat(4,88px)!important;gap:5px!important}
.entity-count{min-height:38px!important;padding:3px 5px!important;border-radius:8px!important}
.entity-count b{font-size:16px!important}
.entity-count small{font-size:9px!important;margin-top:2px!important}
.compliance-view-docs{min-width:92px!important;padding:6px 8px!important;font-size:12px!important}

.compliance-doc-row{grid-template-columns:110px minmax(0,1fr)!important;gap:6px!important;padding:7px 9px!important;align-items:center!important}
.compliance-doc-title{font-size:13px!important;gap:6px!important;align-self:center!important}
.compliance-status-dot{width:10px!important;height:10px!important;flex-basis:10px!important}
.compliance-doc-form{display:grid!important;grid-template-columns:minmax(150px,1.15fr) 125px 118px 105px minmax(130px,.95fr) minmax(230px,1.35fr)!important;gap:6px!important;align-items:end!important}
.compliance-doc-form label{font-size:10px!important;line-height:1.05!important;margin:0!important}
.compliance-doc-form input[type=date],.compliance-note-input{min-height:32px!important;height:32px!important;padding:5px 7px!important;font-size:12px!important}
.compliance-file-picker{display:block!important;margin-top:2px!important}
.compliance-file-input{height:32px!important;padding:3px!important;font-size:11px!important}
.compliance-selected-file{display:none!important}
.compliance-upload-btn{min-height:32px!important;height:32px!important;padding:5px 7px!important;font-size:11px!important}
.compliance-days{display:flex!important;align-items:end!important}
.compliance-doc-form .exp-badge{min-width:0!important;width:100%!important;min-height:32px!important;display:flex!important;align-items:center!important;justify-content:center!important;padding:4px 6px!important;font-size:11px!important;white-space:nowrap!important}
.compliance-note-input{margin:0!important}
.compliance-file-actions{grid-column:auto!important;display:flex!important;gap:4px!important;flex-wrap:nowrap!important;padding:0!important;align-items:end!important}
.compliance-open-file,.compliance-delete-file,.compliance-replace-file{min-height:32px!important;height:32px!important;padding:5px 7px!important;font-size:10px!important;line-height:1!important;flex:1 1 0!important;white-space:nowrap!important}
.compliance-no-file{font-size:10px!important;white-space:nowrap!important}

.compliance-total-summary{gap:6px!important;margin:8px 0 10px!important}
.compliance-total-card{padding:6px 8px!important;min-height:42px!important}
.compliance-total-card span{font-size:10px!important}.compliance-total-card b{font-size:17px!important}
.count-pill{font-size:10px!important;padding:4px 6px!important}

@media(max-width:1450px){
  .compliance-entity-summary{grid-template-columns:minmax(140px,1fr) auto!important}
  .compliance-view-docs{grid-column:2!important;grid-row:1!important}
  .compliance-entity-counts{grid-column:1/-1!important;grid-row:2!important;grid-template-columns:repeat(4,minmax(75px,1fr))!important}
  .compliance-doc-row{grid-template-columns:95px minmax(0,1fr)!important}
  .compliance-doc-form{grid-template-columns:minmax(140px,1.15fr) 120px 112px 100px minmax(125px,1fr)!important}
  .compliance-file-actions{grid-column:1/-1!important;justify-content:flex-start!important}
  .compliance-open-file,.compliance-delete-file,.compliance-replace-file{flex:0 0 auto!important;width:auto!important}
}

@media(max-width:1050px){
  .compliance-doc-row{grid-template-columns:1fr!important;padding:7px!important}
  .compliance-doc-title{padding-bottom:1px!important}
  .compliance-doc-form{grid-template-columns:minmax(140px,1.2fr) 118px 108px 95px!important}
  .compliance-note-input{grid-column:1/3!important}
  .compliance-file-actions{grid-column:3/5!important;justify-content:flex-end!important}
  .compliance-open-file,.compliance-delete-file,.compliance-replace-file{font-size:9px!important;padding:5px 6px!important}
}

@media(max-width:700px){
  .compliance-total-summary{grid-template-columns:repeat(2,1fr)!important}
  .compliance-total-all{grid-column:1/-1!important}
  .compliance-summary{align-items:center!important;gap:5px!important}
  .compliance-section-counts{display:none!important}
  .compliance-collapsible-body{padding:5px!important}
  .compliance-addtype{display:grid!important;grid-template-columns:1fr!important;width:100%!important}
  .compliance-entity-summary{grid-template-columns:1fr auto!important;padding:7px!important}
  .compliance-entity-counts{grid-column:1/-1!important;grid-template-columns:repeat(2,1fr)!important;gap:4px!important}
  .entity-count{min-height:34px!important}.entity-count b{font-size:14px!important}.entity-count small{font-size:8px!important}
  .compliance-view-docs{grid-column:2!important;grid-row:1!important;min-width:82px!important;font-size:10px!important;padding:6px!important;width:auto!important}
  .compliance-doc-row{padding:7px!important;border-left-width:4px!important}
  .compliance-doc-form{grid-template-columns:1fr 1fr!important;gap:5px!important}
  .compliance-upload-label{grid-column:1/-1!important}
  .compliance-file-input{width:100%!important}
  .compliance-selected-file{display:block!important;margin-top:4px!important;padding:5px 7px!important;font-size:10px!important;white-space:nowrap!important}
  .compliance-upload-btn,.compliance-days{width:100%!important}
  .compliance-note-input{grid-column:1/-1!important}
  .compliance-file-actions{grid-column:1/-1!important;display:grid!important;grid-template-columns:1fr 1fr 1fr!important;gap:4px!important}
  .compliance-open-file,.compliance-delete-file,.compliance-replace-file{width:100%!important;min-width:0!important;font-size:9px!important;padding:4px!important}
  .compliance-no-file{grid-column:1/-1!important;text-align:left!important}
}

@media(max-width:430px){
  .compliance-doc-form{grid-template-columns:1fr!important}
  .compliance-upload-label,.compliance-note-input,.compliance-file-actions{grid-column:auto!important}
  .compliance-file-actions{grid-template-columns:1fr!important}
  .compliance-open-file,.compliance-delete-file,.compliance-replace-file{font-size:10px!important}
}

/* V1.96: multi-company driver notification preparation */
.notification-pagehead{align-items:center}.preparation-badge{display:inline-flex;align-items:center;background:#fff1b8;color:#644b00;border:1px solid #d9ba43;border-radius:999px;padding:8px 13px;font-weight:900;white-space:nowrap}
.preparation-banner{display:flex;flex-direction:column;gap:4px;background:#fff8db;border:2px solid #e1c34e;border-radius:10px;padding:12px 14px;margin:10px 0 14px;color:#574300}.preparation-banner b{font-size:15px}.preparation-banner span{font-size:13px}
.notification-stats{display:grid;grid-template-columns:repeat(5,minmax(110px,1fr));gap:8px;margin:12px 0}.notification-stats>div{display:flex;flex-direction:column;align-items:center;background:#fff;border:1px solid #cad6e2;border-radius:10px;padding:9px}.notification-stats b{font-size:22px;color:#173d73}.notification-stats span{font-size:11px;font-weight:800;color:#5b6977;text-transform:uppercase}
.notification-card,.notification-settings{background:#fff;border:1px solid #cbd7e2;border-radius:11px;margin:12px 0;padding:13px}.notification-card h2{font-size:18px;margin:0 0 10px}.notification-settings>summary{font-size:17px;font-weight:900;cursor:pointer;padding:2px}
.escalation-flow{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}.escalation-flow>div{position:relative;display:grid;grid-template-columns:29px 1fr;column-gap:8px;align-items:center;background:#edf4fb;border:1px solid #c6d9ec;border-radius:9px;padding:9px}.escalation-flow span{grid-row:1/3;width:29px;height:29px;display:flex;align-items:center;justify-content:center;border-radius:50%;background:#1769aa;color:#fff;font-weight:900}.escalation-flow b{font-size:13px}.escalation-flow small{font-size:11px;line-height:1.25;color:#566574}
.notification-settings-grid{margin-top:12px}.driver-notification-title,.notification-template{grid-column:1/-1!important;background:#edf4fb;border:1px solid #c5d9ec;border-radius:8px;padding:10px!important}.driver-notification-title{display:flex;flex-direction:column;gap:3px}.driver-notification-title small{font-weight:500;color:#586878}.notification-template textarea{width:100%;box-sizing:border-box;margin-top:5px;padding:8px;border:1px solid #aebdcc;border-radius:7px;font:inherit}.checklabel{display:flex!important;flex-direction:row!important;align-items:center!important;gap:8px;padding:10px!important;background:#f5f7f9;border:1px solid #d2dbe3;border-radius:7px;min-height:42px;box-sizing:border-box}.checklabel input{width:auto!important;margin:0!important}
.notification-table td small{display:block;color:#687684;font-size:10px;margin-top:3px}.readiness,.channel-badge{display:inline-block;border-radius:999px;padding:4px 7px;font-size:11px;font-weight:900;white-space:nowrap}.readiness.ready{background:#dff4e4;color:#176b2c;border:1px solid #95d3a3}.readiness.pending{background:#fff2c9;color:#6c5100;border:1px solid #dfc65b}.channel-badge{background:#e7eef8;color:#173d73;border:1px solid #b9cbe1}.channel-sms{background:#e8f6ea;color:#17662b;border-color:#9fd2aa}.channel-voice-call{background:#f1eafd;color:#613d91;border-color:#c8b2e8}.message-preview{min-width:260px;max-width:430px;font-size:12px;line-height:1.3}
.notification-load-link{color:#145b9e;font-weight:900;text-decoration:underline;text-underline-offset:2px}.notification-load-link:hover{color:#0b3f73}.notification-load-link:focus{outline:2px solid #1769aa;outline-offset:2px;border-radius:2px}
.notification-return-note{display:block;margin-top:5px;color:#52677c;font-weight:700;font-size:11px;white-space:normal}
.notification-plan-help{margin:0 0 10px}.notification-summary-table{min-width:850px}.notification-preview-button{display:block;width:100%;min-width:270px;max-width:480px;padding:8px 10px;background:#f4f8fc;color:#1e344b;border:1px solid #b9c9da;border-radius:7px;text-align:left;font-weight:600;line-height:1.3;cursor:pointer}.notification-preview-button:hover{background:#e7f1fb;border-color:#6e9dcc}.notification-preview-button:focus{outline:2px solid #1769aa;outline-offset:1px}.notification-preview-button span{display:block;white-space:normal}.notification-preview-button small{display:block;margin-top:6px!important;color:#145b9e!important;font-weight:900;font-size:11px!important}.notification-plan-modal{display:none;position:fixed;inset:0;z-index:10000;background:rgba(15,28,45,.48);align-items:center;justify-content:center;padding:18px}.notification-plan-box{position:relative;width:min(900px,96vw);max-height:90vh;overflow:auto;background:#fff;border-radius:12px;padding:18px;box-shadow:0 18px 55px rgba(0,0,0,.3)}.notification-plan-box h2{margin:0 40px 4px 0}.notification-plan-close{position:absolute;right:10px;top:7px;background:transparent;color:#31465b;padding:3px 10px;font-size:29px;line-height:1;cursor:pointer}.notification-plan-list{display:grid;gap:10px;margin-top:13px}.notification-plan-item{border:1px solid #cfdae6;border-left:5px solid #1d5da8;border-radius:8px;padding:11px;background:#f8fafc}.notification-plan-item p{margin:9px 0 2px;white-space:normal;overflow-wrap:anywhere}.notification-plan-top{display:flex;align-items:center;gap:9px;flex-wrap:wrap}.notification-plan-item>small{display:block;color:#667789;margin-top:4px}.notification-plan-reason{color:#8a5b00!important;font-weight:800}.modal-open{overflow:hidden}
@media(max-width:600px){.notification-plan-modal{padding:7px}.notification-plan-box{width:98vw;padding:14px;max-height:95vh}.notification-plan-top{align-items:flex-start}.notification-preview-button{min-width:240px}}

/* V2.04: dispatcher-side driver chat foundation */
.chat-pagehead{align-items:center}.chat-preparation-banner{margin-bottom:14px}.chat-start-panel{padding:0;overflow:visible}.chat-start-panel>summary{padding:12px 14px}.chat-start-form{display:grid;grid-template-columns:minmax(180px,.8fr) minmax(280px,1.4fr) auto;gap:10px;align-items:end;padding:0 14px 14px}.chat-start-form label{min-width:0}.chat-start-form button{height:39px;white-space:nowrap}.chat-layout{display:grid;grid-template-columns:minmax(235px,310px) minmax(0,1fr);gap:14px;min-height:590px}.chat-thread-panel,.chat-window{background:#fff;border:1px solid #d2dbe5;border-radius:10px;overflow:hidden}.chat-panel-title{display:flex;justify-content:space-between;align-items:center;padding:13px 14px;background:#edf3f9;border-bottom:1px solid #d2dbe5}.chat-panel-title span{background:#1d5da8;color:#fff;border-radius:999px;padding:3px 8px;font-size:11px;font-weight:900}.chat-thread-list{max-height:650px;overflow:auto}.chat-thread-link{display:block;padding:11px 12px;border-bottom:1px solid #e1e7ee;text-decoration:none;color:#20364d}.chat-thread-link:hover{background:#f2f7fc}.chat-thread-link.active{background:#e3f0fc;border-left:5px solid #1d5da8;padding-left:7px}.chat-thread-link>div{display:flex;align-items:center;justify-content:space-between;gap:8px}.chat-thread-link>div b{white-space:normal}.chat-thread-link em{font-style:normal;background:#c92525;color:#fff;border-radius:999px;padding:2px 7px;font-size:10px}.chat-thread-link>span{display:block;color:#145b9e;font-weight:800;font-size:12px;margin-top:3px}.chat-thread-link>small{display:block;color:#617183;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:6px}.chat-thread-link>i{display:block;color:#7a8794;font-size:10px;font-style:normal;margin-top:4px}.chat-empty-list{padding:20px 14px;color:#687789;line-height:1.4}.chat-window{display:flex;flex-direction:column;min-width:0}.chat-window-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:13px 16px;background:#edf3f9;border-bottom:1px solid #d2dbe5}.chat-window-head h2{margin:0 0 3px}.chat-window-head>div>span{color:#145b9e;font-weight:800}.chat-ready-badge{background:#e5f5e9;color:#176b2c;border:1px solid #9dd1a9;border-radius:999px;padding:5px 9px;font-weight:900;font-size:11px;white-space:nowrap}.chat-message-list{flex:1;min-height:300px;max-height:470px;overflow:auto;padding:16px;background:#f5f8fb}.chat-message-row{display:flex;margin-bottom:10px}.office-message-row{justify-content:flex-end}.driver-message-row{justify-content:flex-start}.chat-bubble{width:min(680px,82%);border-radius:11px;padding:10px 12px;box-shadow:0 1px 2px rgba(0,0,0,.07)}.office-message{background:#dceeff;border:1px solid #abcce9;border-bottom-right-radius:3px}.driver-message{background:#fff;border:1px solid #cfd9e3;border-bottom-left-radius:3px}.chat-message-meta{display:flex;justify-content:space-between;gap:12px;color:#3b536b;font-size:11px}.chat-message-meta span{white-space:nowrap}.chat-bubble p{margin:7px 0;white-space:pre-wrap;overflow-wrap:anywhere}.chat-message-status{display:flex;justify-content:flex-end;gap:7px;flex-wrap:wrap;color:#587087;font-size:10px;font-weight:800}.chat-priority{border-radius:999px;padding:2px 6px}.priority-normal{background:#edf1f5;color:#526274}.priority-urgent{background:#ffe1df;color:#a51c16}.chat-empty-window,.chat-no-selection{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;color:#657487;gap:5px;min-height:350px;padding:30px}.chat-empty-window b,.chat-no-selection b{font-size:18px;color:#29445f}.chat-composer{display:grid;grid-template-columns:minmax(0,1fr) 130px auto;gap:9px;align-items:end;padding:13px;border-top:1px solid #d2dbe5;background:#fff}.chat-message-input{grid-row:span 2}.chat-message-input textarea{display:block;width:100%;min-height:98px;margin-top:5px;padding:9px;border:1px solid #abb9c8;border-radius:7px;font:inherit;resize:vertical}.chat-sms-option{grid-column:2/4;display:flex;align-items:center;gap:7px;background:#fff7dc;border:1px solid #ead274;border-radius:7px;padding:7px;font-size:11px}.chat-sms-option input{width:auto;margin:0}.chat-composer button{min-width:140px;height:39px}.chat-send-warning{grid-column:2/4;color:#7b5a00;font-weight:700}.chat-start-form select option[hidden]{display:none}
@media(max-width:950px){.chat-layout{grid-template-columns:230px minmax(0,1fr)}.chat-start-form{grid-template-columns:1fr 1fr}.chat-start-form button{grid-column:1/-1}.chat-composer{grid-template-columns:1fr 120px}.chat-message-input{grid-column:1/-1;grid-row:auto}.chat-sms-option,.chat-send-warning{grid-column:1/-1}.chat-composer button{grid-column:2}}
@media(max-width:700px){.chat-start-form{grid-template-columns:1fr}.chat-start-form button{grid-column:auto}.chat-layout{grid-template-columns:1fr;min-height:0}.chat-thread-list{max-height:250px}.chat-window{min-height:520px}.chat-window-head{align-items:flex-start}.chat-ready-badge{white-space:normal;text-align:center}.chat-message-list{max-height:430px}.chat-bubble{width:91%}.chat-composer{grid-template-columns:1fr}.chat-composer button,.chat-sms-option,.chat-send-warning{grid-column:1}.chat-message-meta{display:block}.chat-message-meta span{display:block;margin-top:2px}}
@media(max-width:900px){.notification-stats{grid-template-columns:repeat(3,1fr)}.escalation-flow{grid-template-columns:1fr 1fr}}
@media(max-width:600px){.notification-pagehead{align-items:flex-start}.notification-stats{grid-template-columns:1fr 1fr}.notification-stats>div:last-child{grid-column:1/-1}.escalation-flow{grid-template-columns:1fr}.notification-card,.notification-settings{padding:9px}.notification-table{min-width:900px}}

/* V2.00: Load-style duration popup with Hour, Minute and Done only */
.duration-field{min-width:0}.duration-field>label{display:block}.duration-display{position:relative;width:100%;height:40px;margin-top:5px;padding:8px 38px 8px 10px;background:#fff;color:#1f3449;border:1px solid #9eabb8;border-radius:6px;text-align:left;font-weight:700;cursor:pointer}.duration-display:hover{background:#f8fbff}.duration-display:focus{outline:2px solid #1769aa;outline-offset:1px}.duration-clock{position:absolute;right:10px;top:50%;transform:translateY(-50%);font-size:17px}.duration-popup{width:270px;top:64px}.duration-popup-parts{display:grid;grid-template-columns:minmax(72px,1fr) auto auto minmax(72px,1fr) auto;gap:6px;align-items:center;width:100%}.duration-popup-parts select{height:38px;min-width:0;width:100%;padding:5px 7px;margin:0}.duration-popup-parts>span{font-weight:800;color:#33485d}.duration-colon{font-size:18px}.duration-field>small{display:block;margin-top:5px}.notification-settings{overflow:visible}.notification-settings-grid{overflow:visible}
@media(max-width:700px){.duration-display,.duration-popup-parts select{font-size:16px!important}.duration-popup{width:min(270px,calc(100vw - 50px));top:64px}.duration-popup-parts{grid-template-columns:minmax(58px,1fr) auto auto minmax(58px,1fr) auto;gap:4px}}

/* V2.05: collapsible notification sections with remembered state */
.notification-collapse{padding:0!important;overflow:hidden}.notification-collapse>summary{list-style:none;display:flex;align-items:center;gap:10px;min-height:48px;padding:10px 14px;cursor:pointer;background:#fff;font-weight:900}.notification-collapse>summary::-webkit-details-marker{display:none}.notification-collapse>summary:before{content:'▶';color:#175b98;font-size:14px;flex:0 0 auto}.notification-collapse[open]>summary:before{content:'▼'}.notification-collapse>summary:hover{background:#f2f7fc}.notification-collapse-summary>span{font-size:18px}.notification-collapse-summary>small{margin-left:auto;background:#e7f0fa;color:#174f86;border:1px solid #b8cee4;border-radius:999px;padding:4px 9px;font-size:11px;white-space:nowrap}.notification-collapse[open]>.notification-collapse-summary{border-bottom:1px solid #d8e1ea}.notification-collapse-body{padding:12px 13px}.notification-collapse-body .notification-plan-help{margin-top:0}
@media(max-width:600px){.notification-collapse>summary{padding:9px 10px}.notification-collapse-summary>span{font-size:16px}.notification-collapse-body{padding:8px}}
/* V2.06 accounting foundation */
.accounting-head{align-items:flex-start}.accounting-nav{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}.btnlink.secondary{background:#eef3f8;color:#173d73;border:1px solid #b9c7d8}.btnlink.small{padding:5px 8px;font-size:12px}.accounting-summary{margin:12px 0 16px}.accounting-summary>a{cursor:pointer;text-decoration:none}.accounting-section{background:#fff;border:1px solid #ccd7e4;border-radius:9px;margin:12px 0;overflow:hidden}.accounting-section>summary{list-style:none;cursor:pointer;font-size:17px;font-weight:800;padding:13px 16px;background:#f4f7fb;color:#172b4d}.accounting-section>summary::-webkit-details-marker{display:none}.accounting-section>summary:before{content:'▶';font-size:12px;margin-right:9px;color:#1769c2}.accounting-section[open]>summary:before{content:'▼'}.accounting-section>form,.accounting-section>.tablewrap,.accounting-section>p{margin:14px}.section-note{margin-bottom:8px!important}.summary-meta{float:right;font-size:12px;font-weight:500;color:#657087}.legacy-section>summary{color:#66521c}.status-pill{display:inline-block;padding:4px 8px;border-radius:999px;font-size:11px;font-weight:800;background:#e8eef5;color:#29415f;white-space:nowrap}.status-open,.status-partially-paid{background:#fff0bd;color:#6f5100}.status-paid,.status-posted{background:#d9f4df;color:#17662a}.status-voided{background:#eceff3;color:#596574}.overdue-row td{background:#fff4f3}.overdue-text{display:block;color:#b42318;font-weight:800;margin-top:3px}.load-financial-grid{display:grid;grid-template-columns:1.4fr 1fr;gap:12px}.load-financial-grid>.card{margin:0}.detail-list{display:grid;grid-template-columns:145px 1fr;gap:7px 12px;margin:0}.detail-list dt{font-weight:800;color:#45566d}.detail-list dd{margin:0}.readiness-list{display:flex;flex-direction:column;gap:8px}.readiness-list>*{display:flex;justify-content:space-between;gap:12px;padding:9px 10px;border:1px solid #cbd5e1;border-radius:6px;text-decoration:none;color:#172033}.readiness-ready{background:#eaf8ed!important;border-color:#9bd4a7!important}.readiness-missing{background:#fff0ef!important;border-color:#e9aaa5!important}.invoice-banner{display:grid;grid-template-columns:1.5fr repeat(4,1fr);gap:1px;background:#ccd7e4;border:1px solid #ccd7e4;border-radius:9px;overflow:hidden;margin:14px 0}.invoice-banner>div{display:flex;flex-direction:column;gap:5px;background:#fff;padding:14px}.invoice-banner small{color:#657087;font-weight:700}.invoice-banner b{font-size:19px}.invoice-banner h2{margin:0}.invoice-actions{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:12px}.payment-total{display:flex;flex-direction:column;justify-content:center;padding:8px 10px;background:#eef6ff;border:1px solid #bcd4ee;border-radius:6px}.payment-total b{font-size:20px}.payment-total small{color:#526176}.checkline{display:flex!important;flex-direction:row!important;align-items:center!important;gap:8px}.checkline input{width:auto!important;margin:0!important}.transaction-meta{line-height:1.8}.transaction-meta p{margin:4px 0 0}.factor-card>summary{background:#fff}.wide{grid-column:span 2}.invoice-list small{display:block;color:#657087;margin-top:3px}
@media(max-width:1000px){.load-financial-grid{grid-template-columns:1fr}.invoice-banner{grid-template-columns:1fr 1fr}.invoice-banner>div:first-child{grid-column:1/-1}.wide{grid-column:auto}}
@media(max-width:650px){.accounting-head{display:block}.accounting-nav{justify-content:flex-start;margin-top:10px}.invoice-banner{grid-template-columns:1fr}.invoice-banner>div:first-child{grid-column:auto}.detail-list{grid-template-columns:1fr}.detail-list dd{margin-bottom:7px}.summary-meta{float:none;display:block;margin:5px 0 0 22px}}

/* V2.07 driver settlements and payroll stubs */
.driver-payment-title{background:#eef8ef!important;border-color:#afd8b6!important}.payment-center-btn{display:inline-block;margin-bottom:4px}.driver-clean-table td>small{display:block;color:#687684;font-size:10px}.driver-pay-summary{margin-bottom:14px}.payment-warning{background:#fff3d8}.settlement-period-grid{display:grid;grid-template-columns:repeat(4,minmax(145px,1fr)) minmax(145px,.8fr) auto;gap:8px;align-items:end;margin:14px}.settlement-period-grid label{min-width:0}.selected-total{min-height:39px;display:flex;flex-direction:column;justify-content:center;padding:5px 9px;background:#eaf4ff;border:1px solid #b9d5ef;border-radius:6px}.selected-total b{font-size:17px}.settlement-load-picker{min-width:1300px}.settlement-load-picker th:first-child,.settlement-load-picker td:first-child{width:32px;text-align:center!important}.settlement-load-picker input[type=checkbox]{width:18px;height:18px}.settlement-load-picker input[type=number]{width:92px;min-width:82px;margin:0;padding:6px}.settlement-load-picker .route-cell{max-width:270px}.selected-source-load td{background:#ecf6ff}.settlement-card>summary{display:grid;grid-template-columns:minmax(110px,1fr) minmax(165px,1.4fr) minmax(80px,.7fr) minmax(90px,.7fr) auto;gap:10px;align-items:center}.settlement-card>summary:before{display:none}.settlement-card>summary>span:first-child:before{content:'▶';font-size:11px;color:#1769c2;margin-right:7px}.settlement-card[open]>summary>span:first-child:before{content:'▼'}.settlement-card>summary>b{text-align:right}.settlement-actions{display:flex;gap:8px;flex-wrap:wrap;margin:13px}.settlement-bottom{display:grid;grid-template-columns:1.6fr minmax(240px,.7fr);gap:16px;margin:14px}.adjustment-line{display:flex;justify-content:space-between;align-items:center;gap:10px;border-bottom:1px solid #e2e7ed;padding:7px 0}.adjustment-line form{margin:0}.adjustment-line .small{padding:4px 7px;font-size:10px}.adjustment-form{display:grid;grid-template-columns:repeat(3,minmax(120px,1fr));gap:8px;align-items:end;margin-top:12px;padding:11px;background:#f5f8fb;border:1px solid #d4dfe9;border-radius:7px}.settlement-totals{border:1px solid #ccd7e4;border-radius:8px;overflow:hidden}.settlement-totals>div{display:flex;justify-content:space-between;gap:12px;padding:8px 10px;border-bottom:1px solid #e1e6ec}.settlement-totals>div:last-child{border-bottom:0}.settlement-totals .net{background:#e5f5e9;font-size:16px}.settlement-post-form{display:flex;justify-content:flex-end;margin:14px}.settlement-pay-form{grid-template-columns:repeat(4,minmax(140px,1fr)) auto;background:#edf7ee;padding:12px;border-top:1px solid #badbc0}.payroll-safety{background:#eaf4ff;border-color:#9fc5e8;color:#244766}.payroll-form{grid-template-columns:repeat(auto-fit,minmax(175px,1fr))!important}.payroll-form .payment-total{min-height:39px}.payroll-form button{align-self:end}.route-cell{white-space:normal;min-width:180px}
@media(max-width:1200px){.settlement-period-grid{grid-template-columns:repeat(3,1fr)}.settlement-bottom{grid-template-columns:1fr}.adjustment-form{grid-template-columns:1fr 1fr}.settlement-pay-form{grid-template-columns:1fr 1fr}}
@media(max-width:700px){.settlement-period-grid{grid-template-columns:1fr}.settlement-card>summary{grid-template-columns:1fr auto}.settlement-card>summary>span:nth-child(2),.settlement-card>summary>span:nth-child(3){grid-column:1/-1}.settlement-card>summary>b{text-align:left}.adjustment-form,.settlement-pay-form{grid-template-columns:1fr}.settlement-bottom{margin:9px}.settlement-actions{margin:9px}}

/* V2.07 menu refinement: Driver Chat is a submenu under Drivers */
nav a.driver-submenu{padding-left:30px;font-size:.92em;font-weight:600;}
@media(max-width:700px){nav a.driver-submenu{padding-left:18px;}}

.chat-suggestions{display:flex;flex-wrap:wrap;gap:6px;margin-top:7px;max-height:95px;overflow:auto}.chat-suggestion{height:auto!important;min-width:0!important;padding:5px 9px!important;border-radius:999px!important;border:1px solid #b8c8d8!important;background:#f7fbff!important;color:#244764!important;font-size:11px!important;font-weight:800!important;line-height:1.2!important;cursor:pointer}.chat-suggestion:hover{background:#e7f2fc!important}.chat-suggestion.word{background:#edf7ed!important;border-color:#b8d9b8!important;color:#276027!important}.chat-suggestion.phrase{white-space:normal;text-align:left}


/* =========================================================
   V2.13 UNIVERSAL RESPONSIVE LAYOUT
   Permanent site-wide rule: desktop, laptop, tablet & phone.
   ========================================================= */
html{
  width:100%;
  max-width:100%;
  overflow-x:hidden;
  -webkit-text-size-adjust:100%;
}
body{
  width:100%;
  max-width:100%;
  overflow-x:hidden;
}
header,
.shell,
main,
.pagehead,
details,
.card,
.editcard,
.accounting-section,
.driver-compliance-panel,
.entity-compliance-panel,
.notification-card,
.notification-settings,
.chat-layout,
.chat-window{
  max-width:100%;
}
main{
  width:100%;
  min-width:0;
  overflow-x:hidden;
}
img,video,canvas,svg,iframe{
  max-width:100%;
  height:auto;
}
form,
fieldset,
label,
input,
select,
textarea,
button{
  min-width:0;
  max-width:100%;
}
textarea{
  width:100%;
  resize:vertical;
}
input[type="checkbox"],
input[type="radio"]{
  width:auto;
}
.cards,
.pagehead,
.actions,
.recordactions,
.invoice-actions,
.accounting-nav,
.expiration-legend,
.compliance-cards{
  max-width:100%;
}
.grid,
.filterbar,
.quickgrid,
.entity-summary,
.driver-summary-cards,
.load-financial-grid,
.invoice-banner,
.settlement-period-grid,
.adjustment-form,
.settlement-bottom,
.settlement-pay-form,
.payroll-form,
.chat-start-form,
.chat-composer{
  max-width:100%;
}
.tablewrap,
.responsive-tablewrap{
  display:block;
  width:100%;
  max-width:100%;
  overflow-x:auto;
  overflow-y:visible;
  -webkit-overflow-scrolling:touch;
  overscroll-behavior-inline:contain;
}
.tablewrap table,
.responsive-tablewrap table{
  max-width:none;
}
pre,code{
  max-width:100%;
  overflow-wrap:anywhere;
}
pre{
  overflow-x:auto;
}

/* Standard laptop screens */
@media(max-width:1366px){
  header{padding:11px 16px;font-size:17px;gap:10px}
  nav{width:190px;min-width:190px;padding:12px 8px}
  nav a{padding:9px 9px;font-size:13px}
  main{padding:16px}
  th,td{padding:7px;font-size:12px}
  h1{font-size:clamp(24px,2.25vw,32px)}
  h2{font-size:clamp(18px,1.8vw,25px)}
  .cards{gap:10px}
  .cards a{padding:13px;min-width:125px}
  .cards b{font-size:24px}
  .grid{gap:9px}
  details{padding:10px;margin-bottom:14px}
  .chat-layout{max-width:100%}
  .chat-thread-panel{min-width:0}
  .chat-window{min-width:0}
}

/* Small laptops and tablets: navigation moves above content */
@media(max-width:1024px){
  .shell{display:block;min-height:0}
  nav{
    width:100%;
    min-width:0;
    max-width:100%;
    flex-direction:row;
    flex-wrap:wrap;
    gap:3px 5px;
    padding:7px 9px;
    border-right:0;
    border-bottom:1px solid #d9dee7;
    overflow:visible;
  }
  nav a{
    flex:0 1 auto;
    white-space:normal;
    padding:7px 9px;
    font-size:12px;
  }
  nav a.driver-submenu{padding-left:14px}
  main{width:100%;padding:13px}
  header{flex-wrap:wrap}
  .pagehead{width:100%}
  .filterbar{grid-template-columns:repeat(2,minmax(0,1fr))}
  .grid{grid-template-columns:repeat(auto-fit,minmax(min(180px,100%),1fr))}
  .settlement-load-picker,
  .driver-compliance-table,
  .notification-table,
  .accountingtable{
    min-width:max-content;
  }
}

/* Phones and narrow tablets */
@media(max-width:700px){
  header{
    padding:9px 10px;
    font-size:15px;
    align-items:flex-start;
  }
  header>span{
    width:100%;
    font-size:11px;
    margin-top:3px;
  }
  nav{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    width:100%;
    gap:4px;
    overflow:visible;
  }
  nav a{
    width:100%;
    white-space:normal;
    overflow-wrap:anywhere;
    padding:7px 8px;
  }
  nav a.driver-submenu{padding-left:16px}
  main{padding:9px}
  .backbar{margin-bottom:9px}
  .backbtn,.btnlink,button{
    max-width:100%;
  }
  .pagehead{
    display:flex;
    flex-direction:column;
    align-items:stretch;
    gap:8px;
  }
  .pagehead .btnlink{
    width:100%;
    text-align:center;
  }
  .cards{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    width:100%;
  }
  .cards a{
    min-width:0;
    width:100%;
    padding:11px;
  }
  .grid,
  .filterbar,
  .quickgrid,
  .entity-summary,
  .load-financial-grid,
  .invoice-banner,
  .settlement-period-grid,
  .adjustment-form,
  .settlement-bottom,
  .settlement-pay-form,
  .payroll-form,
  .chat-start-form,
  .chat-composer{
    grid-template-columns:1fr!important;
    width:100%;
  }
  .wide{grid-column:auto!important}
  .actions,
  .recordactions,
  .invoice-actions,
  .accounting-nav{
    flex-wrap:wrap;
    width:100%;
  }
  .actions>*,
  .invoice-actions>*{
    max-width:100%;
  }
  .chat-layout{
    grid-template-columns:1fr!important;
    width:100%;
    min-height:0;
  }
  .chat-thread-panel,
  .chat-window{
    width:100%;
    min-width:0;
  }
  .chat-thread-list{max-height:220px}
  .chat-message-list{max-height:360px}
  .chat-bubble{width:min(94%,560px)}
  .chat-suggestions{
    width:100%;
    max-width:100%;
    overflow-x:hidden;
  }
  .chat-suggestion{
    max-width:100%;
    overflow-wrap:anywhere;
  }
  .detail-list{grid-template-columns:1fr!important}
  .detail-list dd{min-width:0;overflow-wrap:anywhere}
}

/* Very small phones */
@media(max-width:430px){
  nav{grid-template-columns:1fr}
  main{padding:7px}
  .cards{grid-template-columns:1fr}
  input,select,textarea{font-size:16px} /* prevents mobile browser zoom */
  th,td{padding:6px;font-size:11px}
  .chat-bubble{width:96%}
  .preparation-banner,
  .flash,
  details,
  .editcard,
  .card{
    padding-left:8px;
    padding-right:8px;
  }
}

/* Print remains clean and full width */
@media print{
  nav,.backbar{display:none!important}
  .shell{display:block!important}
  main{width:100%!important;max-width:none!important;padding:0!important}
  .tablewrap,.responsive-tablewrap{overflow:visible!important}
}


/* =========================================================
   V2.14 UNIVERSAL COMPACT FIT
   Fits normal browser windows without oversized/cranky layout.
   ========================================================= */
:root{
  --site-font: clamp(12px, .78vw, 14px);
  --site-small: clamp(10px, .68vw, 12px);
  --site-gap: clamp(6px, .55vw, 10px);
  --site-pad: clamp(8px, .7vw, 12px);
}
body{
  font-size:var(--site-font);
  line-height:1.3;
}
header{
  min-height:0!important;
  padding:8px 12px!important;
  font-size:clamp(14px,1vw,17px)!important;
}
.shell{
  min-height:calc(100vh - 42px)!important;
}
nav{
  width:190px!important;
  min-width:190px!important;
  padding:9px 7px!important;
  gap:2px!important;
}
nav a{
  padding:7px 8px!important;
  font-size:clamp(11px,.75vw,13px)!important;
  line-height:1.15!important;
}
nav a.driver-submenu{
  padding-left:20px!important;
}
main{
  padding:12px!important;
}
h1{
  font-size:clamp(22px,1.75vw,30px)!important;
  line-height:1.1!important;
  margin:0 0 3px!important;
}
h2{
  font-size:clamp(17px,1.35vw,23px)!important;
  line-height:1.15!important;
}
p{
  margin-top:4px;
  margin-bottom:7px;
}
.pagehead{
  gap:8px!important;
  margin-bottom:6px!important;
}
.backbar{
  margin-bottom:8px!important;
}
.backbtn{
  padding:6px 11px!important;
  font-size:12px!important;
}
.preparation-badge{
  padding:5px 10px!important;
  font-size:11px!important;
}
.preparation-banner{
  padding:8px 10px!important;
  margin:6px 0 8px!important;
  gap:2px!important;
}
.preparation-banner b{
  font-size:13px!important;
}
.preparation-banner span{
  font-size:11px!important;
}
details{
  padding:8px!important;
  margin-bottom:9px!important;
}
summary{
  font-size:12px!important;
}
input,select,textarea{
  padding:6px 7px!important;
  margin-top:3px!important;
  font-size:12px!important;
}
button,.btnlink,.editlink{
  padding:7px 11px!important;
  font-size:12px!important;
}
.cards{
  gap:7px!important;
}
.cards a{
  padding:9px!important;
}
.cards b{
  font-size:21px!important;
}
.grid{
  gap:7px!important;
  padding:8px 0!important;
}
th,td{
  padding:5px 6px!important;
  font-size:11px!important;
}

/* Driver Chat: use the browser height instead of growing below the fold */
.chat-pagehead{
  min-height:0!important;
  margin-bottom:4px!important;
}
.chat-pagehead .muted{
  font-size:12px!important;
  margin:2px 0!important;
}
.chat-preparation-banner{
  margin-bottom:7px!important;
}
.chat-start-panel{
  margin-bottom:8px!important;
}
.chat-start-panel>summary{
  padding:7px 9px!important;
}
.chat-start-form{
  gap:7px!important;
  padding:0 9px 9px!important;
}
.chat-start-form button{
  height:31px!important;
}
.chat-layout{
  grid-template-columns:minmax(190px,240px) minmax(0,1fr)!important;
  gap:8px!important;
  min-height:0!important;
  height:calc(100vh - 285px)!important;
  max-height:calc(100vh - 285px)!important;
}
.chat-thread-panel,
.chat-window{
  min-height:0!important;
  height:100%!important;
}
.chat-window{
  display:flex!important;
  flex-direction:column!important;
}
.chat-panel-title{
  padding:8px 9px!important;
}
.chat-panel-title b{
  font-size:13px!important;
}
.chat-thread-list{
  max-height:none!important;
  height:calc(100% - 38px)!important;
  overflow:auto!important;
}
.chat-thread-link{
  padding:7px 8px!important;
}
.chat-thread-link.active{
  padding-left:5px!important;
}
.chat-thread-link>div b{
  font-size:12px!important;
}
.chat-thread-link>span{
  font-size:10px!important;
  margin-top:2px!important;
}
.chat-thread-link>small{
  font-size:10px!important;
  margin-top:3px!important;
}
.chat-thread-link>i{
  font-size:9px!important;
}
.chat-window-head{
  padding:8px 10px!important;
  flex:0 0 auto!important;
}
.chat-window-head h2{
  font-size:18px!important;
  margin:0 0 1px!important;
}
.chat-window-head>div>span{
  font-size:11px!important;
}
.chat-ready-badge{
  padding:4px 7px!important;
  font-size:9px!important;
}
.chat-message-list{
  flex:1 1 auto!important;
  min-height:90px!important;
  max-height:none!important;
  padding:8px!important;
  overflow:auto!important;
}
.chat-message-row{
  margin-bottom:6px!important;
}
.chat-bubble{
  width:min(620px,80%)!important;
  padding:7px 9px!important;
  font-size:11px!important;
}
.chat-message-meta{
  font-size:9px!important;
}
.chat-bubble p{
  margin:4px 0!important;
}
.chat-message-status{
  font-size:9px!important;
}
.chat-composer{
  flex:0 0 auto!important;
  grid-template-columns:minmax(0,1fr) 100px auto!important;
  gap:6px!important;
  padding:7px!important;
}
.chat-message-input textarea{
  min-height:56px!important;
  max-height:90px!important;
  padding:6px!important;
  font-size:12px!important;
}
.chat-suggestions{
  margin-top:4px!important;
  gap:3px!important;
}
.chat-suggestion{
  padding:3px 6px!important;
  font-size:9px!important;
  line-height:1.15!important;
}
.chat-sms-option{
  padding:5px!important;
  font-size:9px!important;
}
.chat-composer button{
  min-width:110px!important;
  height:31px!important;
  padding:5px 8px!important;
}
.chat-send-warning{
  font-size:9px!important;
}

/* Normal laptop widths: stay side-by-side and compact */
@media(max-width:1200px){
  nav{
    width:165px!important;
    min-width:165px!important;
  }
  main{
    padding:9px!important;
  }
  .chat-layout{
    grid-template-columns:185px minmax(0,1fr)!important;
    height:calc(100vh - 270px)!important;
    max-height:calc(100vh - 270px)!important;
  }
}

/* Tablet: move navigation above, but keep it compact */
@media(max-width:900px){
  .shell{
    display:block!important;
  }
  nav{
    width:100%!important;
    min-width:0!important;
    display:flex!important;
    flex-direction:row!important;
    flex-wrap:wrap!important;
    padding:5px!important;
    border-right:0!important;
    border-bottom:1px solid #d9dee7!important;
  }
  nav a{
    width:auto!important;
    flex:0 1 auto!important;
    padding:5px 7px!important;
  }
  nav a.driver-submenu{
    padding-left:10px!important;
  }
  .chat-layout{
    height:auto!important;
    max-height:none!important;
    min-height:480px!important;
  }
}

/* Phones: stack sections and never force horizontal page width */
@media(max-width:650px){
  nav{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
  nav a{
    width:100%!important;
  }
  .chat-layout{
    grid-template-columns:1fr!important;
    min-height:0!important;
  }
  .chat-thread-panel{
    height:auto!important;
    max-height:190px!important;
  }
  .chat-thread-list{
    height:auto!important;
    max-height:150px!important;
  }
  .chat-window{
    height:auto!important;
    min-height:460px!important;
  }
  .chat-message-list{
    min-height:180px!important;
    max-height:320px!important;
  }
  .chat-composer{
    grid-template-columns:1fr!important;
  }
  .chat-message-input,
  .chat-sms-option,
  .chat-send-warning,
  .chat-composer button{
    grid-column:1!important;
  }
  .chat-bubble{
    width:94%!important;
  }
}
@media(max-width:420px){
  nav{
    grid-template-columns:1fr!important;
  }
}


/* =========================================================
   V2.15 DRIVER CHAT FULL-SCREEN HEIGHT FIT
   Keep the complete composer visible; history scrolls internally.
   ========================================================= */
@media(min-width:901px){
  body{
    height:100vh;
    overflow:hidden;
  }
  .shell{
    height:calc(100vh - 42px)!important;
    min-height:0!important;
    overflow:hidden!important;
  }
  nav{
    height:100%!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
  }
  main{
    height:100%!important;
    min-height:0!important;
    overflow:hidden!important;
  }

  /* Driver Chat top area becomes deliberately shallow */
  .chat-pagehead{
    margin:0 0 3px!important;
  }
  .chat-pagehead h1{
    font-size:22px!important;
  }
  .chat-pagehead .muted{
    font-size:11px!important;
    line-height:1.15!important;
  }
  .chat-preparation-banner{
    padding:6px 9px!important;
    margin:4px 0 6px!important;
    min-height:0!important;
  }
  .chat-preparation-banner b{
    font-size:12px!important;
  }
  .chat-preparation-banner span{
    font-size:10px!important;
    line-height:1.15!important;
  }
  .chat-start-panel{
    margin:0 0 6px!important;
    padding:0!important;
  }
  .chat-start-panel>summary{
    padding:6px 8px!important;
  }

  /* Remaining viewport belongs to chat. */
  .chat-layout{
    height:calc(100vh - 245px)!important;
    max-height:calc(100vh - 245px)!important;
    min-height:360px!important;
    overflow:hidden!important;
  }
  .chat-thread-panel,
  .chat-window{
    height:100%!important;
    min-height:0!important;
    overflow:hidden!important;
  }
  .chat-thread-list{
    overflow-y:auto!important;
    min-height:0!important;
  }
  .chat-window{
    display:flex!important;
    flex-direction:column!important;
  }
  .chat-window-head{
    flex:0 0 auto!important;
    padding:6px 9px!important;
  }
  .chat-window-head h2{
    font-size:17px!important;
  }

  /* Only history sacrifices height and scrolls. */
  .chat-message-list{
    flex:1 1 0!important;
    min-height:60px!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    padding:6px 8px!important;
  }

  /* Composer always remains fully visible. */
  .chat-composer{
    flex:0 0 auto!important;
    min-height:0!important;
    max-height:none!important;
    overflow:visible!important;
    padding:6px 8px!important;
    grid-template-columns:minmax(0,1fr) 95px auto!important;
    gap:5px!important;
  }
  .chat-message-input textarea{
    min-height:48px!important;
    height:48px!important;
    max-height:48px!important;
  }
  .chat-suggestions{
    margin-top:3px!important;
    gap:2px!important;
  }
  .chat-suggestion{
    padding:2px 5px!important;
    font-size:8.5px!important;
  }
  .chat-sms-option{
    padding:4px!important;
  }
  .chat-composer button{
    height:28px!important;
    padding:4px 7px!important;
  }
}

/* Short laptop screens need an even tighter top section. */
@media(min-width:901px) and (max-height:800px){
  .backbar{
    margin-bottom:4px!important;
  }
  .backbtn{
    padding:4px 9px!important;
  }
  .chat-pagehead h1{
    font-size:20px!important;
  }
  .chat-preparation-banner{
    padding:4px 8px!important;
    margin:3px 0 4px!important;
  }
  .chat-start-panel{
    margin-bottom:4px!important;
  }
  .chat-start-panel>summary{
    padding:5px 7px!important;
  }
  .chat-layout{
    height:calc(100vh - 215px)!important;
    max-height:calc(100vh - 215px)!important;
    min-height:330px!important;
  }
  .chat-window-head{
    padding:5px 8px!important;
  }
  .chat-message-input textarea{
    min-height:44px!important;
    height:44px!important;
    max-height:44px!important;
  }
}


/* =========================================================
   V2.16 DRIVER CHAT LARGE POPUP
   Main page stays compact; selected conversation opens in modal.
   ========================================================= */
@media(min-width:701px){
  body{overflow:auto!important}
  .shell{height:auto!important;min-height:calc(100vh - 42px)!important;overflow:visible!important}
  main{height:auto!important;overflow:visible!important}
}
.chat-layout{
  display:block!important;
  height:auto!important;
  max-height:none!important;
  min-height:0!important;
}
.chat-thread-panel{
  width:100%!important;
  height:auto!important;
  max-height:none!important;
  overflow:visible!important;
  border-radius:10px!important;
}
.chat-thread-list{
  height:auto!important;
  max-height:260px!important;
  overflow-y:auto!important;
}
.chat-window{
  display:none!important;
}

/* Popup shell */
#driverChatModal{
  display:none;
  position:fixed;
  inset:0;
  z-index:10000;
  background:rgba(8,25,48,.58);
  padding:2vh 2vw;
  align-items:center;
  justify-content:center;
}
#driverChatModal.open{display:flex}
.driver-chat-modal-card{
  width:min(1500px,96vw);
  height:min(900px,94vh);
  max-width:96vw;
  max-height:94vh;
  background:#fff;
  border-radius:12px;
  box-shadow:0 18px 60px rgba(0,0,0,.28);
  overflow:hidden;
  display:flex;
  flex-direction:column;
}
.driver-chat-modal-header{
  flex:0 0 auto;
  min-height:48px;
  background:#0d2a50;
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:10px 14px;
}
.driver-chat-modal-title{
  font-size:clamp(16px,1.4vw,22px);
  font-weight:800;
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.driver-chat-modal-exit{
  flex:0 0 auto;
  border:0!important;
  background:#fff!important;
  color:#0d2a50!important;
  border-radius:7px!important;
  padding:7px 13px!important;
  font-weight:800!important;
  cursor:pointer;
}
.driver-chat-modal-body{
  flex:1 1 auto;
  min-height:0;
  overflow:hidden;
}
.driver-chat-modal-body .chat-window{
  display:flex!important;
  width:100%!important;
  height:100%!important;
  max-height:none!important;
  border:0!important;
  border-radius:0!important;
  flex-direction:column!important;
}
.driver-chat-modal-body .chat-window-head{
  flex:0 0 auto!important;
}
.driver-chat-modal-body .chat-message-list{
  flex:1 1 auto!important;
  min-height:120px!important;
  max-height:none!important;
  overflow-y:auto!important;
}
.driver-chat-modal-body .chat-composer{
  flex:0 0 auto!important;
  max-height:none!important;
  overflow:visible!important;
}

/* Button added to each driver/conversation row */
.open-driver-chat-popup{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  margin-top:6px;
  padding:5px 9px!important;
  border:1px solid #8bb9e9!important;
  border-radius:7px!important;
  background:#eef7ff!important;
  color:#07559e!important;
  font-size:11px!important;
  font-weight:800!important;
  cursor:pointer;
}

/* Compact main page: driver/conversation information only */
.chat-thread-link{
  position:relative;
}
@media(max-width:700px){
  #driverChatModal{padding:0}
  .driver-chat-modal-card{
    width:100vw;
    height:100vh;
    max-width:100vw;
    max-height:100vh;
    border-radius:0;
  }
  .driver-chat-modal-header{padding:8px 10px}
  .driver-chat-modal-body .chat-composer{
    grid-template-columns:1fr!important;
    overflow-y:auto!important;
  }
}


/* V2.17 ALL DRIVERS LIST */
.chat-all-drivers{
  width:100%;
  max-width:100%;
  margin:0 0 8px;
  border:1px solid #d7e1ec;
  border-radius:9px;
  background:#fff;
  overflow:hidden;
}
.chat-driver-list{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:6px;
  padding:7px;
  max-height:190px;
  overflow-y:auto;
}
.chat-driver-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  padding:7px 8px;
  border:1px solid #dbe5ef;
  border-radius:7px;
  background:#f8fbff;
}
.chat-driver-main{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:2px;
}
.chat-driver-main b{
  font-size:12px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.chat-driver-main span{
  font-size:10px;
  color:#667085;
}
.chat-driver-row .open-driver-chat-popup{
  margin:0!important;
  white-space:nowrap;
}
@media(max-width:700px){
  .chat-driver-list{grid-template-columns:1fr}
}


/* =========================================================
   V2.18 SEARCHABLE ALL DRIVERS DROPDOWN
   ========================================================= */
.chat-driver-picker-panel{
  width:100%;
  margin:0 0 8px!important;
  padding:0!important;
  border:1px solid #d7e1ec!important;
  border-radius:9px!important;
  background:#fff!important;
  overflow:visible!important;
}
.chat-driver-picker-form{
  display:grid;
  grid-template-columns:auto minmax(180px, .8fr) minmax(220px, 1fr) auto;
  align-items:center;
  gap:8px;
  padding:8px 10px;
}
.chat-all-drivers-label{
  white-space:nowrap;
  color:#142c4f;
  font-size:13px;
}
.chat-driver-search-wrap,
.chat-driver-select-wrap{
  min-width:0;
}
.chat-driver-search,
.chat-driver-select{
  width:100%!important;
  height:34px!important;
  margin:0!important;
  padding:6px 9px!important;
  font-size:12px!important;
}
.chat-driver-search{
  border:1px solid #9eb4ca!important;
  border-radius:6px!important;
}
.chat-driver-select{
  border:1px solid #9eb4ca!important;
  border-radius:6px!important;
  background:#fff!important;
}
.chat-driver-open-btn{
  height:34px!important;
  margin:0!important;
  white-space:nowrap!important;
  padding:6px 12px!important;
}
.chat-driver-no-match{
  padding:0 10px 7px;
  color:#a33;
  font-size:11px;
}
@media(max-width:900px){
  .chat-driver-picker-form{
    grid-template-columns:auto minmax(160px,1fr) minmax(190px,1fr) auto;
    gap:6px;
  }
}
@media(max-width:700px){
  .chat-driver-picker-form{
    grid-template-columns:1fr;
    align-items:stretch;
  }
  .chat-all-drivers-label{
    padding-bottom:1px;
  }
  .chat-driver-open-btn{
    width:100%!important;
  }
}


/* =========================================================
   V2.19 SINGLE ALL-DRIVERS DROPDOWN
   No separate search box; first item is blank.
   Typing letters while dropdown has focus jumps to a driver.
   ========================================================= */
.chat-driver-picker-form{
  display:grid!important;
  grid-template-columns:auto minmax(240px,420px) auto!important;
  align-items:center!important;
  gap:8px!important;
}
.chat-driver-select{
  width:100%!important;
  height:34px!important;
  margin:0!important;
}
@media(max-width:700px){
  .chat-driver-picker-form{
    grid-template-columns:1fr!important;
  }
}


/* =========================================================
   V2.20 FILTER-AS-YOU-TYPE DRIVER COMBOBOX
   ========================================================= */
.chat-driver-picker-form{
  display:flex!important;
  align-items:center!important;
  gap:5px!important;
  padding:7px 9px!important;
}
.chat-all-drivers-label{
  margin-right:1px!important;
  flex:0 0 auto!important;
}
.driver-combobox{
  position:relative;
  width:min(360px,38vw);
  min-width:230px;
  flex:0 1 360px;
}
.driver-combobox-control{
  display:flex;
  align-items:stretch;
  width:100%;
  height:34px;
}
.driver-combobox-input{
  flex:1 1 auto;
  min-width:0;
  height:34px!important;
  padding:6px 8px!important;
  border:1px solid #9eb4ca!important;
  border-right:0!important;
  border-radius:6px 0 0 6px!important;
  font-size:12px!important;
  margin:0!important;
  background:#fff!important;
}
.driver-combobox-arrow{
  width:34px!important;
  height:34px!important;
  margin:0!important;
  padding:0!important;
  border:1px solid #9eb4ca!important;
  border-radius:0 6px 6px 0!important;
  background:#f5f8fb!important;
  color:#17365d!important;
  font-size:11px!important;
  cursor:pointer;
}
.driver-combobox-menu{
  position:absolute;
  top:36px;
  left:0;
  right:0;
  z-index:12000;
  max-height:280px;
  overflow-y:auto;
  border:1px solid #9eb4ca;
  border-radius:6px;
  background:#fff;
  box-shadow:0 8px 20px rgba(0,0,0,.16);
}
.driver-combobox-option{
  padding:7px 9px;
  font-size:12px;
  line-height:1.25;
  cursor:pointer;
  border-bottom:1px solid #edf2f7;
}
.driver-combobox-option:hover,
.driver-combobox-option.keyboard-active{
  background:#eaf4ff;
}
.driver-combobox-option.blank-option{
  min-height:29px;
  background:#fff;
}
.driver-combobox-no-match{
  padding:8px 9px;
  font-size:11px;
  color:#8a2d2d;
}
.chat-driver-open-btn{
  flex:0 0 auto!important;
  margin-left:2px!important;
}
@media(max-width:700px){
  .chat-driver-picker-form{
    display:grid!important;
    grid-template-columns:auto 1fr!important;
  }
  .driver-combobox{
    width:100%!important;
    min-width:0!important;
  }
  .chat-driver-open-btn{
    grid-column:1 / -1;
    width:100%!important;
  }
}

/* V2.24 removed conversation sidebar */
.chat-layout{display:block!important;min-height:0!important}.chat-window{width:100%!important}


/* =========================================================
   V2.26 UNREVIEWED DRIVER MESSAGE ALERTS
   ========================================================= */
.unreviewed-driver-alert-panel{
  margin:8px 0 10px;
  border:1px solid #e9b400;
  border-radius:10px;
  background:linear-gradient(180deg,#fffdf2 0%,#fff8d7 100%);
  box-shadow:0 3px 10px rgba(196,145,0,.12);
  overflow:hidden;
}
.unreviewed-driver-alert-title{
  display:flex;
  align-items:center;
  gap:8px;
  padding:8px 10px;
  color:#5a4300;
  font-size:13px;
  border-bottom:1px solid #f0d46a;
  background:#fff6bf;
}
.unreviewed-pulse-dot{
  width:10px;
  height:10px;
  flex:0 0 10px;
  border-radius:50%;
  background:#ffc400;
  box-shadow:0 0 0 0 rgba(255,196,0,.7);
  animation:unreviewedPulse 1.15s infinite;
}
.unreviewed-total-badge{
  min-width:24px;
  height:22px;
  padding:0 7px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:#5a4300;
  color:#fff;
  font-size:11px;
  font-weight:800;
}
.unreviewed-driver-alert-list{
  display:flex;
  flex-direction:column;
}
.unreviewed-driver-alert-row{
  display:grid;
  grid-template-columns:minmax(160px,1fr) auto auto auto;
  align-items:center;
  gap:9px;
  padding:8px 10px;
  text-decoration:none!important;
  color:#25364d!important;
  border-bottom:1px solid #f3e29a;
  background:#fffef8;
  transition:transform .12s ease, background .12s ease, box-shadow .12s ease;
}
.unreviewed-driver-alert-row:last-child{border-bottom:0}
.unreviewed-driver-alert-row:hover{
  background:#fff5b8;
  box-shadow:inset 4px 0 0 #ffc400;
}
.unreviewed-driver-name{
  font-weight:800;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.unreviewed-load{
  font-size:11px;
  color:#6f7782;
  white-space:nowrap;
}
.unreviewed-flash-label{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:4px 9px;
  border-radius:999px;
  background:#ffd400;
  color:#3f3100;
  font-size:11px;
  font-weight:900;
  white-space:nowrap;
  animation:unreviewedFlash 1.05s infinite;
}
.unreviewed-count{
  min-width:25px;
  height:25px;
  padding:0 7px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:#ffbd00;
  color:#2f2700;
  font-size:11px;
  font-weight:900;
}
@keyframes unreviewedFlash{
  0%,100%{background:#ffd400;box-shadow:0 0 0 rgba(255,196,0,0)}
  50%{background:#fff29a;box-shadow:0 0 12px rgba(255,196,0,.85)}
}
@keyframes unreviewedPulse{
  0%{box-shadow:0 0 0 0 rgba(255,196,0,.65)}
  70%{box-shadow:0 0 0 8px rgba(255,196,0,0)}
  100%{box-shadow:0 0 0 0 rgba(255,196,0,0)}
}
@media(max-width:700px){
  .unreviewed-driver-alert-row{
    grid-template-columns:1fr auto;
  }
  .unreviewed-load{display:none}
  .unreviewed-flash-label{
    grid-column:1/2;
    justify-self:start;
  }
  .unreviewed-count{
    grid-column:2/3;
    grid-row:1/3;
  }
}
@media(prefers-reduced-motion:reduce){
  .unreviewed-pulse-dot,
  .unreviewed-flash-label{animation:none!important}
}

/* V2.27 Semi-automatic Gmail / Rate Confirmation Import */
.email-import-grid{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,.85fr);gap:14px;margin-bottom:14px}.compact-card{padding:14px}.compact-card h2{margin-top:0}.compact-form{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;align-items:end}.compact-form label{min-width:0}.compact-form input,.compact-form select{width:100%;box-sizing:border-box}.section-head,.page-title-row{display:flex;justify-content:space-between;gap:12px;align-items:center}.page-title-row h1{margin-bottom:2px}.small{font-size:.86rem}.email-cell{max-width:230px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.status-pill{display:inline-block;padding:3px 7px;border-radius:999px;font-size:.78rem;font-weight:700;white-space:nowrap}.status-pending-review{background:#fff3cd;color:#775b00}.status-approved{background:#dff3e4;color:#166534}.status-ignored{background:#eceff3;color:#4b5563}.review-layout{display:grid;grid-template-columns:minmax(0,2fr) minmax(260px,.85fr);gap:14px}.two-col{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.review-form input{width:100%;box-sizing:border-box}.action-row{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}.source-meta{display:grid;grid-template-columns:72px 1fr;gap:7px 10px;margin:0}.source-meta dt{font-weight:700}.source-meta dd{margin:0;word-break:break-word}.info-note,.warning-note{margin-top:12px;padding:10px 12px;border:1px solid #d7dee8;border-radius:7px;background:#f8fafc}.warning-note{background:#fff8e5}.danger-outline{border-color:#b42318!important;color:#b42318!important;background:#fff!important}.empty-state{text-align:center;padding:22px!important;color:#667085}
@media(max-width:900px){.email-import-grid,.review-layout{grid-template-columns:1fr}.compact-form{grid-template-columns:1fr 1fr}.compact-form .btn{width:100%}}
@media(max-width:600px){.compact-form,.two-col{grid-template-columns:1fr}.page-title-row,.section-head{align-items:flex-start;flex-direction:column}.review-layout{gap:9px}.compact-card{padding:10px}.action-row .btn{flex:1 1 100%}}

/* V2.28 Gmail date-range + complete load review */
.gmail-date-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}.quick-date-row{display:flex;gap:6px;flex-wrap:wrap;margin:2px 0 8px}.review-form .full-span{grid-column:1/-1}.review-form select{width:100%}@media(max-width:700px){.gmail-date-grid,.review-form .two-col{grid-template-columns:1fr}.review-form .full-span{grid-column:auto}.quick-date-row .btn{flex:1 1 auto}}

/* V2.31 duplicate Rate Confirmation protection */
.duplicate-warning-card{border:2px solid #d59b22;background:#fff9e8;margin-bottom:14px}
.duplicate-warning-title{font-size:18px;font-weight:800;color:#8a5700;margin-bottom:6px}
.duplicate-actions{display:flex;gap:8px;flex-wrap:wrap;margin:10px 0}
.comparison-table td:first-child{font-weight:700;white-space:nowrap}
@media(max-width:700px){.comparison-table td:first-child{white-space:normal}.duplicate-warning-title{font-size:16px}}

/* V2.31 duplicate Rate Confirmation protection */
.duplicate-warning-card{border:2px solid #d59b22;background:#fff9e8;margin-bottom:14px}
.duplicate-warning-title{font-size:18px;font-weight:800;color:#8a5700;margin-bottom:6px}
.duplicate-actions{display:flex;gap:8px;flex-wrap:wrap;margin:10px 0}
.comparison-table td:first-child{font-weight:700;white-space:nowrap}
@media(max-width:700px){.comparison-table td:first-child{white-space:normal}.duplicate-warning-title{font-size:16px}}


/* V2.36 collapsible Loads workflow menu — collapsed by default */
.nav-group{display:block;width:100%}
.nav-group-toggle{width:100%;border:0;background:transparent;color:inherit;font:inherit;text-align:left;padding:8px 10px;display:flex;align-items:center;justify-content:space-between;cursor:pointer;border-radius:5px}
.nav-group-toggle:hover{background:#e7f0fb}
.nav-chevron{font-size:12px;transition:transform .16s ease}
.nav-submenu{display:none;padding:2px 0 5px 10px}
.nav-group.open .nav-submenu{display:block}
.nav-group.open .nav-chevron{transform:rotate(90deg)}
.nav-submenu a{font-size:12px;padding:7px 8px 7px 12px;margin:1px 0;border-left:2px solid #c9d7e8}
.nav-submenu a:hover{border-left-color:#1f66b2}
@media(max-width:700px){.nav-submenu a{font-size:12px;padding-top:8px;padding-bottom:8px}}


/* V2.38 Load Center - workflow cards live in the main body */
.load-center-heading{display:flex;align-items:flex-start;gap:12px;margin:4px 0 16px}.load-center-heading h1{margin:0}.load-center-heading p{margin:3px 0 0;color:#52647a}.load-center-title-icon{font-size:34px;line-height:1}
.load-workflow-card{border:1px solid #cbd8e6;border-radius:7px;margin:10px 0;background:#fff;overflow:hidden}.load-workflow-card>summary{list-style:none;cursor:pointer;display:grid;grid-template-columns:54px 1fr 28px;align-items:center;gap:10px;padding:14px 18px}.load-workflow-card>summary::-webkit-details-marker{display:none}.load-workflow-card>summary b{display:block;font-size:18px;color:#10233e}.load-workflow-card>summary small{display:block;margin-top:3px;color:#40536b;font-size:13px;font-weight:400}.workflow-icon{font-size:30px;text-align:center}.workflow-chevron{font-size:22px;text-align:center;color:#16314f}.load-workflow-card[open] .workflow-chevron{transform:rotate(180deg)}
.manual-card>summary{background:#eaf4ff;border-bottom:1px solid #c9e1fb}.ai-card>summary{background:#ecfaef;border-bottom:1px solid #ccebd3}.auto-card>summary{background:#fff7df;border-bottom:1px solid #f1dfaa}.all-loads-card>summary{background:#f2f6fa;border-bottom:1px solid #d9e2ec}.workflow-body{padding:14px 18px}.workflow-launch{padding:18px}.workflow-open-btn{display:inline-block;background:#1766b1;color:#fff!important;text-decoration:none;font-weight:700;padding:10px 16px;border-radius:5px}.all-loads-body{padding:0 14px 14px}.all-loads-toolbar{padding:12px 4px;color:#1766b1;font-size:16px}.load-workflow-card .create-load-panel{border:0;margin:0}.load-workflow-card .create-load-summary{display:none}
@media(max-width:700px){.load-workflow-card>summary{grid-template-columns:38px 1fr 22px;padding:12px 10px}.workflow-icon{font-size:24px}.load-workflow-card>summary b{font-size:16px}.workflow-body{padding:10px}.load-center-title-icon{font-size:28px}}

/* V2.42 compact Load Center accordion headers */
.load-workflow-card{margin:7px 0;border-radius:6px}
.load-workflow-card>summary{grid-template-columns:42px 1fr 22px;gap:8px;padding:8px 12px;min-height:44px}
.load-workflow-card>summary b{font-size:15px;line-height:1.15}
.load-workflow-card>summary small{margin-top:2px;font-size:11.5px;line-height:1.2}
.workflow-icon{font-size:24px;line-height:1}
.workflow-chevron{font-size:18px;line-height:1}
.workflow-body{padding:10px 12px}
@media(max-width:700px){.load-workflow-card>summary{grid-template-columns:32px 1fr 18px;padding:7px 8px;min-height:40px}.workflow-icon{font-size:21px}.load-workflow-card>summary b{font-size:14px}.load-workflow-card>summary small{font-size:11px}.workflow-body{padding:8px}}


/* V2.62 collapsible site-wide Main Menu */
.main-menu-toggle{
  width:38px;height:34px;min-width:38px;padding:0!important;margin:0 2px 0 0!important;
  display:inline-flex;align-items:center;justify-content:center;align-self:center!important;
  background:#fff!important;color:#12233f!important;border:1px solid rgba(255,255,255,.75)!important;
  border-radius:6px!important;font-size:22px!important;line-height:1!important;font-weight:900!important;cursor:pointer;
}
.main-menu-toggle:hover{background:#eaf1f9!important}
.header-brand{display:flex!important;align-items:center!important;gap:10px!important}
.shell>nav{transition:width .18s ease,flex-basis .18s ease,min-width .18s ease,padding .18s ease,opacity .12s ease}
body.main-menu-collapsed .shell>nav{
  flex:0 0 0!important;width:0!important;min-width:0!important;max-width:0!important;
  padding-left:0!important;padding-right:0!important;border-right:0!important;border-bottom:0!important;
  gap:0!important;overflow:hidden!important;opacity:0!important;pointer-events:none!important;
}
body.main-menu-collapsed main{width:100%!important;max-width:none!important;flex:1 1 100%!important}
@media(max-width:900px){
  body.main-menu-collapsed .shell>nav{display:none!important}
  .main-menu-toggle{width:36px;height:32px;min-width:36px;font-size:21px!important}
}
@media print{.main-menu-toggle{display:none!important}}

/* V2.63 Rate Confirmation e-sign + broker reply */
.ratecon-esign-bar{display:flex;align-items:center;gap:7px;flex-wrap:wrap;margin:10px 0 5px}.esign-btn,.signed-view-btn,.reply-broker-btn{display:inline-flex;align-items:center;justify-content:center;text-decoration:none;border-radius:5px;padding:7px 11px;font-size:12px;font-weight:800;line-height:1}.esign-btn{background:#0b5ed7;color:#fff}.signed-view-btn{background:#d1e7dd;color:#0f5132;border:1px solid #badbcc}.reply-broker-btn{background:#0b2f5b;color:#fff}.ready-chip{display:inline-flex;align-items:center;justify-content:center;background:#b7e4c7;color:#12351c;border:1px solid #89c79d;border-radius:999px;padding:5px 9px;font-size:11px;font-weight:800}.signed-meta{margin:2px 0 7px;color:#475569}
.esign-layout{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(340px,.65fr);gap:14px}.esign-preview-card,.esign-form-card{min-width:0}.esign-pdf-preview{width:100%;height:72vh;min-height:560px;border:1px solid #b8c2cf;border-radius:6px;background:#eef2f6}.esign-form-card label,.broker-reply-form label{display:block;font-weight:700;margin-bottom:10px}.esign-form-card input,.esign-form-card select,.broker-reply-form input,.broker-reply-form textarea{width:100%;box-sizing:border-box;margin-top:4px}.esign-row{display:grid;grid-template-columns:1fr 1fr;gap:9px}.signature-wrap{border:2px dashed #8fa1b5;border-radius:7px;background:#fff;overflow:hidden;margin:5px 0 9px}.signature-wrap canvas{display:block;width:100%;height:150px;touch-action:none;cursor:crosshair}.esign-actions{display:flex;justify-content:flex-end;gap:8px}.btn-secondary{background:#e9ecef!important;color:#263238!important}.esign-sign-btn{background:#0b5ed7!important;color:#fff!important;border:0!important;border-radius:5px!important;padding:10px 15px!important;font-weight:800!important;width:auto!important}.esign-note{color:#5d6875}.broker-reply-card{max-width:820px;margin-left:auto;margin-right:auto}.broker-reply-form textarea{resize:vertical}.gmail-send-box{background:#f7f9fc;border:1px solid #cbd5e1;border-radius:6px;padding:10px;margin:12px 0}.gmail-send-box small{display:block;color:#64748b;margin:2px 0 8px}.reply-attachment{background:#eef6ff;border:1px solid #b7d4f2;border-radius:5px;padding:9px 11px;margin:10px 0 12px}.reply-ready{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
@media(max-width:1000px){.esign-layout{grid-template-columns:1fr}.esign-pdf-preview{height:60vh;min-height:430px}}@media(max-width:600px){.esign-row{grid-template-columns:1fr}.esign-pdf-preview{min-height:350px}.ratecon-esign-bar>a,.ratecon-esign-bar .ready-chip{flex:1 1 145px}}

/* V2.64 outgoing email */
.email-settings-card{max-width:760px;margin:0 auto}.email-settings-form{display:grid;gap:12px}.email-settings-form label,.broker-reply-form label{display:grid;gap:5px;font-weight:700}.email-settings-form input,.broker-reply-form input,.broker-reply-form textarea{width:100%;box-sizing:border-box}.email-test-row{margin-top:4px}.email-last-test,.sending-from{margin:12px 0;padding:10px 12px;border:1px solid #d8e2ef;border-radius:8px;background:#f7faff}.sending-from{margin-top:0}

/* V2.65 email diagnostics */
.email-connection-banner{padding:10px 12px;border-radius:8px;margin-bottom:12px;border:1px solid #cbd5e1;background:#fff7d6;color:#5f4b00}.email-connection-banner.email-ok{background:#eaf7ee;border-color:#9fd2ae;color:#155724}.email-connection-banner span{font-size:12px;color:#5b6472}.ratecon-send-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.email-help,.email-setup-note{font-size:13px;line-height:1.45}.email-setup-note{margin:10px 0 14px;padding:10px 12px;background:#eef5ff;border:1px solid #bdd4f6;border-radius:8px}.email-last-test{margin-top:12px;padding:10px;border-radius:7px;background:#f8fafc;border:1px solid #d8e0ea}


/* V2.102 — system-wide draggable table columns */
.zebra-resizable-th{position:relative!important}
.zebra-col-resize-handle{position:absolute;top:0;right:-3px;width:7px;height:100%;z-index:8;cursor:col-resize;touch-action:none;user-select:none;background:transparent}
.zebra-col-resize-handle:hover,.zebra-col-resize-handle.active{background:rgba(23,102,177,.22)}
body.zebra-column-resizing,body.zebra-column-resizing *{cursor:col-resize!important;user-select:none!important}
.tablewrap,.responsive-tablewrap,.all-loads-tablewrap{max-width:100%}
@media(max-width:700px){.zebra-col-resize-handle{width:10px;right:-5px}}
@media print{.zebra-col-resize-handle{display:none!important}}
\n\n/* V2.107 system-wide smart fair-share tables */
table[data-zebra-auto-fit="1"] th,table[data-zebra-auto-fit="1"] td{box-sizing:border-box;min-width:0}
table[data-zebra-auto-fit="1"] th{overflow:hidden;text-overflow:ellipsis}
table[data-zebra-auto-fit="1"] td{overflow:hidden;text-overflow:ellipsis}
table[data-zebra-auto-fit="1"] td>a,table[data-zebra-auto-fit="1"] td>span{max-width:100%}
.driver-clean-table[data-zebra-auto-fit="1"] td{white-space:nowrap}
.driver-clean-table[data-zebra-auto-fit="1"] .driver-name{overflow:hidden;text-overflow:ellipsis}
.driver-clean-table[data-zebra-auto-fit="1"] .driver-actions{display:flex;justify-content:center;gap:5px;min-width:0}
.driver-clean-table[data-zebra-auto-fit="1"] .driver-actions .editlink,.driver-clean-table[data-zebra-auto-fit="1"] .driver-actions .deletebtn{white-space:nowrap}
@media(max-width:700px){table[data-zebra-auto-fit="1"]{font-size:11px}.responsive-tablewrap,.tablewrap{overflow-x:auto;-webkit-overflow-scrolling:touch}}
\n\n/* V2.118 schedule popup visibility + cancel X */\n.load-workflow-card[open]{overflow:visible;position:relative;z-index:20}\n.load-workflow-card[open]>.workflow-body{position:relative;z-index:21}\n.schedule-field{z-index:auto}\n.schedule-field:has(.schedule-popup[style*="display: block"]){z-index:3000}\n.schedule-popup{z-index:4000!important;overflow:visible!important}\n.schedule-popup-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}\n.schedule-popup-head b{margin:0!important;display:block}\n.schedule-close{width:30px!important;height:30px!important;min-width:30px!important;padding:0!important;margin:0!important;border:0!important;border-radius:50%!important;background:#d92d20!important;color:#fff!important;font-size:22px!important;font-weight:900!important;line-height:28px!important;display:flex!important;align-items:center!important;justify-content:center!important;cursor:pointer!important;box-shadow:none!important}\n.schedule-close:hover{background:#b42318!important}\n@media(max-width:700px){.schedule-popup{left:0;right:auto;max-width:calc(100vw - 32px)}}\n\n\n/* V2.119 schedule popup: viewport-safe and close X inside top-right */\n.schedule-popup{\n  position:fixed!important;\n  top:auto;left:auto;\n  width:280px!important;\n  max-width:calc(100vw - 20px)!important;\n  max-height:calc(100vh - 20px)!important;\n  overflow-y:auto!important;\n  box-sizing:border-box!important;\n  z-index:100000!important;\n}\n.schedule-popup-head{\n  position:relative!important;\n  min-height:30px!important;\n  padding-right:38px!important;\n  display:block!important;\n  margin-bottom:8px!important;\n}\n.schedule-popup-head b{display:block!important;line-height:30px!important}\n.schedule-close{\n  position:absolute!important;\n  top:0!important;\n  right:0!important;\n  width:28px!important;height:28px!important;min-width:28px!important;\n  border-radius:5px!important;\n  font-size:20px!important;line-height:26px!important;\n}\n@media(max-width:700px){\n  .schedule-popup{width:min(280px,calc(100vw - 20px))!important;max-width:calc(100vw - 20px)!important;}\n}\n

/* V2.120: reliable centered date/time picker + manual multi-stop entry */
.schedule-popup{
 position:fixed!important;left:50%!important;top:50%!important;transform:translate(-50%,-50%)!important;
 width:min(330px,calc(100vw - 24px))!important;max-height:calc(100vh - 24px)!important;overflow:auto!important;
 z-index:1000000!important;background:#fff!important;
}
.schedule-popup input[type="date"]{width:100%!important;min-width:0!important;box-sizing:border-box!important;pointer-events:auto!important;position:relative!important;z-index:2!important}
.schedule-popup .schedule-close{top:0!important;right:0!important}
.multi-stop-manager{grid-column:1/-1;border:1px solid #c7d5e7;border-radius:7px;background:#f8fbff;padding:9px 10px;margin-top:2px;min-width:0}
.multi-stop-head{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.multi-stop-head>div:first-child{display:flex;flex-direction:column;gap:1px}.multi-stop-head small{color:#52657c;font-weight:400}
.multi-stop-actions{display:flex;gap:6px;flex-wrap:wrap}
#extraStops{display:flex;flex-direction:column;gap:7px;margin-top:8px}
.extra-stop-row{display:grid;grid-template-columns:88px minmax(130px,.8fr) minmax(210px,1.7fr) minmax(130px,.75fr) minmax(110px,.65fr) 34px;gap:7px;align-items:end;padding:7px;border:1px solid #d9e2ee;border-radius:6px;background:#fff;min-width:0}
.extra-stop-row label{min-width:0;margin:0}.extra-stop-row label span{display:block;font-size:12px;font-weight:700;margin-bottom:3px}.extra-stop-row input{width:100%;min-width:0;box-sizing:border-box}
.extra-stop-type{font-weight:800;align-self:center;color:#153a63}.extra-stop-remove{width:32px;height:32px;padding:0!important;border:0;border-radius:5px;background:#d92d20!important;color:#fff!important;font-size:20px;font-weight:900;line-height:30px}
@media(max-width:900px){.extra-stop-row{grid-template-columns:90px 1fr 1.4fr 1fr 1fr 34px}}
@media(max-width:700px){.extra-stop-row{grid-template-columns:1fr 34px}.extra-stop-type{grid-column:1/2}.extra-stop-row label{grid-column:1/-1}.extra-stop-remove{grid-column:2;grid-row:1}}


/* V2.121 — date picker close button locked to inside top-right corner */
.schedule-popup{position:fixed!important;}
.schedule-popup-head{position:relative!important;display:block!important;padding-right:40px!important;min-height:32px!important;}
.schedule-popup .schedule-close{position:absolute!important;top:0!important;right:0!important;margin:0!important;float:none!important;transform:none!important;}

/* V2.122 ordered multi-stop route */
.extra-stop-type{display:flex;flex-direction:column;gap:1px;line-height:1.15}
.extra-stop-type .route-stop-number{font-size:10px;color:#667085;font-weight:700;text-transform:uppercase;letter-spacing:.02em}
.multi-stop-actions .btn.tiny{white-space:nowrap}


/* V2.130 compact native-like route time picker with Done */
.route-time-field{position:relative!important}
.route-time-popup{
  position:absolute!important;
  z-index:2000000!important;
  top:0!important;
  left:0!important;
  width:220px!important;
  padding:8px!important;
  background:#fff!important;
  border:1px solid #aeb8c4!important;
  border-radius:4px!important;
  box-shadow:0 8px 20px rgba(16,24,40,.18)!important;
  box-sizing:border-box!important;
}
.route-time-native-like{display:grid!important;grid-template-columns:62px 62px 62px!important;gap:5px!important;align-items:start!important}
.route-time-native-like select{
  width:100%!important;
  min-width:0!important;
  height:118px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  outline:0!important;
  background:#fff!important;
  font:600 13px Arial,sans-serif!important;
  text-align:center!important;
  overflow-y:auto!important;
}
.route-time-native-like .route-ampm-list{height:58px!important}
.route-time-native-like option{padding:5px 4px!important;text-align:center!important}
.route-time-native-like option:checked{background:#d9dde3 linear-gradient(0deg,#d9dde3,#d9dde3)!important;color:#111!important;font-weight:800!important}
.route-time-done{
  display:block!important;
  width:100%!important;
  height:30px!important;
  margin:7px 0 0!important;
  padding:0 10px!important;
  border:0!important;
  border-radius:4px!important;
  background:#1f66b2!important;
  color:#fff!important;
  font-size:12px!important;
  font-weight:800!important;
  cursor:pointer!important;
}
.route-time-done:hover{background:#18558f!important}
@media(max-width:700px){.route-time-popup{width:210px!important;max-width:calc(100vw - 24px)!important}}

/* ---------------------------------------------------------------
   Site-wide zebra striping.
   Painted on the ROW, never the cell, so any row that carries its own
   state colour on its <td> (.strongrow, .overdue-row, .current-company,
   .selected-source-load, .load-route-detail) still shows that colour --
   the cell background simply paints over this one.
   Header rows live in <thead> and are unaffected.
   --------------------------------------------------------------- */
table tbody tr:nth-child(odd){background:#fff}
table tbody tr:nth-child(even){background:#eef1f4}

/* All Loads inserts a hidden route-detail row after every load row, so
   nth-child() alternates on the wrong rows there. That table is striped
   from a class rendered by the loop instead. */
.loads-compact tbody tr{background:transparent}
.loads-compact tbody tr.load-row{background:#fff}
.loads-compact tbody tr.load-row.zebra-alt{background:#eef1f4}

/* ===============================================================
   Column auto-fit + phone card layout  (V2.143)
   The JS in base.html measures each column twice -- once with
   wrapping off, once with wrapping on -- and shares the real screen
   width between those numbers. These rules exist so that nothing
   else clamps the table while it is being measured, and so that
   rows can become cards on a phone.
   =============================================================== */

/* --- measurement passes: no clamping, no truncation --- */
table.zebra-measure-max th,table.zebra-measure-max td,
table.zebra-measure-max .load-address,table.zebra-measure-max .addr-street,table.zebra-measure-max .addr-locality{
  white-space:nowrap!important;max-width:none!important;min-width:0!important;
  width:auto!important;overflow:visible!important;text-overflow:clip!important}
table.zebra-measure-min th,table.zebra-measure-min td,
table.zebra-measure-min .load-address,table.zebra-measure-min .addr-street,table.zebra-measure-min .addr-locality{
  white-space:normal!important;max-width:none!important;min-width:0!important;
  width:auto!important;overflow:visible!important;text-overflow:clip!important;
  overflow-wrap:anywhere}

/* --- fitted tables wrap their text instead of truncating it ---
   A row's CSS height acts as a minimum, so rows still grow to fit. */
/* A collapsed list row is exactly one line: anything too long is cut with an
   ellipsis and carries a title tooltip. Expanding the row (the triangle) is
   what reveals the full text. Headers may still wrap onto two lines. */
table[data-zebra-auto-fit="1"]>tbody>tr>td{
  white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
table[data-zebra-auto-fit="1"] th{white-space:normal!important;overflow-wrap:anywhere}
/* ...and an expanded row shows everything it has. */
table[data-zebra-auto-fit="1"]>tbody>tr.address-expanded>td{
  white-space:normal!important;overflow:visible!important;text-overflow:clip!important;
  overflow-wrap:anywhere;height:auto!important}
table[data-zebra-auto-fit="1"]>tbody>tr.address-expanded .load-address,
table[data-zebra-auto-fit="1"]>tbody>tr.address-expanded .addr-street,
table[data-zebra-auto-fit="1"]>tbody>tr.address-expanded .addr-locality{
  white-space:normal!important;max-width:none!important;overflow:visible!important;
  text-overflow:clip!important;overflow-wrap:anywhere}

/* --- phone: each row becomes a card, labels taken from the header --- */
table.zebra-cards{display:block!important;width:100%!important;min-width:0!important;
  max-width:100%!important;table-layout:auto!important;border:0!important}
table.zebra-cards>colgroup{display:none!important}
table.zebra-cards>thead{display:none!important}
table.zebra-cards>tbody{display:block!important}
table.zebra-cards>tbody>tr{display:block!important;height:auto!important;
  border:1px solid #d4dde8;border-radius:10px;background:#fff;
  margin:0 0 10px;padding:8px 11px;box-shadow:0 1px 2px rgba(15,23,42,.06)}
table.zebra-cards>tbody>tr.zebra-alt{background:#f7f9fb}
table.zebra-cards>tbody>tr[hidden]{display:none!important}
table.zebra-cards>tbody>tr>td{display:flex!important;align-items:center;gap:10px;
  width:auto!important;max-width:none!important;min-width:0!important;
  border:0!important;border-bottom:1px solid #eef1f5!important;
  padding:7px 0!important;text-align:left!important;white-space:normal!important;
  overflow:visible!important;overflow-wrap:anywhere;font-size:12px!important;
  flex-wrap:nowrap}
table.zebra-cards>tbody>tr>td:last-child{border-bottom:0!important}
table.zebra-cards>tbody>tr>td::before{content:attr(data-label);
  flex:0 0 38%;max-width:140px;min-width:0;
  font-weight:700;color:#48576b;font-size:11px;line-height:1.3;
  white-space:normal;overflow-wrap:anywhere}
/* the value side gets whatever is left, and may shrink */
table.zebra-cards>tbody>tr>td>*{min-width:0;max-width:100%}
table.zebra-cards .docbuttons{width:auto!important;justify-content:flex-start!important;
  flex-wrap:wrap!important;display:flex!important;gap:4px!important}
table.zebra-cards .docbtn{font-size:10px!important;padding:4px 7px!important;max-width:none!important}
table.zebra-cards .load-actions,table.zebra-cards .recordactions{display:flex!important;
  flex-wrap:wrap!important;gap:6px!important;justify-content:flex-start!important}
table.zebra-cards>tbody>tr>td[colspan]{display:block!important}
table.zebra-cards>tbody>tr>td[colspan]::before{display:none}
table.zebra-cards>tbody>tr>td.zebra-blank{display:none!important}
/* first cell of a card reads as its title */
table.zebra-cards>tbody>tr>td:first-child{font-weight:700;font-size:13px!important}
table.zebra-cards .zebra-col-resize-handle{display:none!important}
table.zebra-cards .load-address{white-space:normal!important;max-width:none!important;overflow:visible!important}

/* the wrapper must not add its own scrollbar once rows are cards */
.tablewrap:has(> table.zebra-cards),
.responsive-tablewrap:has(> table.zebra-cards),
.all-loads-tablewrap:has(> table.zebra-cards){overflow-x:visible!important}

/* Card rows must beat per-page rules that centre or pad individual columns
   (All Loads centres its Invoice and Send/Resend columns). Repeating the
   class raises specificity above those selectors without using a page-specific
   name here. */
table.zebra-cards.zebra-cards>tbody>tr>td{
  text-align:left!important;justify-content:flex-start!important;
  padding-left:0!important;padding-right:0!important;
  border-left:0!important;border-right:0!important;border-top:0!important}
table.zebra-cards.zebra-cards>tbody>tr>td::before{text-align:left!important}
table.zebra-cards.zebra-cards>tbody>tr>td>*{margin-left:0!important;margin-right:0!important}

/* Card rows and their cells must be free to grow: several tables pin a row or
   cell height for the dense desktop grid, which makes card rows overlap. */
table.zebra-cards.zebra-cards>tbody>tr,
table.zebra-cards.zebra-cards>tbody>tr>td,
table.zebra-cards.zebra-cards>tbody>tr>th{height:auto!important;min-height:0!important;
  max-height:none!important;line-height:1.4!important;vertical-align:top!important}


/* ===============================================================
   Black table headers, site-wide (V2.144)
   =============================================================== */
table th,table thead th,table tr th{
  background:#111827!important;color:#ffffff!important;
  border-color:#2b3648!important}
table th a,table thead th a{color:#cfe2ff!important}
table th small,table th .doc-legend,table th .doc-legend span,
table th .th-line,table th .th-wrap{color:#ffffff!important}
/* keep the coloured status keys in the Documents header readable on black */
table th .legend-dot{border:1px solid rgba(255,255,255,.55)!important}
table th .zebra-col-resize-handle:hover{background:rgba(255,255,255,.25)!important}
table.zebra-cards>thead{display:none!important}

/* White separators between the black headers.
   The tables use border-collapse, where two touching borders are merged and
   one of them wins. A white border-left on the right-hand cell LOSES to the
   dark border-right of the cell before it, which is why the line stayed dark.
   Setting border-right on the left-hand cell is the side that wins. */
table thead th,table tr th{border-right:2px solid #ffffff!important}
table thead th:last-child,table tr th:last-child{border-right:0!important}
table thead th+th,table tr th+th{border-left:0!important}
table.zebra-cards>thead th{border-right:0!important}

/* ---- Date / time frames on a route stop (V2.148) ---- */
.route-frame-row{display:flex;align-items:center;gap:6px}
.route-frame-row input[type=date]{flex:1 1 0;min-width:0}
.route-frame-dash{color:#64748b;font-size:11px;font-weight:700}
.route-frame-hint{display:block;color:#7b8794;font-size:10px;margin-top:3px}
.route-time-frame{display:flex;gap:10px;align-items:flex-start}
.route-time-col{flex:1 1 0;min-width:0}
.route-time-col-head{font-weight:800;font-size:11px;color:#0f172a;margin:0 0 4px;text-align:center}
.route-time-range-toggle{display:flex;align-items:center;gap:6px;margin:8px 0 6px;
  font-size:11px;font-weight:700;color:#0f172a;cursor:pointer}
.route-time-range-toggle input{margin:0}

/* The Send / Resend box is a control when the load can actually be sent. */
.send-status-box.send-actionable{cursor:pointer}
.send-status-box.send-actionable:hover{filter:brightness(1.12)}
.send-status-box.send-actionable:focus-visible{outline:2px solid #1d5da8;outline-offset:1px}

/* ===============================================================
   Users & Permissions — page header, role pills, and the shared
   Add/Edit dialog (V2.150)
   =============================================================== */
.users-head{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;margin-bottom:4px}
.users-head h1{margin:0 0 2px}
.users-head p{margin:0;font-size:12px}
.user-primary-btn{display:inline-block;background:#0b6fd3;color:#fff;border:1px solid #075fb7;
  border-radius:7px;padding:10px 18px;font-weight:700;text-decoration:none;line-height:1.2;
  cursor:pointer;box-shadow:0 1px 2px rgba(0,0,0,.08);font-size:13px}
.user-primary-btn:hover{background:#095faf}
.user-edit-btn{display:inline-block;background:#0b6fd3;color:#fff;border:1px solid #075fb7;
  border-radius:6px;padding:7px 14px;font-weight:700;text-decoration:none;font-size:12px}
.user-edit-btn:hover{background:#095faf}
.role-pill{display:inline-block;padding:3px 9px;border-radius:999px;font-size:11px;font-weight:800;
  background:#eef2f7;color:#334155;border:1px solid #dbe3ec;white-space:nowrap}
.role-pill.role-administrator{background:#eef4ff;color:#1d4ed8;border-color:#c7d8fb}
.role-pill.role-dispatcher{background:#ecfdf3;color:#067647;border-color:#bbf0d2}
.role-pill.role-accountant{background:#fff7e6;color:#8a5a00;border-color:#f3dcae}
.role-pill.role-office-support{background:#f5f0ff;color:#6321c9;border-color:#ded0fb}

/* ---- dialog shell ---- */
.zmodal{position:fixed;inset:0;z-index:2147482000;background:rgba(12,20,33,.55);
  display:flex;align-items:flex-start;justify-content:center;padding:28px 16px;overflow:auto}
.zmodal[hidden]{display:none!important}
.zmodal-card{width:100%;max-width:720px;background:#fff;border-radius:14px;overflow:hidden;
  box-shadow:0 24px 60px rgba(6,12,22,.36);animation:zmodal-in .14s ease-out}
@keyframes zmodal-in{from{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:none}}
.zmodal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;
  background:#111827;color:#fff;padding:16px 20px}
.zmodal-head h2{margin:0;font-size:18px;color:#fff}
.zmodal-head p{margin:3px 0 0;font-size:12px;color:#c7d2de}
.zmodal-x{background:transparent;border:0;color:#fff;font-size:26px;line-height:1;cursor:pointer;
  padding:0 2px;opacity:.8}
.zmodal-x:hover{opacity:1}
.zmodal-body{padding:18px 20px 4px;max-height:calc(100vh - 230px);overflow:auto}
.zmodal-foot{display:flex;justify-content:flex-end;gap:10px;padding:14px 20px;
  background:#f6f8fb;border-top:1px solid #e6ecf3}

/* ---- dialog contents ---- */
.zsection{margin:0 0 18px}
.zsection h3{display:flex;align-items:center;gap:8px;margin:0 0 9px;font-size:13px;
  text-transform:uppercase;letter-spacing:.4px;color:#475569}
.zstep{display:inline-flex;align-items:center;justify-content:center;width:20px;height:20px;
  border-radius:50%;background:#111827;color:#fff;font-size:11px;font-weight:800}
.zgrid{display:grid;gap:12px}
.zgrid-2{grid-template-columns:1fr 1fr}
.zgrid-3{grid-template-columns:1fr 1fr 1fr}
.zmodal label{display:block;font-size:12px;font-weight:700;color:#0f172a}
.zmodal label em{color:#b42318;font-style:normal}
.zmodal input[type=text],.zmodal input[type=password],.zmodal input:not([type]),.zmodal select{
  width:100%;box-sizing:border-box;margin-top:4px;padding:9px 10px;font-size:13px;
  border:1px solid #cbd5e1;border-radius:7px;background:#fff;font-weight:500}
.zmodal input:focus,.zmodal select:focus{outline:0;border-color:#0b6fd3;box-shadow:0 0 0 3px rgba(11,111,211,.14)}
.zhint{display:block;margin-top:4px;font-size:11px;font-weight:500;color:#64748b}
.zmodal label.zrole{display:block;max-width:340px}
.zrole-note{margin:8px 0 0;padding:9px 11px;background:#f1f5f9;border-left:3px solid #0b6fd3;
  border-radius:0 6px 6px 0;font-size:12px;color:#334155}
.ztoggles{display:grid;gap:9px;margin-top:14px}
.zmodal label.ztoggle,.ztoggle{display:flex;align-items:flex-start;gap:9px;padding:10px 12px;border:1px solid #e2e8f0;
  border-radius:9px;background:#fbfdff;cursor:pointer;font-weight:500}
.ztoggle:hover{border-color:#bcd3ee;background:#f5faff}
.ztoggle input{margin:2px 0 0;flex:0 0 auto}
.ztoggle span{display:block}
.ztoggle b{display:block;font-size:12.5px;color:#0f172a}
.ztoggle small{display:block;margin-top:2px;font-size:11px;color:#64748b;font-weight:500}
@media(max-width:640px){
  .zgrid-2,.zgrid-3{grid-template-columns:1fr}
  .zmodal{padding:10px}
  .zmodal-body{max-height:calc(100vh - 200px)}
}

/* ---- the user dialog can be moved, resized and maximised ---- */
.zmodal-head{cursor:grab;user-select:none}
.zmodal-head.is-dragging{cursor:grabbing}
.zmodal-tools{display:flex;align-items:center;gap:4px}
.zmodal-tool{background:transparent;border:0;color:#fff;font-size:15px;line-height:1;cursor:pointer;
  padding:4px 6px;border-radius:5px;opacity:.85}
.zmodal-tool:hover{opacity:1;background:rgba(255,255,255,.14)}
.zmodal-card{resize:both;overflow:hidden;min-width:360px;min-height:300px;
  width:min(720px,96vw);max-width:96vw;max-height:92vh;display:flex;flex-direction:column}
.zmodal-card form{display:flex;flex-direction:column;min-height:0;flex:1 1 auto}
.zmodal-body{flex:1 1 auto;min-height:0;max-height:none}
.zmodal-card.is-max{position:fixed!important;inset:8px!important;width:auto!important;
  height:auto!important;max-width:none!important;resize:none}
.zmodal-card::after{content:'';position:absolute;right:2px;bottom:2px;width:14px;height:14px;
  pointer-events:none;opacity:.5;
  background:linear-gradient(135deg,transparent 45%,#94a3b8 45%,#94a3b8 55%,transparent 55%,
             transparent 70%,#94a3b8 70%,#94a3b8 80%,transparent 80%)}
.zmodal-card{position:relative}
.user-delete-btn{display:inline-block;background:#b42318;color:#fff;border:1px solid #96190f;
  border-radius:6px;padding:7px 13px;font-weight:700;font-size:12px;cursor:pointer}
.user-delete-btn:hover{background:#96190f}
.user-delete-na{display:inline-block;padding:0 10px;color:#94a3b8}

/* ---- Roles & Permissions ---- */
.perm-count{display:inline-block;font-weight:800;font-size:11px;color:#0b6fd3;
  background:#eef4ff;border:1px solid #c7d8fb;border-radius:999px;padding:2px 9px;margin-right:6px}
.perm-list{display:inline-flex;flex-wrap:wrap;gap:4px;vertical-align:middle}
.perm-chip{display:inline-block;font-size:10.5px;background:#f1f5f9;color:#334155;
  border:1px solid #e2e8f0;border-radius:5px;padding:2px 6px}
.perm-actions{display:flex;gap:8px;margin:0 0 12px}
.perm-group{margin:0 0 16px}
.perm-group h4{margin:0 0 7px;font-size:12px;font-weight:800;color:#0f172a;
  border-bottom:1px solid #e6ecf3;padding-bottom:5px}
.perm-row{margin-bottom:6px}

/* ---- "did you mean" prompt ---- */
.zspell-bubble{position:absolute;z-index:2147483500;background:#fff;border:1px solid #cbd5e1;
  border-radius:9px;box-shadow:0 10px 26px rgba(15,23,42,.18);padding:9px 10px;min-width:210px;max-width:340px}
.zspell-head{font-size:11px;font-weight:800;color:#8a5a00;margin-bottom:6px}
.zspell-list{display:flex;flex-direction:column;gap:4px;margin-bottom:6px}
.zspell-pick{display:block;width:100%;text-align:left;background:#fff7e6;border:1px solid #f3dcae;
  border-radius:6px;padding:7px 9px;font-size:12.5px;font-weight:700;color:#0f172a;cursor:pointer}
.zspell-pick:hover{background:#ffefcc}
.zspell-keep{display:block;width:100%;text-align:left;background:transparent;border:0;
  color:#64748b;font-size:11px;cursor:pointer;padding:3px 2px}
.zspell-keep:hover{color:#0f172a;text-decoration:underline}

/* ---- Reply to Broker: saved receivers and the safe test box ---- */
.reply-hint{display:block;margin-top:4px;font-size:11px;color:#64748b;font-weight:500}
.reply-hint-warn{color:#9a3412;font-weight:700}
.test-send-box{margin:14px 0 4px;padding:11px 13px;background:#f1f6fb;border:1px solid #cfe0f2;
  border-radius:9px;font-size:12px;color:#334155}
.test-send-box label{display:block;margin-top:7px;font-weight:700;font-size:12px;color:#0f172a}
.test-send-box input{width:100%;max-width:340px;box-sizing:border-box;margin-top:4px;padding:8px 10px;
  border:1px solid #cbd5e1;border-radius:7px;font-size:13px}

/* ---- signed RateCon preview on the reply page ---- */
.reply-attachment{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.attach-actions{display:flex;align-items:center;gap:8px}
.preview-toggle{cursor:pointer}
.signed-preview{margin:10px 0 4px;border:1px solid #cfe0f2;border-radius:10px;overflow:hidden;background:#f8fbff}
.signed-preview[hidden]{display:none}
.signed-preview-label{padding:7px 12px;font-size:11.5px;font-weight:700;color:#0b2f5b;
  background:#eaf3fc;border-bottom:1px solid #cfe0f2}
.signed-preview iframe{display:block;width:100%;height:460px;border:0;background:#fff}
@media(max-width:760px){.signed-preview iframe{height:320px}}

/* ===== V2.155 — signature placement on the RateCon =================== */
.sig-place{border:1px solid #cfd7e2;border-radius:10px;background:#f7f9fc;padding:10px;margin:0 0 14px}
.sig-place-status{font-size:12.5px;font-weight:600;padding:7px 9px;border-radius:7px;background:#eef2f7;color:#31404f;margin-bottom:9px}
.sig-place-status.sig-ok{background:#e7f6ec;color:#1b5e34;border:1px solid #b7e0c4}
.sig-place-status.sig-warn{background:#fff7ed;color:#92400e;border:1px solid #f5cfa0}
.sig-place-map{background:#fff;border:1px solid #d5dbe3;border-radius:7px;overflow:auto;max-height:430px}
.sig-place-map canvas{display:block;width:100%;height:auto;cursor:crosshair}
.sig-place-actions{display:flex;flex-wrap:wrap;gap:9px;align-items:center;margin-top:9px}
.sig-place-actions small{color:#56637a;font-size:11.5px}
@media (max-width:860px){.sig-place-map{max-height:320px}}

/* ===== V2.156 — choose a signature, or draw one ====================== */
.sig-choose{border:1px solid #cfd7e2;border-radius:10px;background:#f7f9fc;padding:10px;margin:0 0 14px}
.sig-tabs{display:flex;gap:6px;margin-bottom:10px;flex-wrap:wrap}
.sig-tab{flex:1 1 150px;padding:9px 12px;border:1px solid #c6cfdb;border-radius:8px;background:#fff;
 color:#31404f;font-size:13px;font-weight:700;cursor:pointer}
.sig-tab:hover{border-color:#8fa6c4}
.sig-tab.is-on{background:#0b2f5b;border-color:#0b2f5b;color:#fff}
.sig-name-label{display:block;margin:0 0 10px}
.sig-name-label input{width:100%}
.sig-styles{display:grid;grid-template-columns:repeat(auto-fill,minmax(215px,1fr));gap:9px}
.sig-style{position:relative;padding:0;border:2px solid #d5dbe3;border-radius:9px;background:#fff;
 cursor:pointer;overflow:hidden;line-height:0}
.sig-style:hover{border-color:#8fa6c4}
.sig-style.is-on{border-color:#1d4ed8;box-shadow:0 0 0 3px rgba(29,78,216,.16)}
.sig-style canvas{display:block;width:100%;height:auto}
.sig-style-tag{position:absolute;left:0;bottom:0;padding:2px 7px;font-size:10.5px;line-height:1.6;
 font-weight:700;letter-spacing:.03em;text-transform:uppercase;color:#5a6779;background:rgba(255,255,255,.9);
 border-top-right-radius:7px}
.sig-style.is-on .sig-style-tag{color:#fff;background:#1d4ed8}
.sig-draw-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin-top:8px}
.sig-hint{color:#56637a;font-size:11.5px}
@media (max-width:860px){.sig-styles{grid-template-columns:repeat(auto-fill,minmax(170px,1fr))}}

/* ===== V2.159 — full test email to yourself ========================== */
.test-send-actions{display:flex;flex-wrap:wrap;gap:8px;margin:9px 0 4px}
.test-send-actions .btn-secondary{flex:0 1 auto}
.test-send-box .test-full-btn{border-color:#0b2f5b;color:#0b2f5b;font-weight:700}
.test-send-box .test-full-btn:hover{background:#0b2f5b;color:#fff}

/* ===== V2.160 — permissions you cannot hand out ====================== */
.perm-row.perm-locked{opacity:.55;cursor:not-allowed}
.perm-row.perm-locked input{cursor:not-allowed}
.perm-locked-note{display:block;color:#92400e;font-weight:600}
.users-head .muted{max-width:760px}

/* ===== V2.161 — automatic load import =============================== */
.auto-status{display:flex;flex-wrap:wrap;justify-content:space-between;gap:10px;align-items:center;border-left:6px solid #94a3b8}
.auto-status.auto-on{border-left-color:#067647;background:#f2fbf5}
.auto-status.auto-off{border-left-color:#b42318;background:#fff6f5}
.auto-status-main b{font-size:15px}
.auto-status-main span{margin-left:10px;color:#3d4b5c}
.auto-status-meta{color:#56637a;font-size:12.5px}
.warn-card{border:2px solid #d97706;background:#fff7ed}
.warn-card h2{margin-top:0;color:#9a3412}
.auto-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(320px,1fr));gap:14px;align-items:start}
.auto-steps{margin:0;padding-left:20px}
.auto-steps li{margin:7px 0;line-height:1.5}
.auto-form label{display:block;margin:10px 0}
.auto-fields{margin:6px 0 14px}
.auto-hint{display:block;color:#56637a;font-size:11.5px;font-weight:400;margin-top:3px}
.auto-range{display:flex;flex-wrap:wrap;gap:12px;align-items:end}
.auto-range label{margin:0}
.auto-flagged{border:2px solid #d97706;background:#fff7ed}
.auto-flagged h2{margin-top:0;color:#9a3412}
.auto-why{font-size:12px;color:#3d4b5c;white-space:normal;max-width:520px}
.broker-verify-card{border:2px solid #d97706;background:#fff7ed}
.broker-verify-line{margin:6px 0}
@media (max-width:860px){.auto-grid{grid-template-columns:1fr}}

/* ===== V2.162 — everything the scan found, in one list =============== */
.auto-waiting-warn{border:2px solid #d97706}
.auto-waiting tr.row-needs-check{background:#fff7ed}
.chip-warn{color:#9a3412;font-size:11.5px;white-space:nowrap}
.chip-ok{color:#067647;font-size:11.5px}

/* ===== V2.163 — say what permission is missing ====================== */
.perm-needed{font-size:11px;color:#92400e;white-space:normal;display:inline-block;max-width:190px;line-height:1.35}

/* ===== V2.164 — act on a waiting Rate Confirmation from the list ===== */
.wait-actions{white-space:nowrap}
.wait-actions form{display:inline;margin:0}
.wait-actions>*{margin:0 3px 3px 0}
.wait-actions .approve-btn{background:#067647;border-color:#067647;color:#fff;font-weight:700}
.wait-actions .approve-btn:hover{background:#04532f}
.wait-actions a.btn,.wait-actions button.btn{display:inline-block;padding:5px 11px;border-radius:6px;border:1px solid #c6cfdb;
 background:#fff;color:#1d4ed8;font-size:12px;font-weight:700;text-decoration:none;cursor:pointer;line-height:1.4}
.wait-actions a.btn:hover,.wait-actions button.btn:hover{border-color:#8fa6c4}
.wait-actions a.btn.primary{background:#1d4ed8;border-color:#1d4ed8;color:#fff}
.wait-actions .danger-outline{color:#b42318;border-color:#f0b4ae}
.wait-actions .danger-outline:hover{background:#b42318;color:#fff;border-color:#b42318}
.wait-actions button.btn.approve-btn{background:#067647;border-color:#067647;color:#fff}
.wait-actions button.btn.approve-btn:hover{background:#04532f;border-color:#04532f}
.wait-actions button.btn.disapprove-btn{color:#92400e;border-color:#f0c48a}
.wait-actions button.btn.disapprove-btn:hover{background:#92400e;color:#fff;border-color:#92400e}

/* ===== V2.166 — placing a signature on a page Zebra cannot read ======= */
.sig-place-pdf{position:relative;width:100%;border:1px solid #d5dbe3;border-radius:7px;overflow:hidden;background:#fff}
.sig-place-pdf iframe{position:absolute;inset:0;width:100%;height:100%;border:0}
.sig-clickpad{position:absolute;inset:0;cursor:crosshair;background:transparent}
.sig-pad-mark{position:absolute;width:34%;height:26px;margin-left:-17%;margin-top:-13px;
 border:2px solid #1d4ed8;border-radius:5px;background:rgba(29,78,216,.16);pointer-events:none}
.sig-pad-mark::after{content:'signature';position:absolute;left:4px;top:-16px;font-size:10px;font-weight:700;color:#1d4ed8}

/* ---------------------------------------------------------------
   V2.169: report tables - compact rows, a green head and green stripes.
   These sit AFTER the site-wide black table header block and use
   "table.accountingtable ... tr th" so they beat it outright. The black
   header rule is what was turning the row names white on white.
   --------------------------------------------------------------- */
.visually-hidden{position:absolute!important;width:1px!important;height:1px!important;
 overflow:hidden!important;clip:rect(0 0 0 0)!important;white-space:nowrap!important;border:0!important;padding:0!important;margin:-1px!important}

table.accountingtable{border-collapse:collapse}
table.accountingtable th,table.accountingtable td{padding:5px 10px!important;line-height:1.2!important;font-size:13px!important}

/* The head: green, with dark green writing. */
table.accountingtable thead tr th{
 background:#1f7a3a!important;color:#ffffff!important;border:1px solid #17622e!important;
 border-right:2px solid #ffffff!important;font-weight:700!important;text-align:center!important;vertical-align:bottom!important}
table.accountingtable thead tr th:last-child{border-right:1px solid #17622e!important}
table.accountingtable thead tr th a{color:#ffffff!important;text-decoration:none!important}
table.accountingtable thead tr th a:hover{text-decoration:underline!important}
table.accountingtable thead tr th small{display:block!important;color:#d8f0e0!important;font-weight:400!important;font-size:11px!important;margin-top:2px!important}

/* The row-name column: plain, readable, wide enough for its words. */
table.accountingtable tbody tr th{
 background:#ffffff!important;color:#172033!important;border:1px solid #cfd8e3!important;
 font-weight:700!important;text-align:left!important;white-space:nowrap!important;
 width:170px!important;min-width:150px!important}
table.accountingtable tbody tr th.subrow{font-weight:400!important;padding-left:24px!important}
table.accountingtable thead tr th.rowlabel-head{width:170px!important;min-width:150px!important;background:#1f7a3a!important}

/* Green stripes down the rows. */
table.accountingtable tbody tr:nth-child(odd) td{background:#ffffff!important}
table.accountingtable tbody tr:nth-child(even) td{background:#e7f4ec!important}
table.accountingtable tbody tr.groupheadrow th{background:#d7eede!important;color:#0d3b24!important;font-weight:700!important;text-align:left!important}
table.accountingtable tbody tr.strongrow th,table.accountingtable tbody tr.strongrow td{background:#cfead8!important;color:#0d3b24!important;font-weight:700!important}
table.accountingtable tbody tr td{border:1px solid #cfd8e3!important}

/* A script in base.html wraps the text of every <th> in .th-wrap/.th-line
   spans, and the site-wide black header block paints those spans white.
   On the report tables that made the row names white on white. These put
   the colour and the left alignment back on the row-name column. */
table.accountingtable tbody tr th .th-wrap{display:block!important;text-align:left!important;color:inherit!important}
table.accountingtable tbody tr th .th-line{display:inline!important;color:#172033!important;font:inherit!important}
table.accountingtable tbody tr th .th-line+.th-line::before{content:" "!important;white-space:pre!important}
table.accountingtable tbody tr.strongrow th .th-line,
table.accountingtable tbody tr.groupheadrow th .th-line{color:#0d3b24!important}
table.accountingtable thead tr th .th-wrap{color:#ffffff!important}
table.accountingtable thead tr th .th-line{color:#ffffff!important}

/* V2.174: the row-name column has no heading, so its header box stays plain
   white like the Profit and Loss by Class report, not part of the green bar. */
table.accountingtable thead tr th.rowlabel-head{background:#ffffff!important;border:1px solid #cfd8e3!important;border-right:1px solid #cfd8e3!important}
/* Clickable amounts read as links: blue, on white and on green alike. */
table.accountingtable tbody tr td a{color:#1559a8!important;text-decoration:none!important;font-weight:inherit}
table.accountingtable tbody tr td a:hover{text-decoration:underline!important}
table.accountingtable tbody tr.strongrow td a{color:#10457f!important}

/* V2.178: the band shown while the platform owner is inside a renter company. */
.renter-banner{background:#fff4d6;border:1px solid #e0c168;color:#5b4300;
 border-radius:8px;padding:10px 14px;margin:0 0 14px;font-size:14px;font-weight:600}
.renter-banner b{color:#3d2d00}
@media (prefers-color-scheme: dark){
 .renter-banner{background:#3a2f0d;border-color:#7a6420;color:#f3e4b4}
 .renter-banner b{color:#fff6d8}
}

/* V2.179: the extra detail on a compliance paper. */
.compliance-history-link{display:inline-block;margin-left:8px;font-size:12px;font-weight:700;
 color:#173d73;text-decoration:none;white-space:nowrap}
.compliance-history-link:hover{text-decoration:underline}
.compliance-howoften{display:block;margin-top:3px;font-size:11px;color:#657087;font-weight:400;line-height:1.2}
.compliance-same-record{display:flex;align-items:center;gap:6px;font-size:11.5px;font-weight:600;
 color:#566171;white-space:normal;margin-top:4px}
.compliance-same-record input{width:16px;height:16px;margin:0}

/* ---------------------------------------------------------------
   V2.183: the compliance paper row, rebuilt. The extra fields added
   in V2.179 did not fit the old six-column grid and the parts ran
   over each other. This lays the row out in two clear bands: the
   paper and its status on top, then its fields below.
   --------------------------------------------------------------- */
.compliance-doc-row{display:block!important;padding:12px 14px!important}
.cdoc-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:10px}
.cdoc-no{min-width:26px;height:26px;border-radius:6px;background:#eef2f7;color:#3f4a57;
 display:inline-flex;align-items:center;justify-content:center;font-weight:800;font-size:13px;
 font-variant-numeric:tabular-nums;flex:0 0 auto}
.cdoc-name{font-weight:800;font-size:14px;display:flex;flex-direction:column;gap:1px;min-width:0}
.cdoc-name small{font-weight:400;font-size:11px;color:#657087;line-height:1.2}
.cdoc-tick{width:30px;height:30px;border-radius:50%;background:#1f7a3a;color:#fff;
 display:inline-flex;align-items:center;justify-content:center;font-size:18px;font-weight:900;flex:0 0 auto}
.cdoc-head .exp-badge{margin-left:auto}
.cdoc-form{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px;align-items:end}
.cdoc-form label{font-size:12px;font-weight:700;margin:0;min-width:0}
.cdoc-form input[type=text],.cdoc-form input[type=date]{width:100%;margin-top:4px}
.cdoc-file{grid-column:span 2;min-width:0}
.cdoc-actions{grid-column:1/-1;display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:2px}
.cdoc-history{font-size:12px;font-weight:700;color:#173d73;text-decoration:none;white-space:nowrap}
.cdoc-history:hover{text-decoration:underline}
.cdoc-same{display:flex;align-items:center;gap:6px;font-size:11.5px;font-weight:600;color:#566171;margin:0}
.cdoc-same input{width:16px;height:16px;margin:0}
.compliance-doc-row .compliance-upload-btn{min-height:34px!important;padding:6px 16px!important}
.compliance-doc-row .compliance-delete-file{min-height:34px!important;padding:6px 12px!important;font-size:12px!important}
@media(max-width:700px){
 .cdoc-file{grid-column:1/-1}
 .cdoc-head .exp-badge{margin-left:0;width:100%;text-align:center}
}

/* V2.184: Save sits in the same row as File. The links and the
   "correct this one" box drop to a line of their own underneath. */
.cdoc-file{grid-column:span 2!important;min-width:0}
.cdoc-file input[type=file]{width:100%;margin-top:4px;padding:6px;border:1px solid #bbb;border-radius:5px;background:#fff;font-size:12px}
.cdoc-save{display:flex;align-items:flex-end}
.cdoc-save .compliance-upload-btn{width:100%;min-height:36px!important;white-space:nowrap}
.cdoc-extra{grid-column:1/-1;display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:4px}
@media(max-width:700px){
 .cdoc-file{grid-column:1/-1!important}
 .cdoc-save{grid-column:1/-1}
}

/* V2.192: white-on-colour buttons that are LINKS kept losing their white
   text. The site-wide rule "table.accountingtable tbody tr td a" repaints
   every link in a table blue, which turned blue text on a blue button -
   invisible. This puts the white back, everywhere the buttons are used
   (Backup, DOT Download Pack, Compliance Bills, IFTA, Records, Library,
   Drug tests, Share Online), not just on the page where it was noticed. */
a.rt-open,a.set-access,a.user-primary-btn,
table a.rt-open,table a.set-access,table a.user-primary-btn,
table.accountingtable tbody tr td a.rt-open,
table.accountingtable tbody tr td a.set-access,
table.accountingtable tbody tr td a.user-primary-btn{color:#ffffff!important;text-decoration:none!important}
a.rt-open:hover,table.accountingtable tbody tr td a.rt-open:hover{color:#ffffff!important}
a.set-access:hover,table.accountingtable tbody tr td a.set-access:hover{color:#ffffff!important}
a.user-primary-btn:hover{color:#ffffff!important}

/* V2.215 — the menu in folding groups. Same pages as before, grouped by what
   you are doing. The group holding the page you are on opens by itself, so
   nothing you need is ever hidden behind a click. */
nav a.menu-top{font-weight:700}
nav .mgroup{background:none;border:0;padding:0;margin:0}
nav .mgroup>summary{list-style:none;cursor:pointer;padding:10px 12px 5px;font-size:11px;
  letter-spacing:.08em;text-transform:uppercase;color:#657087;font-weight:700;
  display:flex;align-items:center;gap:7px;border-radius:6px}
nav .mgroup>summary::-webkit-details-marker{display:none}
nav .mgroup>summary::before{content:"\25B8";font-size:10px;transition:transform .12s}
nav .mgroup[open]>summary::before{transform:rotate(90deg)}
nav .mgroup>summary:hover{background:#edf2f8;color:#173d73}
nav .mgroup>a{padding-left:26px}
@media(max-width:700px){nav .mgroup{display:contents}nav .mgroup>summary{padding:8px 10px}}

/* ===== V2.217 - the read-me note, the locked boxes and the popup ======= */
.import-readme{background:#fff7dc;border:1px solid #ead274;border-left:6px solid #d9a400;
 border-radius:10px;padding:14px 16px;margin:10px 0 14px}
.import-readme-head{font-weight:800;font-size:15px;color:#7a5200;letter-spacing:.01em}
.import-readme p{margin:7px 0 11px;color:#5d4300;font-size:14.5px;line-height:1.5}
.import-readme-done{margin-left:10px;color:#15603a;font-weight:700;font-size:13.5px}
.load-workflow-card.is-locked>summary{opacity:.72;cursor:pointer}
.load-workflow-card.is-locked>summary:hover{opacity:.9}
.load-workflow-card.is-locked{border-style:dashed}

/* The popup: plain white, parted by thin silver lines. */
.notice-popup.import-notice{max-width:640px;text-align:left;background:#fff}
.notice-popup.import-notice h3{margin:0 0 4px;font-size:19px;color:#172033}
.import-notice .import-notice-key,
.import-notice .import-notice-row,
.import-notice .import-notice-safe,
.import-notice .import-notice-how{border:0;border-top:1px solid #c9cfd8;
 border-radius:0;padding:12px 14px;margin:0;color:#172033;font-size:14.5px;line-height:1.55}
/* Striped: light green, white, light green... so each block is easy to tell apart. */
.import-notice .import-notice-key{background:#eef8f1}
.import-notice .import-notice-row:nth-of-type(odd){background:#fff}
.import-notice .import-notice-row:nth-of-type(even){background:#eef8f1}
.import-notice .import-notice-safe{background:#fff}
.import-notice .import-notice-how{background:#eef8f1}
.import-notice .import-notice-row b,
.import-notice .import-notice-key b,
.import-notice .import-notice-how b{display:block;margin-bottom:3px;font-size:15px;color:#172033}
.import-notice .import-notice-key b+br+b{margin-top:7px}
.import-notice .import-notice-how ol{margin:7px 0 0;padding-left:20px}
.import-notice .import-notice-how li{margin-bottom:5px}
.import-notice .import-notice-foot{margin:9px 0 0;color:#657087;font-size:13.5px}
.import-notice-buttons{display:flex;gap:9px;flex-wrap:wrap;
 border-top:1px solid #c9cfd8;padding-top:14px;margin-top:12px}
@media (prefers-color-scheme:dark){
 .import-readme{background:#2c2512;border-color:#5c4a1c}
 .import-readme-head{color:#f0c868}.import-readme p{color:#e0cd9a}
 .notice-popup.import-notice{background:#172233}
 .notice-popup.import-notice h3{color:#e7edf5}
 .import-notice .import-notice-key,
 .import-notice .import-notice-row,
 .import-notice .import-notice-safe,
 .import-notice .import-notice-how{border-top-color:#3b4a63;color:#e7edf5}
 .import-notice .import-notice-key{background:#16271e}
 .import-notice .import-notice-row:nth-of-type(odd){background:#172233}
 .import-notice .import-notice-row:nth-of-type(even){background:#16271e}
 .import-notice .import-notice-safe{background:#172233}
 .import-notice .import-notice-how{background:#16271e}
 .import-notice .import-notice-row b,
 .import-notice .import-notice-key b,
 .import-notice .import-notice-how b{color:#e7edf5}
 .import-notice .import-notice-foot{color:#9bacc2}
 .import-notice-buttons{border-top-color:#3b4a63}
}

/* V2.219: how to get the key - on the setup page, striped like the popup */
.key-steps{background:#eef8f1;border:1px solid #c9cfd8;border-radius:10px;
 padding:14px 16px;margin:14px 0;font-size:15px;line-height:1.55;color:#172033}
.key-steps>b{display:block;margin-bottom:6px;font-size:16px}
.key-steps ol{margin:0;padding-left:20px}
.key-steps li{margin-bottom:6px;background:transparent}
.key-steps li:nth-child(even){background:#fff;border-radius:5px;padding:2px 6px;margin-left:-6px}
.key-steps-foot{margin:10px 0 0;color:#657087;font-size:13.5px}
@media (prefers-color-scheme:dark){
 .key-steps{background:#16271e;border-color:#3b4a63;color:#e7edf5}
 .key-steps li:nth-child(even){background:#172233}
 .key-steps-foot{color:#9bacc2}
}

/* V2.222: the note comes up every sign-in, so say plainly what is shut. */
.import-readme-shut{margin:4px 0 11px!important;color:#7a2d00!important;font-weight:700}
@media (prefers-color-scheme:dark){.import-readme-shut{color:#f0a868!important}}

/* ===== V2.223 - tick boxes in the Import Inbox ======================== */
.pick-bar{display:flex;align-items:center;gap:14px;flex-wrap:wrap;
 background:#f3f7fc;border:1px solid #dde4ec;border-radius:9px;padding:9px 13px;margin:0 0 10px}
.pick-all{display:flex;align-items:center;gap:7px;font-weight:700;font-size:14.5px;cursor:pointer}
.pick-all input{width:17px;height:17px;cursor:pointer}
.pick-count{color:#657087;font-size:14px}
.pick-bar .btn.danger[disabled]{opacity:.45;cursor:not-allowed}
.pick-col{width:34px;text-align:center}
.pick-col input{width:17px;height:17px;cursor:pointer}
@media (prefers-color-scheme:dark){
 .pick-bar{background:#172233;border-color:#2a3850}
 .pick-count{color:#9bacc2}
}

/* ===== V2.225 - Manual Load Entry, four steps, one open at a time ===== */
.load-steps{display:block}
.lstep{background:#fff;border:1px solid #dde4ec;border-radius:12px;margin:0 0 12px;padding:16px 18px;
 transition:border-color .15s,background .15s,opacity .15s}
.lstep.off{background:#f2f4f7;opacity:.6}
.lstep.off .lstep-body{pointer-events:none}
.lstep.now{border-color:#1d5da8;border-width:2px;padding:15px 17px;box-shadow:0 0 0 4px #eaf2fc}
.lstep.done{border-color:#8ed3ab;background:#eef8f1}
.lstep-head{display:flex;align-items:center;gap:11px;margin-bottom:4px}
.lstep-num{flex:none;width:30px;height:30px;border-radius:50%;display:grid;place-items:center;
 font-weight:800;font-size:15px;background:#9aa5b4;color:#fff}
.lstep.now .lstep-num{background:#1d5da8}
.lstep.done .lstep-num{background:#15603a}
.lstep-title{font-weight:800;font-size:16.5px}
.lstep.off .lstep-title{color:#9aa5b4}
.lstep-hint{color:#657087;font-size:14px;margin:0 0 12px 41px}
.lstep.now .lstep-hint{color:#1d5da8;font-weight:600}
.lstep.done .lstep-hint{color:#15603a;font-weight:600}
.lstep-body{margin-left:41px}
.lstep-finish{margin:14px 0 0 41px;display:flex;align-items:center;gap:14px;flex-wrap:wrap}
.lstep-why{color:#657087;font-size:14px}
.lstep .create-load-btn[disabled]{opacity:.4;cursor:not-allowed}
.load-label .req{color:#b42318;font-weight:800}
@media (max-width:760px){
 .lstep-hint,.lstep-body,.lstep-finish{margin-left:0}
}
@media (prefers-color-scheme:dark){
 .lstep{background:#172233;border-color:#2a3850}
 .lstep.off{background:#141d2b}
 .lstep.now{border-color:#6aa7e8;box-shadow:0 0 0 4px #15263d}
 .lstep.done{border-color:#2b5c40;background:#122a1e}
 .lstep-num{background:#6a788c}
 .lstep.now .lstep-num{background:#6aa7e8}
 .lstep.done .lstep-num{background:#7cd3a2;color:#0b1422}
 .lstep-title{color:#e7edf5}.lstep.off .lstep-title{color:#6a788c}
 .lstep-hint{color:#9bacc2}
 .lstep.now .lstep-hint{color:#6aa7e8}
 .lstep.done .lstep-hint{color:#7cd3a2}
 .lstep-why{color:#9bacc2}
 .load-label .req{color:#f09188}
}

/* V2.225: step 5 - the Rate Confirmation itself */
.ratecon-pick{display:flex;flex-direction:column;gap:6px;max-width:560px}
.ratecon-pick input[type=file]{font:inherit;padding:9px;border:1px solid #dde4ec;border-radius:8px;background:#fff}
.ratecon-pick small{color:#657087;font-size:13px}
.ratecon-have{background:#eef8f1;border:1px solid #8ed3ab;color:#15603a;border-radius:9px;
 padding:10px 13px;margin:0 0 11px;font-size:14.5px}
@media (prefers-color-scheme:dark){
 .ratecon-pick input[type=file]{background:#172233;border-color:#2a3850;color:#e7edf5}
 .ratecon-pick small{color:#9bacc2}
 .ratecon-have{background:#122a1e;border-color:#2b5c40;color:#7cd3a2}
}

/* V2.226: + Add Load at the top of box 1, and the popup after saving */
.manual-add-top{margin-left:auto;margin-right:12px;text-decoration:none;font-size:14px;
 padding:7px 14px;white-space:nowrap}
.load-workflow-card.manual-card>summary{align-items:center}
.notice-popup.saved-popup{max-width:470px;text-align:center}
.saved-tick{width:56px;height:56px;margin:2px auto 12px;border-radius:50%;background:#eef8f1;
 color:#15603a;font-size:30px;font-weight:800;display:grid;place-items:center;
 border:2px solid #8ed3ab}
.saved-popup h3{margin:0 0 6px;font-size:21px}
.saved-line{margin:0 0 18px;font-size:16px;color:#172033}
.saved-buttons{display:flex;gap:10px;justify-content:center;flex-wrap:wrap}
.saved-buttons .btn{text-decoration:none}
@media (prefers-color-scheme:dark){
 .saved-tick{background:#122a1e;color:#7cd3a2;border-color:#2b5c40}
 .saved-line{color:#e7edf5}
}

/* V2.227: reading the load back before saving it */
.notice-popup.review-popup{max-width:600px;text-align:left}
.review-popup h3{margin:0 0 14px;font-size:20px}
.rv-block{border-top:1px solid #c9cfd8;padding:12px 2px;margin:0}
.rv{display:flex;justify-content:space-between;gap:16px;padding:5px 0;font-size:15px}
.rv span{color:#657087}
.rv b{text-align:right}
.rv-stops{display:flex;flex-direction:column;gap:10px}
.rv-stop{background:#eef8f1;border-radius:8px;padding:9px 12px;font-size:14.5px;line-height:1.45}
.rv-stop b{display:block;margin-bottom:2px}
.rv-soft{color:#657087;font-size:13.5px}
.review-buttons{display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap;
 border-top:1px solid #c9cfd8;padding-top:14px;margin-top:14px}
@media (prefers-color-scheme:dark){
 .rv-block,.review-buttons{border-top-color:#3b4a63}
 .rv span,.rv-soft{color:#9bacc2}
 .rv-stop{background:#122a1e}
}

/* V2.232: the Next button at the foot of each step */
.lstep-next{display:flex;justify-content:flex-end;margin:14px 0 0 41px}
.lstep.off .lstep-next{display:none}
.lstep-next .btn{font-size:15px;padding:10px 20px}
.lstep-next .btn[disabled]{opacity:.4;cursor:not-allowed}
.lstep-next .btn.is-ready{box-shadow:0 0 0 4px #eaf2fc}
@media (max-width:760px){.lstep-next{margin-left:0}}
@media (prefers-color-scheme:dark){.lstep-next .btn.is-ready{box-shadow:0 0 0 4px #15263d}}

/* V2.234: the line above the buttons on the saved popup */
.saved-next{margin:-6px 0 16px;color:#657087;font-size:14.5px}
@media (prefers-color-scheme:dark){.saved-next{color:#9bacc2}}

/* ===== V2.235 - Step 6: sign it and send it ========================== */
.lstep6{border-color:#1d5da8;border-width:2px;box-shadow:0 0 0 4px #eaf2fc}
.sign6-grid{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(300px,1fr);gap:20px;align-items:start}
.sign6-paper-head{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin-bottom:8px;font-size:14.5px}
.sign6-paper-head label{display:flex;align-items:center;gap:6px}
.sign6-paper-head select{font:inherit;padding:5px 8px;border:1px solid #dde4ec;border-radius:7px;background:#fff}
.sign6-stage{position:relative;border:1px solid #dde4ec;border-radius:10px;overflow:hidden;
 background:#fff;min-height:320px;cursor:crosshair}
.sign6-stage img{display:block;width:100%;height:auto}
.sign6-stage.no-picture{background:repeating-linear-gradient(45deg,#f7f9fc,#f7f9fc 12px,#eef2f7 12px,#eef2f7 24px);min-height:420px}
.sig-box{position:absolute;left:60%;top:80%;width:150px;height:24px;border:2px dashed #1d5da8;
 background:rgba(29,93,168,.12);border-radius:8px;display:grid;place-items:center;text-align:center;
 font:700 10.5px/1.1 Arial;color:#1d5da8;cursor:grab;user-select:none;touch-action:none}
.sig-box>span{overflow:hidden;white-space:nowrap;max-width:100%}
.sig-box.dragging{cursor:grabbing;background:rgba(29,93,168,.22);box-shadow:0 4px 14px rgba(16,24,40,.25)}
/* V2.239: the circle at the corner makes the signature bigger or smaller */
.sig-grip{position:absolute;right:-12px;bottom:-12px;width:24px;height:24px;border-radius:50%;
 background:#1d5da8;border:2px solid #fff;cursor:nwse-resize;touch-action:none;
 box-shadow:0 1px 5px rgba(16,24,40,.4)}
.sig-grip::after{content:'';position:absolute;inset:7px;border-right:2px solid #fff;border-bottom:2px solid #fff}
.sig-grip:hover{background:#17385f}
.sig-size-read{font-size:13px;color:#44586e;font-weight:700;margin-left:auto}
@media (prefers-color-scheme:dark){.sig-size-read{color:#9fb2c6}}
.sign6-note{color:#657087;font-size:13.5px;margin:8px 0 0}
.sign6-field{display:flex;flex-direction:column;gap:5px;margin-bottom:14px}
.sign6-field>span{font-weight:700;font-size:14px}
.sign6-field input{font:inherit;padding:9px 11px;border:1px solid #dde4ec;border-radius:8px;background:#fff;width:100%}
.sign6-field small{color:#657087;font-size:12.5px}
.sign6-pad{border:1px solid #dde4ec;border-radius:8px;background:#fff;overflow:hidden}
.sign6-pad canvas{display:block;width:100%;height:auto;touch-action:none;cursor:crosshair}
.sign6-padrow{display:flex;align-items:center;gap:12px;margin-top:7px}
.sig-state{font-size:13.5px;color:#9d1c12;font-weight:700}
.sig-state.ready{color:#15603a}
.sign6-warn{background:#fff7dc;border:1px solid #ead274;color:#8a5b00;border-radius:9px;
 padding:10px 12px;font-size:14px;margin:0 0 14px}
.sign6-go{width:100%;padding:13px;font-size:16px}
.sign6-go[disabled]{opacity:.4;cursor:not-allowed}
.sign6-why{color:#657087;font-size:13.5px;margin:8px 0 0;text-align:center}
.sign6-skip{margin:12px 0 0;text-align:center;font-size:13.5px}
@media (max-width:980px){.sign6-grid{grid-template-columns:1fr}}
@media (prefers-color-scheme:dark){
 .lstep6{border-color:#6aa7e8;box-shadow:0 0 0 4px #15263d}
 .sign6-stage,.sign6-pad,.sign6-field input,.sign6-paper-head select{background:#172233;border-color:#2a3850;color:#e7edf5}
 .sign6-stage.no-picture{background:repeating-linear-gradient(45deg,#141d2b,#141d2b 12px,#1b2638 12px,#1b2638 24px)}
 .sig-box{border-color:#6aa7e8;background:rgba(106,167,232,.18);color:#cfe1f7}
 .sign6-note,.sign6-field small,.sign6-why{color:#9bacc2}
 .sig-state{color:#f09188}.sig-state.ready{color:#7cd3a2}
 .sign6-warn{background:#2c2512;border-color:#5c4a1c;color:#f0c868}
}

/* V2.235: the half-done tick, when it was signed but not sent */
.saved-tick.half{background:#fff7dc;color:#8a5b00;border-color:#ead274}
@media (prefers-color-scheme:dark){
 .saved-tick.half{background:#2c2512;color:#f0c868;border-color:#5c4a1c}
}

/* ===== V2.236 - asking a new broker for his details ================== */
.notice-popup.broker-popup{max-width:520px;text-align:left}
.broker-popup h3{margin:0 0 6px;font-size:20px}
.broker-why{margin:0 0 16px;color:#657087;font-size:14.5px;line-height:1.5}
.broker-field{display:flex;flex-direction:column;gap:5px;margin-bottom:13px}
.broker-field>span{font-weight:700;font-size:14px}
.broker-field input{font:inherit;padding:10px 12px;border:1px solid #dde4ec;border-radius:8px;
 background:#fff;width:100%}
.broker-field input:focus{outline:2px solid #1d5da8;outline-offset:1px;border-color:#1d5da8}
.broker-field small{color:#657087;font-size:12.5px}
.broker-warn{background:#fff6f5;border:1px solid #ee9188;color:#9d1c12;border-radius:9px;
 padding:10px 12px;font-size:14px;margin:0 0 12px}
.broker-buttons{display:flex;gap:9px;justify-content:flex-end;flex-wrap:wrap;
 border-top:1px solid #c9cfd8;padding-top:14px;margin-top:4px}
@media (prefers-color-scheme:dark){
 .broker-why,.broker-field small{color:#9bacc2}
 .broker-field input{background:#172233;border-color:#2a3850;color:#e7edf5}
 .broker-warn{background:#2c1614;border-color:#6b2a24;color:#f09188}
 .broker-buttons{border-top-color:#3b4a63}
}

/* V2.239: a link marked .btn is a BUTTON, everywhere in the program.
   There was never a rule for it, so every <a class="btn"> - the three on the
   Load saved popup, Step 6, the documents pages - came out as a plain purple
   word that did not look pressable. Real <button> elements are left exactly as
   they were; only links are touched. */
a.btn{display:inline-block;padding:10px 18px;border-radius:6px;font-weight:bold;
 font-size:14px;line-height:1.2;text-align:center;text-decoration:none;
 background:#eaf1fa;color:#1d5da8;border:1px solid #1d5da8;cursor:pointer}
a.btn:hover{background:#d8e6f7}
a.btn.primary{background:#1d5da8;color:#fff;border-color:#1d5da8}
a.btn.primary:hover{background:#17385f;border-color:#17385f}
a.btn.tiny{padding:5px 10px;font-size:12px}
a.btn:focus-visible{outline:3px solid #e0a561;outline-offset:2px}
@media (prefers-color-scheme:dark){
 a.btn{background:#16283c;color:#9cc4f0;border-color:#2f5d93}
 a.btn:hover{background:#1d3652}
}

/* V2.240: the Sign RateCon page shows ONE page, full size, and the signature
   box lives on it. The small second copy on the right is gone, so the page
   here is no longer a scrolling thumbnail - it is the thing you aim with. */
.esign-preview-card .sig-place-map{position:relative;max-height:none;overflow:visible}
.esign-preview-card .sig-place-map canvas{cursor:crosshair}
.esign-place-head{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:0 0 9px}
.esign-place-head .btn-secondary{padding:6px 10px!important;font-size:12.5px!important}
.esign-place-head .sig-size-read{font-size:13px;font-weight:800;color:#44586e;margin-right:auto}
.esign-preview-card .sig-box{position:absolute;left:60%;top:80%;width:150px;height:24px;
 border:2px dashed #1d5da8;background:rgba(29,93,168,.12);border-radius:8px;
 display:grid;place-items:center;text-align:center;font:700 10.5px/1.1 Arial;color:#1d5da8;
 cursor:grab;user-select:none;touch-action:none}
/* the LABEL is clipped, never the box: clipping the box hid the corner
   circle, and dragging it then moved the signature instead of sizing it */
.esign-preview-card .sig-box>span{overflow:hidden;white-space:nowrap;max-width:100%}
.esign-preview-card .sig-box.dragging{cursor:grabbing;background:rgba(29,93,168,.22);
 box-shadow:0 4px 14px rgba(16,24,40,.25)}
@media (prefers-color-scheme:dark){
 .esign-place-head .sig-size-read{color:#9fb2c6}
 .esign-preview-card .sig-box{border-color:#6aa7e8;background:rgba(106,167,232,.18);color:#cfe1f7}
}

/* V2.241: cancelling the load you have just saved. Red, and it asks first. */
.btn.danger,button.btn.danger{background:#fef3f2!important;color:#b42318!important;
 border:1px solid #f0b0a8!important;font-weight:800;border-radius:6px;padding:10px 16px;cursor:pointer}
.btn.danger:hover,button.btn.danger:hover{background:#fde3e0!important}
.btn.danger.solid,button.btn.danger.solid{background:#b42318!important;color:#fff!important;
 border-color:#b42318!important}
.btn.danger.solid:hover,button.btn.danger.solid:hover{background:#8f1c13!important}
.notice-popup.cancel-popup{max-width:450px;text-align:center}
.cancel-mark{width:52px;height:52px;margin:2px auto 12px;border-radius:50%;background:#fef3f2;
 color:#b42318;font-size:27px;font-weight:800;display:grid;place-items:center;border:2px solid #f0b0a8}
.cancel-popup h3{margin:0 0 6px;font-size:20px}
.cancel-line{margin:0 0 18px;font-size:15px;color:#172033}
.cancel-popup .saved-buttons form{margin:0}
@media (prefers-color-scheme:dark){
 .cancel-mark{background:#2a1413;color:#f08b7f;border-color:#5e2a24}
 .cancel-line{color:#e7edf5}
}

/* V2.242: look at the signed paper before anybody is offered it. */
.sigcheck-ask{border-left:5px solid #1d5da8;
 /* V2.245: the question sits UNDER the picture of the signed page - he looks
    at the paper first, then answers. It is only on his screen: nothing here
    touches the PDF. */
 background:#fff;box-shadow:0 6px 18px rgba(16,24,40,.12)}
.sigcheck-q b{display:block;font-size:17px;color:#17385f}
.sigcheck-q small{display:block;color:#5d6875;margin-top:4px;font-size:13.5px}
.sigcheck-buttons{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px}
@media (max-width:700px){.sigcheck-ask{padding:10px 12px}.sigcheck-buttons .btn{flex:1 1 100%}}
.sigcheck-paper{padding:12px}
.sigcheck-note{color:#5d6875;font-size:13px;margin:0 0 9px}
.sigcheck-img{display:block;width:100%;height:auto;border:1px solid #d5dbe3;border-radius:7px;background:#fff}
.sigcheck-pdf{width:100%;height:76vh;min-height:560px;border:1px solid #b8c2cf;border-radius:6px;background:#eef2f6}
/* V2.242: the sign button waits until the signature has been placed. */
.esign-ready{margin:10px 0 4px;font-size:13px;color:#8a3d08;background:#fff7ed;
 border:1px solid #e0a561;border-left-width:4px;border-radius:7px;padding:8px 11px}
.esign-ready.is-ready{color:#176b2c;background:#e9f6ed;border-color:#b7e0c4}
.esign-sign-btn[disabled]{opacity:.5;cursor:not-allowed}
@media (prefers-color-scheme:dark){
 .sigcheck-q b{color:#cfe1f7}
 .sigcheck-ask{background:#17212d;box-shadow:0 6px 18px rgba(0,0,0,.45)}
 .sigcheck-img,.sigcheck-pdf{border-color:#2a3850;background:#172233}
}

/* V2.243: the printed name and date, dragged on their own. */
.esign-preview-card .name-box{position:absolute;left:58%;top:84%;
 border:2px dashed #7a8899;background:rgba(122,136,153,.14);border-radius:7px;
 padding:5px 9px;font:700 11.5px/1.2 Arial;color:#44586e;white-space:nowrap;
 cursor:grab;user-select:none;touch-action:none}
.esign-preview-card .name-box.dragging{cursor:grabbing;background:rgba(122,136,153,.26);
 box-shadow:0 4px 14px rgba(16,24,40,.25)}
.esign-nameon{display:flex!important;gap:8px;align-items:flex-start;margin:10px 0 0;
 font-weight:400!important;font-size:12.5px;color:#5d6875}
.esign-nameon input{width:auto!important;margin:3px 0 0!important;flex:none}
@media (prefers-color-scheme:dark){
 .esign-preview-card .name-box{border-color:#7f8fa3;background:rgba(127,143,163,.2);color:#cfd8e3}
 .esign-nameon{color:#9fb2c6}
}

/* V2.247: a Load # that broker already has, marked where he typed it. */
#loadNumber.is-taken{border:2px solid #b42318!important;background:#fef3f2!important}
/* the zone each stop's clock time is in */
.stop-zone{min-width:92px}
.stop-zone select{height:34px;padding:0 6px;font-size:12px}
.stop-order-bad{background:#fef3f2;border:1px solid #f0b0a8;border-left-width:4px;border-radius:7px;
 padding:8px 11px;margin:8px 0 0;color:#b42318;font-size:12.5px;font-weight:700}
@media (prefers-color-scheme:dark){
 #loadNumber.is-taken{border-color:#f08b7f!important;background:#2a1413!important}
 .stop-order-bad{background:#2a1413;border-color:#5e2a24;color:#f08b7f}
}

/* V2.248: the spot on the signed paper the screen opens looking at. */
.sigcheck-hold{position:relative}
.sigcheck-here{position:absolute;left:0;width:100%;height:1px;pointer-events:none;opacity:0}

/* V2.252: the tick boxes, for every table in the program.
   Written once here so all of them look and behave the same. The column is
   pinned by its NAME, never by its position, so it can never take width from
   the columns beside it. */
th.pick-col,td.pick-col{width:26px!important;min-width:26px!important;max-width:26px!important;
 padding:6px 1px!important;text-align:center!important;overflow:visible!important}
.pick-box{width:16px!important;height:16px!important;margin:0!important;cursor:pointer;accent-color:#0b2f5b}
.pickbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;
 background:#f4f7fb;border:1px solid #cdd8e6;border-radius:8px;padding:8px 11px;margin:8px 0 6px}
.pickbar-what{font-weight:800;color:#0b2f5b;font-size:12px}
.pickbar-count{font-size:12px;font-weight:700;color:#334155;min-width:72px}
.pickbar .btn{margin:0}
.pickbar .btn.danger[disabled]{opacity:.45;cursor:not-allowed}
.pickbar-hint{font-size:11px;color:#5a6a7e;margin-left:auto}
@media(max-width:700px){.pickbar-hint{margin-left:0;width:100%}}
