/* GENERATED. Preserve the source order from ui-contract.json. */
/* SOURCE design-system.css */
/* UI-CONTRACT TOKENS BEGIN: generated by scripts/ui/build.py */
@media screen{
 :root{--ui-font:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Arial,sans-serif;--ui-text:14px;--ui-title:24px;--ui-section:18px;--ui-small:11px;--ui-table:12px;--ui-heading-size:11px;--ui-heading-weight:600;--ui-control:36px;--ui-control-text:12px;--ui-row:28px;--ui-row-action:24px;--ui-radius:8px;--ui-gap:6px;--ui-row-padding:2px 6px;--ui-touch-input:16px;--ui-add-bg:#242321;--ui-add-fg:#fff;--ui-control-padding:7px 10px;--ui-search-height:34px;--ui-search-line:22px;--ui-filter-gap:8px;--ui-module-heading-padding:22px 24px 18px;--ui-module-heading-mobile-padding:10px 20px;--ui-module-body-padding:24px;--ui-module-gap:24px;--ui-dialog-action-gap:8px;--ui-dialog-action-margin:16px;--ui-row-action-radius:6px;--ui-row-action-gap:5px;--ui-row-action-padding:3px;--ui-admin-dialog-radius:18px;--ui-admin-dialog-padding:30px;--ui-admin-dialog-field-gap:8px;--ui-admin-dialog-grid-gap:20px 16px;--ui-admin-dialog-footer-gap:8px;--ui-admin-module-header-height:60px;--ui-admin-module-inset:24px;--ui-admin-module-gap:var(--ui-title-action-gap);--ui-action-bg:#000;--ui-action-fg:#fff;--ui-title-action-gap:8px;}
}
@media screen and (pointer:coarse){
 :root{--ui-row:36px;--ui-row-action:32px;}
}
@media screen and (max-width:760px){
 :root{--ui-title:22px;--ui-admin-module-inset:14px;}
}
/* UI-CONTRACT TOKENS END */
/* Shared SCREEN rules. Printed/exported documents retain their paper typography. */
@media screen {
 html body{font-family:var(--ui-font);font-size:var(--ui-text);line-height:1.45}
 .app :is(button,input,select,textarea),.modal :is(button,input,select,textarea),dialog :is(button,input,select,textarea){font-family:var(--ui-font)}
 .app .page-head h1{font-family:var(--ui-font);font-size:var(--ui-title);font-weight:650;letter-spacing:normal;line-height:1.2}
 #content :is(.panel-head,.equipment-heading,.audio-doc-card>summary,.video-heading,.patch-heading,.section-heading) h2{font-family:var(--ui-font);font-size:var(--ui-section);font-weight:600;line-height:1.3}
 .app .help,.modal .help,dialog .help{font-family:var(--ui-font);font-size:var(--ui-small);font-weight:400;line-height:1.45}
 .app .btn,.modal .btn,dialog .btn{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:var(--ui-control);height:var(--ui-control);padding:7px 10px;font-size:12px;font-weight:600;line-height:1.2;border-radius:var(--ui-radius,8px);white-space:nowrap}
 .app :is(.toolbar,.table-filter-bar,.head-actions) .btn{font-size:12px;font-weight:600}
 .app .topbar .top-actions{align-items:center;flex-wrap:nowrap;gap:8px;min-width:0}
 :is(#content,.light-label-dialog,.vehicle-history,.radio-handover-dialog,.cargo-pdf-options,.staff-dialog,.project-document-dialog,:is(.personnel-shifts-dialog,.output-history-dialog,.free-text-modal)) :is(.table,.data-table,.patch-table,.personnel-total-table)>tbody>tr:not(.day-group-row):not(.material-order-heading):not(.trucking-day-row):not(.material-import-row):not(.catering-day-heading)>:is(td,th[scope=row]){box-sizing:border-box;height:var(--ui-row);padding:var(--ui-cell-padding,var(--ui-row-padding,2px 6px));font-family:var(--ui-font);font-size:var(--ui-table);font-weight:400;line-height:16px;vertical-align:middle}
 :is(#content,.light-label-dialog,.vehicle-history,.radio-handover-dialog,.cargo-pdf-options,.staff-dialog,.project-document-dialog,:is(.personnel-shifts-dialog,.output-history-dialog,.free-text-modal)) :is(.table,.data-table,.patch-table,.personnel-total-table)>tbody :is(.btn,.iconbtn,.action-button){height:var(--ui-row-action);min-height:var(--ui-row-action);padding:2px 5px;font-size:11px;line-height:16px;min-width:var(--ui-row-action)}
 :is(#content,.light-label-dialog,.vehicle-history,.radio-handover-dialog,.cargo-pdf-options,.staff-dialog,.project-document-dialog,:is(.personnel-shifts-dialog,.output-history-dialog,.free-text-modal)) :is(.table,.data-table,.patch-table,.personnel-total-table)>tbody :is(.table-input,.audio-doc-cell-input,.trucking-inline-input){height:24px;min-height:24px;padding:2px 5px;font-size:var(--ui-table);font-weight:400;line-height:18px}
 :is(#content,.light-label-dialog,.vehicle-history,.radio-handover-dialog,.cargo-pdf-options,.staff-dialog,.project-document-dialog,:is(.personnel-shifts-dialog,.output-history-dialog,.free-text-modal)) :is(.table,.data-table,.patch-table,.personnel-total-table)>tbody :is(p,small){margin-block:0}
 /* Booking grid rows use the same action size as personnel table rows. */
 #content .staff-booking-grid .staff-timeline-row .btn{height:var(--ui-row-action);min-height:var(--ui-row-action);padding:2px 5px;font-size:11px;line-height:16px}
 /* Preserve the intentional gap between mail titles/details and subjects/recipients. */
 #content .issue-mail-table td>.issue-mail-detail,#content .issue-mail-history td>.issue-mail-recipient{margin-top:8px}
 #content :is(.gantt-table,.build-table) :is(td,th[scope=row]){font-size:var(--ui-table)}
 .issue-attention-button{position:relative;width:36px}
 .issue-attention-dot{position:absolute;top:5px;right:5px;width:8px;height:8px;background:var(--red,#a34b40);border-radius:50%;box-shadow:0 0 0 2px #fff}
 .issue-attention-dot[hidden]{display:none}
 .issue-attention-dialog{width:min(480px,calc(100vw - 28px));max-height:80dvh;box-sizing:border-box;overflow:auto;padding:20px;border:1px solid var(--line,#e4e0d8);border-radius:16px;color:var(--ink,#242321);background:var(--surface,#fff);font:14px/1.45 var(--ui-font)}
 .issue-attention-dialog::backdrop{background:#0005}
 .issue-attention-dialog header{display:flex;align-items:center;justify-content:space-between;gap:12px}
 .issue-attention-dialog h2{margin:0;font-size:18px;font-weight:600}
 .issue-attention-items{display:grid;gap:8px}
 .issue-attention-items a{display:block;padding:10px;border:1px solid var(--line,#e4e0d8);border-radius:8px;text-decoration:none}
 .issue-attention-items small{display:block;margin-top:4px;color:var(--muted,#706d67);font-size:11px}
 .push-device-label{font-size:12px;color:var(--muted,#706d67)}
}
@media screen and (pointer:coarse){
 :is(#content,.light-label-dialog,.vehicle-history,.radio-handover-dialog,.cargo-pdf-options,.staff-dialog,.project-document-dialog,:is(.personnel-shifts-dialog,.output-history-dialog,.free-text-modal)) :is(.table,.data-table,.patch-table,.personnel-total-table)>tbody :is(.table-input,.audio-doc-cell-input,.trucking-inline-input){font-size:16px;height:30px;min-height:30px}
}
@media screen and (max-width:760px){
 .app .topbar .top-actions{gap:6px}
}
/* Header appearance and compact controls live in header-controls.css. */
@media print{.issue-attention-button,.issue-attention-dialog{display:none!important}}
@media screen{
 /* Shared module headings; project-bridge.css keeps only their paper rules. */
 .equipment-heading{padding:var(--ui-module-heading-padding,22px 24px 18px);border-bottom:1px solid var(--line);background:var(--surface-alt,#faf9f6)}
 .equipment-heading h2{margin:0 0 6px;letter-spacing:-.025em}
 .equipment-heading p{font-size:var(--ui-table,12px);line-height:1.5;margin:0;color:var(--muted)}
 @media(max-width:600px){.equipment-heading{padding:var(--ui-module-heading-mobile-padding,10px 20px)}}
.app [hidden],dialog [hidden],.modal [hidden]{display:none!important}}
@media screen and (max-width:760px){.app .topbar [data-project-action="projects"]{width:36px;min-width:36px;padding:0;font-size:0}.app .topbar [data-project-action="projects"]::before{font-size:17px}}
@media screen{
 /* An explicit hotel column prevents the fixed layout from wrapping its text into a zero-width column. */
 #content .hotel-booking-table .hotel-col-hotel{width:170px}
 #content .hotel-booking-toggle{width:var(--ui-row-action);height:var(--ui-row-action);min-height:var(--ui-row-action);font-size:12px}
 /* A timing cell contains time + H/F/M/A/O, so it needs two compact content rows. */
 #content .personnel-overall-cell{min-height:0;height:auto;gap:3px;grid-template-rows:auto auto;align-content:start}
 #content .personnel-overall-cell.is-compact{grid-template-rows:auto;gap:0}
 #content .personnel-overall-marker{grid-template-rows:auto;grid-template-columns:1fr 1fr;min-height:22px;padding:1px 2px}
}
@media screen and (pointer:coarse){#content .personnel-overall-marker{min-height:32px}}
@media screen{
 #content .gantt-row{min-height:var(--ui-row);padding-block:2px}
 #content .gantt-cell{font-family:var(--ui-font);font-size:12px;line-height:16px;font-weight:400}
 #content .gantt-actions>button{height:var(--ui-row-action);min-height:var(--ui-row-action);min-width:var(--ui-row-action);padding:2px}
}
@media screen{
 .app :is(.tag,.badge){font-family:var(--ui-font);font-size:11px;font-weight:500;line-height:1.2}
 .app .nav button{font-family:var(--ui-font);font-size:12px;font-weight:500}
 .app .equipment-card :is(input,select,textarea){font-family:var(--ui-font);font-size:14px;font-weight:400}
}
@media screen{#content :is(.table,.data-table,.patch-table)>tbody>tr>td[colspan]{font-weight:600}}
@media screen and (min-width:761px){
 /* Reserve enough width for both time endpoints and all five markers per day. */
 #content .personnel-total-table{width:max(100%,calc(680px + 136px * var(--personnel-date-count,1)));min-width:820px}
 #content .personnel-total-table .personnel-col-day{width:136px}
}
@media screen{
 .file-format-buttons{display:inline-flex;align-items:center;flex-wrap:nowrap;gap:var(--ui-title-action-gap);flex:none}
 .file-direction-options{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding-block:8px}
 .file-direction-options>.btn{min-width:120px}
}
@media screen and (max-width:760px){
 .file-format-buttons [data-file-format=csv][data-file-import=false]{display:none}
 .file-direction-options>.btn{flex:1;min-width:0}
}
@media screen{.modal:has(.file-direction-options){width:min(440px,calc(100vw - 28px));max-width:440px}}
@media screen and (max-width:760px){
 .app .topbar [data-project-action="projects"]::before{content:none}
 .app .topbar .project-back-label{display:none}
}

@media screen{
 #content .users-table{table-layout:auto;min-width:1100px}
 #content .users-table .last-login{white-space:nowrap}
 #content .data-table .actions{flex-wrap:nowrap;white-space:nowrap;width:max-content;margin-left:auto}
 .permission-legend{margin:12px 0;font-size:var(--ui-table);line-height:1.45}
 .permission-legend>div{display:grid;grid-template-columns:minmax(150px,210px) 1fr;gap:12px;padding:7px 0;border-bottom:1px solid var(--line)}
 .permission-legend dt{font-weight:600}.permission-legend dd{margin:0}
 @media(max-width:600px){.permission-legend>div{grid-template-columns:1fr;gap:3px}}
}

@media screen{
 .head-actions:has(>.file-format-buttons){flex:1;min-width:0;display:flex;align-items:center;flex-wrap:wrap}
 .equipment-heading .toolbar:has(>.file-format-buttons){flex:1;min-width:0;display:flex;align-items:center;flex-wrap:wrap}
 :is(.head-actions,.equipment-heading .toolbar)>.file-format-buttons{margin-left:auto}
}

/* Grouped timing: continuous identity columns, stronger horizontal row guides. */
@media screen{
 :root{--ui-row-divider:#d1cbc0}
 #content .personnel-total-table>tbody>tr>:is(td,th){border-bottom:1px solid var(--ui-row-divider)}
 #content .personnel-total-table>tbody>tr>:nth-child(-n+3),#content .personnel-total-table>thead>tr>:nth-child(-n+3){border-right:0}
 /* Position labels in the separate crew list need a constrained block too.
    nowrap on personnel editors does not cover these plain-text table cells. */
 #content .crew-table .crew-position-label{display:block;width:100%;min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;overflow-wrap:normal}
 #content :is(.personnel-overall-edit[data-field=role],.personnel-inline-edit[data-field=role]){display:block;width:100%;min-width:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;overflow-wrap:normal;text-align:left}
 #content .personnel-total-name>div{min-width:0}
 #content .personnel-gantt-row{border-bottom:1px solid var(--ui-row-divider)}
 #content .personnel-gantt-row>.gantt-cell{border-right:0}
 #content .personnel-gantt-row>.personnel-inline-edit[data-field=role]{min-height:var(--ui-row)}
 #content .personnel-gantt .personnel-plain-head{white-space:nowrap;justify-content:center}
 #content .library-tools>.file-format-buttons{margin-left:auto}
}

@media screen and (min-width:761px){
 #content .personnel-gantt-row{min-height:32px;padding:2px 0}
 #content .personnel-gantt-row :is(.gantt-cell,.personnel-flag-cell,.personnel-drag-cell){min-height:28px}
 #content .personnel-gantt-row .personnel-drag-handle{height:24px}
 #content .personnel-gantt-row .personnel-static-cell[data-field=title]{display:block;height:auto;padding:3px 4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
}

@media screen{.lang-toggle>button[hidden],.onsite-language-switch>button[hidden]{display:none!important}}

/* Shared square add action, including dark mode; accessible label stays on the button. */
@media screen{
 :is(.app,.onsite-admin,.modal,dialog) button.btn.primary:is(.action-add,.ui-icon-primary){box-sizing:border-box;width:36px;min-width:36px;max-width:36px;height:36px;min-height:36px;padding:8px;flex:0 0 36px;background:var(--ui-add-bg,#242321);color:var(--ui-add-fg,#fff);border-color:var(--ui-add-bg,#242321);border-radius:8px}
 :is(.app,.onsite-admin,.modal,dialog) button.btn.primary:is(.action-add,.ui-icon-primary):hover:not(:disabled){background:var(--ui-add-bg,#242321);color:var(--ui-add-fg,#fff)}
 :is(.app,.onsite-admin,.modal,dialog) button.btn.primary:is(.action-add,.ui-icon-primary):focus-visible{outline:2px solid var(--brand-deep);outline-offset:3px}
 :is(.app,.onsite-admin,.modal,dialog) button.action-add[hidden]{display:none!important}
 .action-add svg{display:block;flex:none;width:18px;height:18px;pointer-events:none}
 .library-add-options{display:grid;gap:8px}.library-add-options>.btn{justify-content:flex-start;width:100%}
 #content .shitlist-heading{align-items:center;flex-wrap:wrap}
 #content .shitlist-heading>.toolbar{margin-left:auto;flex-wrap:nowrap}
 #content .todo-status-filters{align-items:center}
 #content .todo-status-filters>.filter-chip{box-sizing:border-box;min-height:36px;height:36px;display:inline-flex;align-items:center}
 #content .quick-entry .action-add{justify-self:end;grid-column:auto}
}
@media print{.action-add{display:none!important}}

/* Explicit normal form controls inside nested table editors must not inherit
   compact row-action dimensions. New modules may opt in without changing icons. */
@media screen{
 #content .table [data-ui-control="standard"].btn,.modal [data-ui-control="standard"].btn{height:var(--ui-control);min-height:var(--ui-control);padding:7px 10px;font-size:12px;line-height:1.2}
 #content [data-ui-input="standard"],.modal [data-ui-input="standard"]{height:var(--ui-control);min-height:var(--ui-control)}
}
@media screen and (pointer:coarse){#content [data-ui-input],.modal [data-ui-input]{font-size:16px}}

/* Page actions stay beside short titles; wider toolbars wrap together and align right. */
@media screen and (max-width:760px){
 .app .page-head:has(>.head-actions>.action-add){display:flex;align-items:center;flex-wrap:wrap;column-gap:12px;row-gap:10px}
 .app .page-head:has(>.head-actions>.action-add)>.head-actions{display:flex;align-items:center;justify-content:flex-end;flex:1 0 auto;gap:8px;min-width:0;width:auto;height:auto;min-height:36px;overflow:visible}
 .app .page-head:has(>.head-actions>.action-add)>.head-actions>.file-format-buttons{margin-left:0}
}

@media screen{
 .page-head>.head-actions:has(>details){overflow:visible;height:auto;min-height:36px}
}

/* Screen-wide UI contract. Paper layouts retain their own typography and sizing. */
@media screen{
 :root{--ui-regular:400;--ui-medium:500;--ui-bold:600;--ui-control-height:32px;--ui-body-size:12px;--ui-secondary-size:11px;--ui-title-size:14px;--mobile-chrome-bg:var(--surface,#fff)}
 #content{font-size:var(--ui-body-size);font-weight:var(--ui-regular);color:var(--ink)}
 #content :where(*){font-weight:inherit}
 #content :is(p,td,li,label,input,textarea,select){font-weight:var(--ui-regular)}
 #content :is(h1,h2,h3,h4,strong,b,th){font-weight:var(--ui-bold)}
 #content :is(button,.btn,summary,.tag,.badge):not(.table-name-open){font-weight:var(--ui-medium)}
 #content :is(.help,.muted,small){color:var(--muted);font-size:var(--ui-secondary-size);font-weight:var(--ui-regular)}
 #content :is(.equipment-heading,.section-head,.panel-head){align-items:start}
 #content :is(.equipment-heading,.section-head,.panel-head)>:is(.toolbar,.library-tools,.head-actions){margin-top:0;margin-bottom:0;align-items:center;justify-content:flex-end}
 #content :is(.shitlist-actions,.row-actions,.trucking-actions,.catering-actions,.crew-row-actions){align-items:center}
 .onsite-compact-select{position:relative;display:inline-flex;align-items:center;box-sizing:border-box;min-width:0;max-width:100%;height:var(--ui-control-height);min-height:var(--ui-control-height);padding:0 25px 0 9px;border:1px solid var(--line);border-radius:8px;background:var(--surface,#fff);color:var(--ink);font-size:12px;font-weight:var(--ui-medium)}
 .onsite-compact-select>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;pointer-events:none}
 .onsite-compact-select::after{content:'⌄';position:absolute;right:8px;top:50%;transform:translateY(-55%);pointer-events:none;color:var(--muted)}
 .onsite-compact-select>select{position:absolute!important;inset:0!important;opacity:0!important;width:100%!important;height:100%!important;min-height:0!important;margin:0!important;cursor:pointer;font-size:16px!important}
 .onsite-compact-select:focus-within{outline:2px solid var(--brand);outline-offset:2px}
 .onsite-compact-select:has(select.onsite-field-invalid){outline:2px solid var(--red)}
}
@media screen and (max-width:600px){
 html{scrollbar-gutter:auto;-webkit-text-size-adjust:100%;text-size-adjust:100%}
 .app{--ui-control-height:32px}
 .app>.sidebar{height:0!important;min-height:0!important;padding:0!important;margin:0!important;overflow:visible!important}
 .app>.sidebar>.brand{display:none!important}
 .app>.main{padding-top:calc(var(--onsite-chrome-height,100px) + var(--onsite-local-height,0px));min-width:0;margin-left:0!important}
 html.onsite-local .app{--onsite-local-height:24px}
 html.onsite-local body{padding-top:0}
 .onsite-mobile-header{position:fixed;will-change:transform;backface-visibility:hidden;z-index:1090;left:0;top:0;width:var(--onsite-visual-width,100%);box-sizing:border-box;background:var(--mobile-chrome-bg);color:var(--ink);transform-origin:0 0;transform:translate3d(var(--onsite-header-x,0px),calc(var(--onsite-header-y,0px) + var(--onsite-local-height,0px) * var(--onsite-visual-inverse,1)),0) scale(var(--onsite-visual-inverse,1));padding-top:env(safe-area-inset-top);border-bottom:1px solid var(--line)}
 .onsite-mobile-header>.brand{display:flex;align-items:center;justify-content:center;text-align:center;height:44px;box-sizing:border-box;padding:4px 12px 0;margin:0;border:0;background:transparent;text-decoration:none;color:var(--muted)}
 .onsite-mobile-header .brand>div{width:auto;max-width:100%}
 .onsite-mobile-header .brand .habegger-logo{display:block;width:120px;max-width:100%;height:auto;margin:0 auto;padding:0;background:transparent}
 .onsite-mobile-header .brand small{display:block;font-size:8px;line-height:1.1;font-weight:400;letter-spacing:.06em;margin-top:2px;color:var(--muted)}
 .app .onsite-mobile-header>.topbar{position:static!important;min-height:48px!important;height:48px!important;padding:4px 12px 8px!important;background:var(--mobile-chrome-bg)!important;border:0!important;box-sizing:border-box;backdrop-filter:none}
 .app .onsite-mobile-header .top-actions{height:36px;align-items:center;justify-content:space-between;gap:4px}
 .app .onsite-mobile-header :is(.breadcrumb,.crumb,.mobile-head){display:none!important}
 #bottomNav.bottom-nav,.onsite-admin .sidebar .nav{position:fixed!important;will-change:transform;backface-visibility:hidden;inset:0 auto auto 0!important;z-index:1100;width:var(--onsite-visual-width,100%);box-sizing:border-box;background:var(--mobile-chrome-bg)!important;backdrop-filter:none;transform-origin:0 0;transform:translate3d(var(--onsite-visual-x,0px),var(--onsite-visual-bottom,100dvh),0) scale(var(--onsite-visual-inverse,1)) translateY(-100%)}
 .onsite-admin .sidebar .nav{grid-template-columns:repeat(5,minmax(0,1fr))}
 .app .content{min-width:0;max-width:100%;box-sizing:border-box;padding-top:12px}
 #content .page-head{display:flex!important;align-items:center!important;flex-wrap:wrap;justify-content:space-between;gap:var(--ui-title-action-gap)!important;min-height:32px!important;margin-bottom:12px!important;grid-template-rows:none}
 #content .page-head>div:first-child{flex:1 1 auto;min-width:0}
 #content .page-head h1{font-size:var(--ui-title)!important;line-height:1.3;font-weight:600;overflow-wrap:anywhere}
 #content .page-head>.head-actions{flex:0 1 auto!important;min-width:0;width:auto!important;height:auto!important;min-height:32px!important;gap:5px;justify-content:flex-end!important;margin:0 0 0 auto!important;overflow:visible;flex-wrap:wrap}
 #content .page-head>.head-actions .btn{flex:0 0 auto!important}
 #content :is(.equipment-heading,.section-head,.panel-head){display:flex;align-items:start;justify-content:space-between;flex-wrap:wrap;gap:6px 8px;padding-top:10px;padding-bottom:10px}
 #content :is(.equipment-heading,.section-head,.panel-head)>div:first-child{min-width:0;flex:1 1 100px}
 #content :is(.equipment-heading,.section-head,.panel-head) :is(h2,h3){font-size:14px!important;line-height:32px!important;margin:0!important}
 #content :is(.equipment-heading,.section-head,.panel-head) p{font-size:11px;line-height:1.4;margin:2px 0 0!important;color:var(--muted)}
 #content :is(.equipment-heading,.section-head,.panel-head)>:is(.toolbar,.library-tools,.head-actions){flex:0 1 auto;max-width:100%;gap:5px;flex-direction:row;flex-wrap:wrap;align-self:start;justify-content:flex-end;margin:0!important}
 #content :is(.toolbar,.table-filter-bar,.head-actions){flex-direction:row;align-items:center;gap:6px;flex-wrap:wrap}
 #content :is(.btn,button.select,summary.btn,.toolbar select,.table-filter-bar select,.shitlist-status select,.toolbar input:not([type=checkbox]):not([type=radio]):not([type=file]),.table-filter-bar input:not([type=checkbox]):not([type=radio])){box-sizing:border-box;margin-block:0;padding-top:4px;padding-bottom:4px;line-height:22px}
 #content .btn{font-size:12px!important;padding-inline:8px}
 #content .action-add{width:32px;min-width:32px;padding:6px}
 #content :is(.shitlist-actions,.row-actions,.catering-actions,.crew-row-actions,.trucking-actions)>.btn{width:32px;min-width:32px;padding:5px}
 #content .shitlist-status{align-self:center}
 #content .shitlist-status>.onsite-compact-select{width:100%}
 #content .shitlist-row{align-items:center}
 #content :is(.equipment-heading,.section-head,.panel-head) .project-export-buttons{gap:5px;flex-wrap:nowrap}
 .onsite-compact-select{max-width:100%}
}
@media print{.onsite-mobile-header{display:none!important}}

@media screen and (max-width:600px){
 #content .material-more-actions>summary{font-size:0!important;width:32px;min-width:32px;padding:4px;justify-content:center}
 #content .material-more-actions>summary::before{content:'⋯';font-size:18px;line-height:22px}
 #content .material-more-actions>summary>span{display:none}
}

@media screen and (max-width:600px){
 #content .shitlist-heading{padding:0;gap:6px 8px;margin-bottom:12px;flex-direction:row;align-items:start}
 #content .shitlist-heading>div:first-child{flex:1 1 80px}
 #content .shitlist-heading>.toolbar{flex:0 0 auto;align-self:start;margin:0 0 0 auto}
 #content .shitlist-heading>.toolbar>button[data-compact-action]{width:32px;min-width:32px;padding:5px}
 #content .shitlist-heading>.toolbar>button[data-compact-action]>svg{display:block;width:16px;height:16px}
 #content [data-layout-module] .equipment-heading>.toolbar{justify-content:flex-end}
}

@media screen and (max-width:600px){
 .more-menu.mobile-nav-menu,.onsite-admin .admin-mobile-more:not([hidden]){position:fixed;inset:0 auto auto 0;width:calc(var(--onsite-visual-width,100vw) - 20px);max-height:calc(var(--onsite-visual-height,100dvh) - var(--onsite-footer-height,68px) - 16px);transform-origin:0 0;transform:translate(calc(var(--onsite-visual-x,0px) + 10px * var(--onsite-visual-inverse,1)),calc(var(--onsite-visual-bottom,100dvh) - (var(--onsite-footer-height,68px) + 8px) * var(--onsite-visual-inverse,1))) scale(var(--onsite-visual-inverse,1)) translateY(-100%)}
}

@media screen{.onsite-compact-select:has(select:disabled){opacity:.5;cursor:default}}

@media screen and (max-width:600px){.onsite-admin .sidebar .nav .admin-dock-label{width:100%;max-width:100%;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:10px;line-height:1.2}}

@media screen{
 #content :is(.gantt-cell,.crew-position-label,.shitlist-title h3,.material-description,.audio-doc-cell-input,.trucking-inline-input,.personnel-total-name strong,.todo-table strong){color:var(--ink)}
 #content :is(.shitlist-meta,.shitlist-location span,.actual-work-plan,.personnel-no-shift,.material-position-id){color:var(--muted)}
}
@media screen and (max-width:600px){
 #content [data-layout-module] .equipment-heading>.toolbar>.file-format-buttons{margin-left:0}
 #content :is(.toolbar,.table-filter-bar,.personnel-toolbar,.timing-toolbar) .search{display:flex;align-items:center;gap:6px;box-sizing:border-box;height:32px;min-height:32px;padding:0 9px!important;border:1px solid var(--line);border-radius:8px;background:var(--surface,#fff)}
 #content :is(.toolbar,.table-filter-bar,.personnel-toolbar,.timing-toolbar) .search>span{position:static!important;flex:none;font-size:14px;line-height:1}
 #content :is(.toolbar,.table-filter-bar,.personnel-toolbar,.timing-toolbar) .search>input{display:block;flex:1;min-width:0;width:100%;height:30px!important;min-height:30px!important;padding:3px 0!important;border:0!important;border-radius:0;background:transparent;line-height:24px}
 .onsite-admin .onsite-mobile-header .top-actions{width:100%;justify-content:center;gap:8px}
 .onsite-admin .sidebar .nav :is([data-view=users],[data-view=roles])>.admin-dock-label{display:none}
 .onsite-admin .sidebar .nav .admin-dock-short{display:block;width:100%;font-size:10px;line-height:1.2}
}
@media screen and (min-width:601px){.admin-dock-short{display:none}}
@media screen and (max-width:600px){
 .more-menu.mobile-nav-menu{z-index:1101}
 #modalBackdrop.modal-backdrop{z-index:1400}
}
@media screen and (max-width:600px){
 .onsite-mobile-header>.brand{height:52px;padding:8px 12px 4px}
 .app .onsite-mobile-header>.topbar{height:56px!important;min-height:56px!important;padding:8px 12px 12px!important}
 #content .personnel-view-controls{display:flex;flex-wrap:nowrap;gap:5px;margin-bottom:10px}
 #content .personnel-view-controls>.segmented{flex:1 1 0;min-width:0;width:auto;display:flex;margin:0;padding:2px;min-height:32px}
 #content .personnel-view-controls>.segmented>button{min-width:0;flex:1 1 auto;font-size:11px;padding:6px 2px;white-space:nowrap}
 #content .personnel-view-controls .mobile-timing-toggle{margin:0!important}
 #content .personnel-toolbar{display:flex!important;flex-wrap:wrap;gap:7px!important}
 #content .personnel-toolbar>.personnel-search-wrap{flex:1 1 100%;width:100%}
 #content .personnel-filter-actions{display:flex;align-items:center;justify-content:flex-end;gap:6px;width:100%;flex-wrap:nowrap}
 #content .personnel-filter-actions>.btn{font-size:11px!important;padding-inline:7px;white-space:nowrap}
 #content .timing-toolbar.build-filter-toolbar{display:grid;grid-template-columns:auto minmax(50px,1fr) auto auto;align-items:center;gap:4px!important}
 #content .timing-toolbar.build-filter-toolbar>.mobile-timing-toggle{display:flex;margin:0!important;min-width:0;padding:2px;min-height:32px;grid-column:1!important;grid-row:1!important}
 #content .timing-toolbar.build-filter-toolbar>.mobile-timing-toggle>button{font-size:11px;padding:5px 4px}
 #content .timing-toolbar.build-filter-toolbar>.timing-search{grid-column:2!important;grid-row:1!important;min-width:0;width:100%}
 #content .timing-toolbar.build-filter-toolbar>.mobile-date-filter{display:block;margin:0;justify-self:end;grid-column:3!important;grid-row:1!important}
 #content .timing-toolbar.build-filter-toolbar>.filter-reset{justify-self:end;font-size:11px!important;padding-inline:6px;grid-column:4!important;grid-row:1!important;min-width:0;width:auto}
 #content .timing-toolbar.build-filter-toolbar .column-menu>summary{height:32px!important;min-height:32px!important;box-sizing:border-box;padding:4px!important}
 #content .shitlist-panel,#content .todo-toolbar,#content .todo-status-filters,#content .todo-table{background:var(--surface,#fff)}
 #content .shitlist-panel .shitlist-heading{background:transparent}
 #content .todo-toolbar>.action-add{margin-left:auto}
 #content .library-tools>button[data-library-compact]{width:32px;min-width:32px;padding:5px}
 #content .library-tools>button[data-library-compact]>svg{width:16px;height:16px;display:block}
}
@media screen and (max-width:360px){
 #content .timing-toolbar.build-filter-toolbar{grid-template-columns:1fr auto auto}
 #content .timing-toolbar.build-filter-toolbar>.timing-search{grid-column:1/-1!important;grid-row:1!important}
 #content .timing-toolbar.build-filter-toolbar>.mobile-timing-toggle{grid-column:1!important;grid-row:2!important;justify-self:start}
 #content .timing-toolbar.build-filter-toolbar>.mobile-date-filter{grid-column:2!important;grid-row:2!important}
 #content .timing-toolbar.build-filter-toolbar>.filter-reset{grid-column:3!important;grid-row:2!important}
}
@media screen and (min-width:601px){#content .timing-toolbar.build-filter-toolbar{display:flex;align-items:center}#content .timing-toolbar.build-filter-toolbar>.mobile-timing-toggle{display:none}#content .timing-toolbar.build-filter-toolbar>.timing-search{flex:1;min-width:0}#content .timing-toolbar.build-filter-toolbar>.mobile-date-filter{display:block;margin-left:auto}}
.onsite-action-label{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden;clip-path:inset(50%);white-space:nowrap}

/* Shared control refinements: plain resets, compact icons and single-row filters. */
@media screen{
 button.plain-filter-reset::before,button.plain-filter-reset::after{display:none!important;content:none!important}
 #content .personnel-toolbar{display:flex!important;flex-wrap:nowrap;align-items:center}
 #content .personnel-toolbar>.personnel-search-wrap{flex:1 1 0!important;min-width:45px;width:auto}
 #content .personnel-filter-actions{display:flex;flex:0 0 auto;width:auto;align-items:center;justify-content:flex-end;gap:6px;flex-wrap:nowrap}
 #content .personnel-filter-actions>.btn{white-space:nowrap}
 #content .personnel-extras-toggle{display:inline-flex;align-items:center;justify-content:center;gap:3px;white-space:nowrap!important;padding-inline:8px}
 #content :is(.crew-hierarchy-button,.emergency-edit-button){display:inline-flex;align-items:center;justify-content:center;width:36px;min-width:36px;padding:6px}
 #content .shitlist-toolbar{display:flex;align-items:center;gap:6px;flex-wrap:nowrap}
 #content .shitlist-toolbar>.search{flex:1 1 auto;min-width:45px}
 #content .shitlist-toolbar>.search>input{width:100%;min-width:0}
 #content .shitlist-toolbar>.filter-reset{margin-left:auto;flex-shrink:0;white-space:nowrap}
 #content .shitlist-heading{display:grid!important;grid-template-columns:minmax(65px,1fr) auto;align-items:start;gap:8px}
 #content .shitlist-heading>.toolbar{display:flex!important;flex-wrap:nowrap!important;align-items:center;justify-content:flex-end;max-width:none;width:auto}
 #content .shitlist-heading>.toolbar>.btn{flex-shrink:0}
 #content .trucking-rank-heading{width:32px;min-width:32px;max-width:32px;padding-inline:4px}
 #content .trucking-rank-heading>button{width:24px;min-width:24px;max-width:24px;padding:0;height:24px}
}
@media screen and (max-width:600px){
 #content .personnel-toolbar>.personnel-search-wrap{flex:1 1 0!important;width:auto!important;min-width:40px}
 #content .personnel-filter-actions{width:auto;gap:4px}
 #content .personnel-filter-actions>.btn{font-size:11px!important;padding-inline:5px}
 #content .personnel-extras-toggle{gap:1px;padding-inline:4px!important}
 #content .personnel-extras-toggle svg{width:14px;height:14px}
 #content .crew-toolbar{display:flex!important;flex-wrap:wrap}
 #content .crew-toolbar>.search{flex:1 1 100%}
 #content .crew-toolbar>.crew-day-filter{flex:1 1 auto;width:auto}
 #content .crew-toolbar>.crew-hierarchy-button{flex:0 0 32px;width:32px;min-width:32px;grid-column:auto}
 #content .emergency-edit-button{width:32px;min-width:32px}
 .catering-mobile-card{display:flex;flex-direction:column}
 .catering-mobile-bottom{display:flex;align-items:flex-end;justify-content:space-between;gap:8px;margin-top:auto}
 .catering-mobile-bottom>div:first-child{min-width:0;flex:1}
 .catering-mobile-bottom>.catering-actions{flex-shrink:0;margin:0!important;padding:0!important;border:0!important}
 .onsite-admin .admin-mobile-more:not([hidden]){grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;padding:10px;border-radius:12px;box-sizing:border-box;overflow:auto}
 :is(.more-menu .mobile-nav-destination,.onsite-admin .admin-mobile-more>button:not([data-admin-menu-reset])){border:0!important;border-radius:8px!important;background:var(--mobile-nav-bg,var(--surface-alt))!important;color:var(--mobile-nav-ink,var(--ink))!important;min-height:66px;box-sizing:border-box}
 .onsite-admin .admin-mobile-more>button:not([data-admin-menu-reset]){display:grid;justify-items:center;align-content:center;gap:6px;padding:11px 4px;font-size:10px;line-height:1.25}
 .onsite-admin .admin-mobile-more>button:not([data-admin-menu-reset]) .navicon{display:grid;place-items:center}
 .onsite-admin .admin-mobile-more>button:not([data-admin-menu-reset]) .navicon svg{width:15px;height:15px}
 :is(.more-menu .mobile-nav-destination,.onsite-admin .admin-mobile-more>button:not([data-admin-menu-reset])):is(:hover,:focus-visible){background:var(--mobile-nav-active-bg,var(--brand-soft))!important;color:var(--mobile-nav-ink,var(--brand-deep))!important}
}

@media screen and (max-width:600px){:is(.more-menu .mobile-nav-destination,.onsite-admin .admin-mobile-more>button:not([data-admin-menu-reset])).active{background:var(--mobile-nav-active-bg,var(--brand-soft))!important;color:var(--mobile-nav-ink,var(--brand-deep))!important}}

@media screen and (max-width:600px){.more-menu.mobile-nav-menu>.onsite-push-settings{border-radius:8px!important}}

/* Dark application chrome is independent of the selected content theme. */
@media screen{
 .onsite-admin .topbar,.onsite-admin .onsite-mobile-header{--surface:#202224;--surface-alt:#2d3032;--ink:#f0efeb;--muted:#c5c3bc;--line:#484b4d;--brand-soft:#3b362c;--brand-deep:#e0c891;--mobile-chrome-bg:#202224;background:var(--surface);color:var(--ink);border-color:var(--line)}
 .app .topbar :is(.breadcrumb,.crumb){color:var(--muted)}
 .app .topbar :is(.breadcrumb b,.crumb b){color:var(--ink)}
}
@media screen and (max-width:600px){
 .onsite-mobile-header>.brand{color:var(--muted)}
 .onsite-mobile-header>.brand small{color:var(--muted)}
 #bottomNav.bottom-nav button,.onsite-admin .sidebar .nav button{color:var(--mobile-nav-ink,var(--muted))}
 #bottomNav.bottom-nav .mobile-nav-destination{background:var(--mobile-nav-bg,transparent)}
 #bottomNav.bottom-nav .mobile-nav-destination:is(:hover,:focus-visible){background:var(--mobile-nav-active-bg,var(--brand-soft))}
 #bottomNav.bottom-nav button.active,.onsite-admin .sidebar .nav button.active{color:var(--mobile-nav-ink,var(--brand-deep));background:var(--mobile-nav-active-bg,var(--brand-soft))}
}

@media screen and (max-width:600px){.onsite-admin .sidebar .nav{--surface:#202224;--surface-alt:#2d3032;--ink:#f0efeb;--muted:#c5c3bc;--line:#484b4d;--brand-soft:#3b362c;--brand-deep:#e0c891;--mobile-chrome-bg:#202224;background:var(--surface);color:var(--ink);border-color:var(--line)}}

@media screen{.onsite-admin .admin-statistics-grid>.card.panel,.onsite-admin .admin-usage-statistics>.card.panel{padding:16px;min-width:0;box-sizing:border-box}.onsite-admin .admin-statistics-grid>.card.panel>h2{margin:0 0 12px}.onsite-admin .admin-usage-statistics>.card.panel{margin-bottom:16px}.onsite-admin .admin-usage-statistics{margin-top:20px}.onsite-admin .admin-usage-statistics .stats{grid-template-columns:repeat(auto-fit,minmax(135px,1fr))}}

/* Explicit chrome palettes: project light, administration dark; content theme stays independent. */
@media screen{
 body:not(.onsite-admin) .app .topbar,body:not(.onsite-admin) .onsite-mobile-header,#bottomNav.bottom-nav{--surface:#fff;--surface-alt:#f5f3ef;--ink:#202124;--muted:#68655f;--line:#dedbd5;--brand-soft:#eee5d3;--brand-deep:#68552e;--mobile-chrome-bg:#fff;background:var(--surface);color:var(--ink);border-color:var(--line)}
 html[data-onsite-theme=dark] body:not(.onsite-admin) .app .topbar,
 html[data-onsite-theme=dark] body:not(.onsite-admin) .onsite-mobile-header,
 html[data-onsite-theme=dark] body:not(.onsite-admin) #bottomNav.bottom-nav{--surface:#25292c;--surface-alt:#202427;--ink:#ecebe6;--muted:#b4b4ae;--line:#454a4d;--brand-soft:#3d372b;--brand-deep:#e1ca98;--mobile-chrome-bg:#25292c;background:var(--surface)!important;color:var(--ink);border-color:var(--line)}
 html[data-onsite-theme=dark] body:not(.onsite-admin) .onsite-mobile-header .habegger-logo{content:url('assets/habegger-logo-white.svg')}
 #content .onsite-search-row{display:flex!important;flex-wrap:nowrap!important;align-items:center!important;gap:6px!important;max-width:100%;min-width:0;overflow-x:auto}
 #content .onsite-search-row>*{grid-area:auto!important;order:0!important;flex:0 0 auto;margin:0!important;width:auto}
 #content .onsite-search-row>.onsite-row-search{flex:1 1 180px!important;min-width:70px!important;width:auto!important;max-width:none!important}
 #content .onsite-search-row>.onsite-row-search input{width:100%;min-width:0}
 #content .onsite-search-row>.personnel-filter-actions{display:flex!important;flex-wrap:nowrap!important;gap:6px;flex:0 0 auto!important}
 #content :is(.toolbar,.head-actions,.library-tools,.mvr-header-tools,.equipment-heading) button.btn.primary.action-add{height:var(--ui-control,36px)!important;min-height:var(--ui-control,36px)!important;width:var(--ui-control,36px)!important;min-width:var(--ui-control,36px)!important;max-width:var(--ui-control,36px)!important;padding:6px!important;flex:0 0 var(--ui-control,36px)!important}
 .app .topbar .issue-attention-dot{display:flex;align-items:center;justify-content:center;width:auto;min-width:17px;height:17px;padding:0 3px;box-sizing:border-box;top:-5px;right:-5px;color:var(--notification-ink,#fff);background:var(--notification-bg,#a34b40);font:600 10px/1 var(--ui-font,Arial,sans-serif);border-radius:10px;pointer-events:none}
 .app .topbar .issue-attention-dot[hidden]{display:none}
 .chat-room-tabs button[data-room]{background:var(--surface);color:var(--ink);border-color:var(--line)}
 .chat-room-tabs button[data-room][aria-pressed=true]{background:var(--brand-soft);color:var(--brand-deep);border-color:var(--brand-deep)}
}
@media screen and (max-width:760px){#content :is(.toolbar,.head-actions,.library-tools,.mvr-header-tools,.equipment-heading){--ui-control:36px}}
@media screen and (max-width:600px){
 .app .topbar .top-actions{gap:4px!important}
 .app .topbar .top-actions [data-project-action=up]{width:36px;padding:0}
 .app .topbar .top-actions .site-plan-button{width:36px;padding:0}
 .app .topbar .top-actions .site-plan-button span{display:none}
 #content .crew-toolbar>.search{flex:1 1 90px!important}
 #content .crew-toolbar>.crew-day-filter{max-width:100px;min-width:65px}
 #content .onsite-search-row .plain-filter-reset{padding-inline:6px;flex:none}
}
@media screen and (max-width:360px){.app .topbar .top-actions button.timeclock-button{width:36px;padding:0}.app .topbar .top-actions button.timeclock-button>span{display:none}}
@media screen{#content :is(.toolbar,.head-actions,.library-tools,.mvr-header-tools,.equipment-heading) .btn{height:var(--ui-control,36px)!important;min-height:var(--ui-control,36px)!important}}

/* Equal native button/link geometry in administration title actions. */
@media screen{.onsite-admin #content .page-head>.head-actions :is(button.btn,a.btn){box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;height:36px!important;min-height:36px!important;padding:0 10px!important;font-size:12px;line-height:1.2;text-decoration:none}}


/* More menus grow upward into available space; no inner scrolling. */
@media screen and (max-width:760px){
 .more-menu.mobile-nav-menu.open,.onsite-admin .admin-mobile-more:not([hidden]){box-sizing:border-box;max-height:calc(var(--onsite-visual-height,100dvh) - var(--onsite-footer-height,68px) - 16px);overflow:visible}
 .more-menu.mobile-nav-menu .mobile-nav-pool{overflow:visible;flex-shrink:0;grid-template-columns:repeat(var(--menu-columns,3),minmax(0,1fr));min-height:0}
 .more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-pool{gap:4px;padding-block:0}
 .more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-item .mobile-nav-destination{min-height:var(--menu-tile-height,40px);height:var(--menu-tile-height,40px);box-sizing:border-box;padding:3px;gap:3px;font-size:10px}
 .more-menu.mobile-nav-menu[data-menu-density=compact] .mobile-nav-item .mobile-nav-destination{display:flex;flex-direction:row;justify-content:center;align-items:center}
 .more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-hint{display:none}
 .more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-tools button,.more-menu.mobile-nav-menu[data-menu-density]>.onsite-push-settings,.more-menu.mobile-nav-menu[data-menu-density]>.mobile-nav-reset{height:32px;min-height:32px;padding:3px 8px;box-sizing:border-box}
 .more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-change{height:24px;min-height:24px;width:24px;font-size:16px}
 .more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-item .navicon,.more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-item .navicon svg{width:16px;height:16px;flex:0 0 16px}
 .more-menu.mobile-nav-menu[data-menu-density] .mobile-nav-item:has(.mobile-nav-change) .mobile-nav-destination{padding-right:22px}
}

@media screen and (max-width:600px){
 #onsite-feedback-button.onsite-feedback-floating{inset:0 auto auto 0;white-space:nowrap;transform-origin:0 0;transform:translate(calc(var(--onsite-visual-x,0px) + (var(--onsite-visual-width,100vw) - 14px) * var(--onsite-visual-inverse,1)),calc(var(--onsite-visual-bottom,100dvh) - (var(--onsite-footer-height,68px) + 12px) * var(--onsite-visual-inverse,1))) scale(var(--onsite-visual-inverse,1)) translate(-100%,-100%)}
}

/* Readiness and issue controls share one text size in RF live tiles. */
@media screen {
 :is(#content,dialog.wireless-full) :is(.wireless-tile .wireless-tile-bottom>:is(.wireless-issued,.wireless-status),.wireless-table :is(.wireless-issued,.wireless-status)){font-family:var(--ui-font);font-size:12px!important;font-weight:600;line-height:18px;transition-property:background-color,border-color,color,box-shadow}
 @media(pointer:coarse){:is(#content,dialog.wireless-full) :is(.wireless-tile .wireless-tile-bottom>:is(.wireless-issued,.wireless-status),.wireless-table :is(.wireless-issued,.wireless-status)){font-size:16px!important;line-height:20px}}
}

@media screen{.personnel-mobile-time-edit{border:0;background:transparent;color:inherit;font:inherit;text-align:left;cursor:pointer;padding:0}.personnel-mobile-time-edit:disabled{opacity:1;cursor:default}.personnel-mobile-time-edit:focus-visible{outline:2px solid var(--brand);outline-offset:3px}}

@media screen{
 .personnel-gantt-row .gantt-lane{height:30px}
 .personnel-shift-bar{display:flex;align-items:center;gap:3px;box-sizing:border-box;min-width:70px;padding:0 10px;height:26px;top:2px;overflow:visible;cursor:default}
 .personnel-shift-bar .gantt-bar-label{flex:1;min-width:0;font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 .personnel-shift-bar :is(.personnel-bar-time,.personnel-bar-grip,.personnel-bar-separator,.personnel-bar-edge){color:inherit;border:0;background:transparent;font:inherit;line-height:1;flex:none;padding:0;margin:0;touch-action:none}
 .personnel-shift-bar .personnel-bar-time{font-size:11px;cursor:text;font-variant-numeric:tabular-nums}
 .personnel-shift-bar :is(.personnel-bar-grip,.personnel-bar-separator){display:inline-flex;align-items:center;justify-content:center;font-size:11px;line-height:1}.personnel-shift-bar .personnel-bar-grip{width:18px;min-height:24px;cursor:grab}
 .personnel-shift-bar .personnel-bar-edge{position:absolute;top:0;bottom:0;width:8px;cursor:ew-resize;background:currentColor;opacity:.22;border-radius:4px}
 .personnel-bar-edge.left{left:0}.personnel-bar-edge.right{right:0}
 .personnel-shift-bar .personnel-bar-time:disabled{opacity:1;cursor:default}
 .personnel-bar-time-input{position:relative;z-index:5;flex:none;width:76px;height:26px;box-sizing:border-box;border:1px solid var(--line);border-radius:4px;background:var(--surface);color:var(--ink);font:12px var(--ui-font);padding:2px 4px}
 .personnel-shift-bar :is(button,input):focus-visible{outline:2px solid var(--brand);outline-offset:1px}
 @media(pointer:coarse){.personnel-shift-bar{height:34px;padding-inline:12px}.personnel-gantt-row .gantt-lane{height:38px}.personnel-shift-bar .personnel-bar-grip{min-width:28px;min-height:32px}.personnel-shift-bar .personnel-bar-time{min-height:32px}.personnel-shift-bar .personnel-bar-edge{width:10px}.personnel-bar-time-input{height:34px;font-size:16px;width:86px}.personnel-mobile-list~.mobile-timeline-content .mobile-time-row{min-height:40px}}
}

@media screen{.personnel-shift-bar{container-type:inline-size}@container(max-width:100px){.personnel-shift-bar .personnel-bar-time,.personnel-shift-bar .gantt-bar-label{display:none}}.mobile-time-row:has(.personnel-shift-bar){min-height:40px}}

@media screen{.personnel-multi-tools{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:8px 0}.personnel-multi-tools .help{margin:0}.personnel-multi-tools [data-personnel-selection-count]{margin-left:auto}.personnel-is-selected{outline:2px solid var(--gold,#bda36c);outline-offset:-2px}.personnel-bulk-form>label{display:grid;gap:5px}.personnel-bulk-form .grid label{display:grid;gap:8px}.personnel-bulk-form .grid label>span{display:flex;align-items:center;gap:6px}.personnel-bulk-form .select{width:100%}}

@media screen{.personnel-time-tooltip{position:fixed;z-index:12000;pointer-events:none;max-width:min(300px,calc(100vw - 16px));padding:8px 10px;background:var(--surface-alt,var(--surface,#fff));color:var(--ink,#202124);border:1px solid var(--line,#ddd);border-radius:8px;box-shadow:0 4px 16px #0002;font:11px/1.4 var(--ui-font)}.personnel-extra-form .grid label{display:grid;gap:6px}.personnel-extra-form .select{width:100%}.personnel-overall-shifts .personnel-add-shift{white-space:nowrap}}

@media screen{.personnel-grouped-actions{display:flex;align-items:center;justify-content:flex-end;min-width:0}.personnel-grouped-mobile-times{display:flex;flex-direction:row;align-items:center;gap:2px;min-width:0}.personnel-compact-time{display:flex;align-items:center;gap:3px;min-width:0;white-space:nowrap}.personnel-compact-time>.gantt-cell{position:static!important;left:auto!important;width:auto;min-width:0;flex:1;height:auto!important;background:inherit}.personnel-compact-value{min-width:0;overflow:hidden}.personnel-shift-more{flex:none;display:inline-flex;align-items:center;justify-content:center;height:var(--ui-row-action,24px);min-width:22px;padding:0 3px;border:1px solid var(--line);border-radius:5px;background:var(--surface-alt);color:var(--ink);font:600 11px var(--ui-font);cursor:pointer}.personnel-shift-more:hover{background:var(--brand-soft,var(--surface-alt))}.personnel-shift-more:focus-visible{outline:2px solid var(--brand-deep);outline-offset:1px}.personnel-mobile-card .personnel-shift-more{height:22px;margin:0}.personnel-overall-cell .personnel-compact-time:has(.personnel-shift-more){position:relative;padding-right:25px}.personnel-overall-cell .personnel-compact-time>.personnel-shift-more{position:absolute;right:0;top:50%;transform:translateY(-50%)}.personnel-overall-cell .personnel-compact-time .personnel-shift-time{grid-template-columns:auto 6px auto;gap:2px;min-width:0}.personnel-shift-list{width:100%;min-width:740px!important;table-layout:fixed}.personnel-shift-list th:first-child{width:36px}.personnel-shift-list th:nth-child(2){width:120px}.personnel-shift-list th:nth-child(3),.personnel-shift-list th:nth-child(4){width:70px}.personnel-shift-list th:last-child{width:88px;background:var(--surface,#fff)}.personnel-shift-list td{white-space:nowrap}.personnel-shift-list td:nth-child(5),.personnel-shift-list td:nth-child(6){overflow:hidden;text-overflow:ellipsis}}


@media screen{.personnel-grouped-lane{overflow:hidden}.personnel-grouped-lane .personnel-shift-bar{min-width:0;padding-inline:2px}}


@media screen{.personnel-continuation-edit{border:0;background:transparent;color:inherit;font:11px var(--ui-font);white-space:nowrap;padding:0 3px;cursor:pointer}.personnel-continuation-edit:disabled{opacity:1;cursor:default}.personnel-continuation-label{white-space:nowrap;font:inherit}.personnel-shift-bar[data-personnel-continuation]{min-width:0;padding-inline:2px}}

/* Anchor ordinary data rows to their first line, including rows with wrapped notes.
   Only the first text line reserves the row-control height; later lines stay compact. */
@media screen{
 :is(#content,.modal,dialog) :is(.table,.data-table,.patch-table):not(.table-align-middle)>tbody>tr:not(.day-group-row):not(.material-order-heading):not(.trucking-day-row):not(.material-import-row):not(.catering-day-heading)>:is(td,th[scope=row]):not(.table-cell-align-middle){vertical-align:top}
 :is(#content,.modal,dialog) :is(.table,.data-table,.patch-table)>tbody>tr:not(.day-group-row):not(.material-order-heading):not(.trucking-day-row):not(.material-import-row):not(.catering-day-heading)>td:not(:has(>.crew-position-label))::first-line{line-height:var(--ui-row-action,24px)}
}
@media screen{
 /* Position labels keep their single-line ellipsis box; align that box without stretching it. */
 #content .crew-table td:has(>.crew-position-label)::first-line{line-height:16px}
 #content .crew-table .crew-position-label{margin-top:0}
}

/* Booking subviews share the personnel controls, with readable mobile overflow. */
@media screen and (max-width:760px){
 #content .personnel-view-controls:has(>.staff-booking-tabs){display:flex;flex-wrap:wrap;align-items:stretch;gap:8px}
 #content .personnel-view-controls:has(>.staff-booking-tabs)>.personnel-time-basis{flex:1 1 100%}
 #content .personnel-view-controls>.staff-booking-tabs{display:flex;flex:1 1 100%;flex-wrap:nowrap;overflow-x:auto;max-width:100%;box-sizing:border-box}
 #content .personnel-view-controls>.staff-booking-tabs>button{flex:0 0 auto;padding-inline:10px}
}
@media screen{
 #content .personnel-view-controls:has(.unified-filters){display:flex;flex-wrap:wrap;align-items:center;gap:8px}
 #content .personnel-view-controls:has(.unified-filters)>.segmented{flex:0 0 auto;width:auto}
 #content .personnel-view-controls>.unified-filters{margin:0 0 0 auto;display:flex;align-items:center;justify-content:flex-end;gap:6px;flex-wrap:wrap}
 #content .unified-filters>.personnel-multi-tools{display:contents}
 #content .personnel-unified>.help{margin:8px 0 12px}
 .personnel-person-suggestions{position:fixed;z-index:18000;overflow:auto;border:1px solid var(--line,#dedbd6);border-radius:8px;background:var(--surface,#fff);color:var(--ink,#242321);box-shadow:0 6px 24px #0003;padding:4px;box-sizing:border-box}
 .personnel-person-suggestions[hidden]{display:none}
 .personnel-person-suggestions>button{display:block;width:100%;text-align:left;border:0;border-radius:5px;padding:8px;background:transparent;color:var(--ink,#242321);font:400 12px var(--ui-font);cursor:pointer}
 .personnel-person-suggestions>button:is(:hover,[aria-selected=true]){background:var(--surface-alt,#f7f5f1)}
 .personnel-person-suggestions strong{display:block;font-weight:600}
 .personnel-person-suggestions small{display:block;font-size:11px;color:var(--muted);margin-top:3px}
 .personnel-person-suggestions>p{padding:8px;margin:0}
}
@media screen and (max-width:760px){
 #content .personnel-view-controls:has(.unified-filters)>.segmented{flex:1 1 0;min-width:0}
 #content .personnel-view-controls>.unified-filters{flex:1 1 100%;margin-left:0}
 .personnel-person-suggestions>button{font-size:16px;min-height:44px}
}
@media screen{
 .personnel-person-suggestions[popover],.personnel-travel-tip[popover]{margin:0;inset:auto;box-sizing:border-box}
 .personnel-travel-tip{position:fixed;z-index:19000;border:1px solid var(--line,#dedbd6);border-radius:8px;padding:6px;background:var(--surface,#fff);color:var(--ink,#242321);box-shadow:0 4px 18px #0003}
 #content .personnel-unified-grid .staff-plan-person{padding:2px 6px;gap:4px}
 #content .personnel-unified-grid .staff-plan-person>.select,#content .personnel-unified-grid .personnel-booking-name>.personnel-overall-edit{box-sizing:border-box;height:24px;min-height:24px;padding:2px 5px;font:400 12px/18px var(--ui-font);text-align:left;border:1px solid transparent;border-radius:5px;margin:0}
 #content .personnel-unified-grid .personnel-booking-name{font-weight:400;width:100%;height:24px}
 #content .personnel-unified-grid .personnel-booking-name>.personnel-overall-edit{width:100%;max-width:100%;flex:1}
 .personnel-action-placeholder{width:var(--ui-row-action,24px);height:var(--ui-row-action,24px);flex:none}
 .personnel-shift-bar.is-travel,.unified-plan-bar.is-travel{background-image:repeating-linear-gradient(135deg,transparent 0 6px,color-mix(in srgb,currentColor 18%,transparent) 6px 8px)!important}
}
@media screen and (pointer:coarse){
 #content .personnel-unified-grid .staff-plan-person>.select,#content .personnel-unified-grid .personnel-booking-name>.personnel-overall-edit{height:32px;min-height:32px;font-size:16px;line-height:26px}
 #content .personnel-unified-grid .personnel-booking-name{height:32px}
}

@media screen{
 #app #content .projects-table>tbody>tr>td{vertical-align:middle}
 #app #content .projects-table .project-name-open{display:block;width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;height:var(--ui-row-action,32px);min-height:var(--ui-row-action,32px);padding:0;margin:0;line-height:inherit}
}

@media screen{
 .personnel-extra-form .personnel-shift-fields,.staff-dialog .personnel-shift-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
 .personnel-shift-fields>label{min-width:0}
 .personnel-shift-fields>label>.select{display:block;width:100%;min-width:0;box-sizing:border-box}
 .personnel-shift-fields>.staff-wide{grid-column:1/-1}
}

@media screen{.staff-plan-status{display:flex;align-items:center;gap:4px;min-width:0}.staff-plan-status>.staff-status{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.staff-plan-status>.staff-hotel-review{flex:none}}

/* Separate the scrolling time axis from fixed personnel details and actions. */
@media screen{
 .personnel-unified-grid{--personnel-timeline-edge:color-mix(in srgb,var(--line) 65%,var(--ink) 35%)}
 .personnel-unified-grid :is(.staff-timeline-head,.staff-timeline-row)>.staff-plan-label:nth-child(6){border-right:1px solid var(--personnel-timeline-edge);box-shadow:4px 0 7px -5px var(--ink)}
 .personnel-unified-grid :is(.staff-timeline-head,.staff-timeline-row)>.staff-plan-actions{border-left:1px solid var(--personnel-timeline-edge);box-shadow:-4px 0 7px -5px var(--ink)}
 .personnel-unified .staff-timeline-scroll{scrollbar-width:auto;scrollbar-color:var(--muted) var(--surface-alt)}
 .personnel-unified .staff-timeline-scroll::-webkit-scrollbar{height:10px;width:10px}
 .personnel-unified .staff-timeline-scroll::-webkit-scrollbar-track{background:var(--surface-alt)}
 .personnel-unified .staff-timeline-scroll::-webkit-scrollbar-thumb{background:var(--muted);border:2px solid var(--surface-alt);border-radius:8px}
}

/* Staffing requests reuse the shared controls; portraits/logos remain unaltered. */
@media screen{
 .staff-request-event-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:14px}
 .staff-request-event-heading>.staff-caption{min-width:0;margin:0}
 .staff-request-event-logo{display:block;max-width:140px;max-height:64px;width:auto;height:auto;object-fit:contain;flex:none}
 .staff-request-message{white-space:pre-line;overflow-wrap:anywhere}
 .staff-request-copy,.staff-position-colours{min-width:0;margin:18px 0;padding:12px;border:1px solid var(--line);border-radius:8px}
 .staff-request-copy>legend,.staff-position-colours>legend{padding-inline:5px;font-weight:600}
 .staff-request-copy textarea{display:block;box-sizing:border-box;width:100%;min-height:80px;resize:vertical}
 .staff-request-copy>details{margin-block:12px}
 .staff-request-snippet-tools{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:12px}
 .staff-request-snippet-tools>.select{flex:1 1 200px;min-width:0;max-width:100%;width:auto}
 .staff-request-snippet-tools>.btn{flex:none}
 .staffing-reply-count{display:inline-flex;align-items:center;justify-content:center;flex:none;box-sizing:border-box;min-width:20px;height:20px;padding:0 4px;border:0;border-radius:50%;background:var(--notification-bg,#a34b40);color:var(--notification-ink,#fff);font:600 11px/1 var(--ui-font);cursor:pointer}
 .staffing-reply-count:hover{filter:brightness(.9)}
 .staffing-reply-count:focus-visible{outline:2px solid var(--brand-deep);outline-offset:2px}
 .personnel-unified-grid .staff-position-name{gap:6px}
 .personnel-unified-grid .staff-position-name>.personnel-overall-field,.personnel-unified-grid .staff-position-name>span{min-width:0;flex:1}
}
@media screen and (max-width:760px){
 .staff-request-event-logo{max-width:100px;max-height:52px}
 .staff-request-copy,.staff-position-colours{padding:10px}
 .staff-request-snippet-tools>.select{flex-basis:100%}
 .staffing-reply-count{min-width:24px;height:24px}
}
/* Inline fields in the unified crew grid occupy the same space as open roles. */
@media screen{
 #content .personnel-unified-grid .staff-plan-trade>.tag{box-sizing:border-box;display:flex;align-items:center;height:24px;min-height:24px;padding:2px 6px}
 #content .personnel-unified-grid .staff-plan-trade>.tag>.personnel-overall-edit{height:18px;min-height:0;margin:0;padding:0;font:inherit;line-height:18px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
 #content .personnel-unified-grid .staff-position-name>.personnel-overall-edit{height:24px;min-height:24px;padding:2px 0;margin:0;line-height:18px}
}
@media screen and (pointer:coarse){
 #content .personnel-unified-grid .staff-plan-trade>.tag{height:32px;min-height:32px}
 #content .personnel-unified-grid .staff-plan-trade>.tag>.personnel-overall-edit{height:26px;line-height:26px}
 #content .personnel-unified-grid .staff-position-name>.personnel-overall-edit{height:32px;min-height:32px;line-height:26px}
}

@media screen{#content .project-budget-table [data-ui-input=inline]{font-family:var(--ui-font);font-size:12px;font-weight:400;line-height:1.3;vertical-align:middle} @media(pointer:coarse),(max-width:760px){#content .project-budget-table [data-ui-input=inline]{font-size:16px;min-height:36px}}}

@media screen{#content .users-table>tbody>tr>td{vertical-align:middle!important}#content .users-table .name-cell{align-items:center;min-height:0;margin:0}#content .users-table .name-cell strong{margin:0;line-height:1.3}}

@media screen{.personnel-bar-travel{display:inline-flex;align-items:center;justify-content:center;border:0;background:transparent;color:inherit;padding:0;min-width:18px;height:24px;cursor:grab;touch-action:none}.personnel-shift-bar:has(.personnel-bar-travel){justify-content:center}.personnel-drag-ghost{opacity:.9}}

@media screen{#content .personnel-unified-grid [data-unified-venue]{display:block;min-width:0;width:100%;max-width:100%;height:24px;min-height:24px;padding:2px 0;margin:0;font:400 12px/18px var(--ui-font);text-align:left;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}}
@media screen and (pointer:coarse){#content .personnel-unified-grid [data-unified-venue]{height:32px;min-height:32px;font-size:16px;line-height:26px}}

@media screen{.personnel-unified-grid .personnel-overall-markers[hidden]{display:none!important}}

@media screen{#content .personnel-unified-grid select.unified-role-input{box-sizing:border-box;width:100%;min-width:0;height:24px;min-height:24px;margin:0;padding:2px 22px 2px 5px;font:400 12px/18px var(--ui-font)}}
@media screen and (pointer:coarse){#content .personnel-unified-grid select.unified-role-input{height:32px;min-height:32px;font-size:16px;line-height:26px}}

@media screen{#content .personnel-unified .staff-timeline-scroll{max-height:none;height:auto}#content .personnel-unified .is-offday .personnel-bar-travel{cursor:default}}

@media screen{#content .personnel-unified .unified-day.is-cell-selected{background-color:var(--brand-soft);box-shadow:inset 0 0 0 2px var(--brand);z-index:1}body.personnel-cell-selecting,body.personnel-cell-selecting *{user-select:none!important}.personnel-unified [data-cell-selection-count]{white-space:nowrap}}

@media screen{.personnel-shift-kind{display:flex;flex-wrap:wrap}.personnel-shift-kind>button{flex:1 0 auto;min-height:36px;font-size:12px}.personnel-shift-kind>button.active{background:var(--surface-alt);color:var(--ink)}}
@media screen and (max-width:720px){.personnel-shift-kind>button{font-size:16px}}

@media screen{#content .personnel-unified-grid .staff-timeline-row[hidden]{display:none!important}}

@media screen{
 #content .personnel-timeline-zoom{display:flex;align-items:center;justify-content:flex-end;gap:8px;box-sizing:border-box;min-width:0;padding:0 var(--personnel-actions-width,160px) 8px 0}
 #content .personnel-timeline-zoom>.btn{flex:none;min-width:36px;height:36px;padding:0 8px}
 #content .personnel-timeline-zoom>[data-timeline-zoom-reset]{min-width:54px;font-variant-numeric:tabular-nums}
 #content .personnel-timeline-zoom>input[type=range]{box-sizing:border-box;flex:0 1 120px;width:120px;min-width:60px;height:36px;min-height:36px;margin:0;padding:0;accent-color:var(--brand);cursor:pointer}
 #content .personnel-unified-grid .unified-day-heading{min-width:0;overflow:hidden}
 #content .personnel-unified-grid .unified-day-heading .personnel-date-label{display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 #content .personnel-unified-grid .staff-day-activity{min-width:0;max-width:100%}
 #content .personnel-unified-grid.is-compact-zoom .personnel-overall-markers{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:1px;overflow:hidden}
 #content .personnel-unified-grid.is-compact-zoom .personnel-overall-marker{min-width:0;grid-template-columns:minmax(0,1fr);padding:1px 0;overflow:hidden}
 #content .personnel-unified-grid.is-compact-zoom .personnel-overall-marker>i{display:none}
 #content .personnel-unified-grid.is-tiny-zoom .staff-hour-labels{visibility:hidden}
 #content .personnel-unified-grid.is-compact-zoom .staff-hour-labels>span:nth-child(even){display:none}
 #content .personnel-unified-grid.is-compact-zoom .staff-hour-labels>span:nth-child(3){grid-column:3}
}
@media screen and (max-width:760px){#content .personnel-timeline-zoom{padding-right:0}#content .personnel-timeline-zoom>input[type=range]{flex-basis:100px;width:100px}}

@media screen{#content .personnel-unified:has([data-unified-action=fix],[data-unified-action=transfer]){--personnel-actions-width:190px}#content .personnel-unified:has([data-unified-action=fix],[data-unified-action=transfer]) .personnel-unified-grid{--staff-actions-width:var(--personnel-actions-width)}}
@media screen and (pointer:coarse){#content .personnel-unified:has([data-unified-action=fix],[data-unified-action=transfer]){--personnel-actions-width:240px}}

@media screen{#content .crew-table .crew-person-cell{min-height:var(--ui-row-action,24px);align-items:center}#content .crew-table .crew-person-cell strong{line-height:1.3;margin:0}}

@media screen{#content .head-actions>[data-schedule-venue]{flex:0 1 auto;min-width:0;max-width:100%;width:auto}}
@media screen and (min-width:1400px){#content .quick-entry-grid:has([name=venueId]){grid-template-columns:minmax(140px,1.2fr) 112px 76px 76px minmax(90px,1fr) minmax(160px,1.5fr) minmax(90px,1fr) minmax(100px,1fr) 36px}}
@media screen and (min-width:761px) and (max-width:1399px){#content .quick-entry-grid:has([name=venueId]){grid-template-columns:repeat(4,minmax(0,1fr))}#content .quick-entry-grid:has([name=venueId]) .quick-entry-title{grid-column:span 2}#content .quick-entry-grid:has([name=venueId]) .quick-entry-submit{grid-column:auto;justify-self:end}}

/* Module title corners follow the same open/closed geometry across portal pages. */
@media screen{
 #content :is(details.card,details.equipment-card,details.material-panel,details.patch-panel,details.admin-statistics-module)>summary{border-radius:var(--radius,16px) var(--radius,16px) 0 0}
 #content :is(details.card,details.equipment-card,details.material-panel,details.patch-panel,details.admin-statistics-module):not([open])>summary{border-radius:var(--radius,16px);border-bottom-color:transparent}
}

@media screen{
 .resource-planner .btn{border:1px solid var(--line,#e4e0d8);background:var(--surface,#fff);color:var(--ink,#202124);box-shadow:none;text-decoration:none;cursor:pointer}
 .resource-planner .btn:hover{background:var(--surface-alt,#f7f6f3)}
 .resource-planner .btn:disabled{opacity:.5;cursor:default}
}

/* Explicit centered metadata cells; ordinary multiline rows retain first-line alignment. */
@media screen{ :is(#content,.modal,dialog) :is(.table,.data-table,.patch-table)>tbody>tr>.table-cell-align-middle{vertical-align:middle}.table-cell-stack{display:flex;flex-direction:column;justify-content:center;min-width:0}}

/* Access forms outside the AB/PB app use the same screen controls. */
@media screen{
 .ui-access-screen main :is(button,input:not([type=checkbox]),select){box-sizing:border-box;min-height:var(--ui-control);height:var(--ui-control);border-radius:var(--ui-radius);font-family:var(--ui-font);font-size:var(--ui-control-text);line-height:1.2}
 .ui-access-screen main button{display:inline-flex;align-items:center;justify-content:center;padding:var(--ui-control-padding);font-weight:600}
 .ui-access-screen .page-head h1{font-family:var(--ui-font);font-size:var(--ui-title);line-height:1.2}
 @media(pointer:coarse){.ui-access-screen main :is(input:not([type=checkbox]),select){font-size:var(--ui-touch-input)}}
}

/* Add is the last action, after the format group; collapse remains outside it. */
@media screen{
 #content .ui-add-last{justify-content:flex-end}
 #content .page-head>.head-actions.ui-add-last{margin-left:auto}
 :is(#content,.ui-reference,dialog,.modal) .ui-add-last>.action-add:not(.action-photo){margin-left:0}
 :is(#content,.ui-reference,dialog,.modal) .ui-add-last>.file-format-buttons{margin-left:0}
 .onsite-admin #content .page-head>.head-actions>button.action-add{width:var(--ui-control,36px);min-width:var(--ui-control,36px);max-width:var(--ui-control,36px);padding:8px!important;flex:0 0 var(--ui-control,36px)}
}

@media screen{
 .personnel-shift-bar>.onsite-time-label{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);z-index:3;gap:3px;font-size:var(--ui-small)}
 .personnel-shift-bar>.personnel-label-move-area{position:absolute;inset:0;width:auto;height:auto;min-height:0;font-size:0;z-index:1}
 .personnel-shift-bar>.personnel-bar-edge{z-index:4}
}

/* Compact shared table baseline, matching Lichtpatch. Content may grow naturally. */
@media screen{
 :is(#content,.modal,dialog) :is(.table,.data-table,.patch-table)>tbody>tr:not(.day-group-row):not(.table-group-heading)>td{height:var(--ui-row);padding-block:2px;vertical-align:middle}
}

/* One body-text size for every screen table. The named layer makes this contract
 * win over older per-module important rules; paper and action icons stay separate.
 * Touch editors grow only while editing, so resting cells keep the same typography. */
@layer onsite-table-typography {
 @media screen {
  table:not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *)) :is(tbody,tfoot) :is(td,th):not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *,thead *)),
  table:not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *)) :is(tbody,tfoot) :is(td,th) :is(span,div,p,small,strong,em,label,a,input,select,textarea,button):not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *,thead *,button *,.btn,.btn *,.iconbtn,.iconbtn *,.action-button,.action-button *,.row-actions *,.actions *,.column-menu-panel *,.onsite-column-settings *,.personnel-drag-handle *,svg *,.table-group-heading *,.day-group-toggle *,.day-group-row *,.material-order-heading *,.catering-day-heading *,.trucking-day-row *)),
  :is(.staff-timeline-row,.gantt-row,.personnel-unified-grid [role="row"],.material-mobile-card,.mobile-list-card):not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *)),
  :is(.staff-timeline-row,.gantt-row,.personnel-unified-grid [role="row"],.material-mobile-card,.mobile-list-card) :is(span,div,p,small,strong,em,label,a,input,select,textarea,button):not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *,thead *,button *,.btn,.btn *,.iconbtn,.iconbtn *,.action-button,.action-button *,.row-actions *,.actions *,.column-menu-panel *,.onsite-column-settings *,.personnel-drag-handle *,svg *,.table-group-heading *,.day-group-toggle *,.day-group-row *,.material-order-heading *,.catering-day-heading *,.trucking-day-row *)) {font-size:var(--ui-table,12px)!important}
 }
 @media screen and (pointer:coarse),screen and (max-width:760px) {
  table:not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *)) :is(tbody,tfoot) :is(td,th) :is(input,select,textarea):not([readonly]):enabled:focus:not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *,thead *)),
  :is(.staff-timeline-row,.gantt-row,.personnel-unified-grid [role="row"],.material-mobile-card,.mobile-list-card) :is(input,select,textarea):not([readonly]):enabled:focus:not(:where(.report-table,.print-timing-table,.personnel-print-table,.report-preview-paper *,.report-page *,.print-page *,.print-output-page *,.print-preview-page *,.print-preview-pages *,.report-preview-pages *,.personnel-preview-page *,.timing-preview-page *,.crew-preview-page *,.diary-report-page *,#projectReportPrintSheet *,#timingPrintSheet *,#printSheet *)) {font-size:var(--ui-touch-input,16px)!important}
 }
}

/* Shared patch-style cell selection; Audio editors overlay existing cell geometry. */
@media screen{
 .patch-table td[data-patch-field]{position:relative;cursor:cell}
 .patch-table td[data-patch-field]:not(.patch-cell-editing){user-select:none;-webkit-user-select:none}
 .patch-table .patch-cell-input{user-select:text;-webkit-user-select:text}
 body.patch-grid-selecting,body.patch-grid-selecting *{user-select:none!important;-webkit-user-select:none!important}
 .patch-grid-touch-selection td[data-patch-field]{touch-action:none}
 .patch-table td.patch-cell-selected{box-shadow:inset 0 0 0 2px var(--brand-deep);outline-offset:-2px}
 .patch-table td.patch-cell-editing{color:transparent}
 .patch-table td .patch-cell-input{position:absolute;inset:0;z-index:4;width:100%;min-width:80px;height:var(--ui-control,36px);font-size:var(--ui-table,12px);color:var(--ink);background:var(--surface);padding:6px}
 #audio-planning .audio-doc-table td .audio-grid-input{box-sizing:border-box;height:100%!important;min-height:0!important;min-width:0;width:100%;margin:0;padding:2px 6px;border-radius:0}
 #audio-planning .audio-doc-table .action-cell{white-space:nowrap;overflow:visible}
 #audio-planning .audio-doc-table .row-actions{width:max-content;margin-left:auto}
 @media(pointer:coarse){.patch-table td .patch-cell-input{font-size:var(--ui-touch-input,16px)}}
}

/* Status chips must fit the same ordinary row in AB and PB. */
@media screen{
 :is(#content,.modal,dialog) :is(.table,.data-table,.patch-table)>tbody>tr>td:has(>:is(.badge,.status-label,.project-access-summary):only-child)::first-line{line-height:16px}
 :is(#content,.modal,dialog) :is(.table,.data-table,.patch-table)>tbody>tr>td :is(.badge,.status-label,.project-access-summary){box-sizing:border-box;display:inline-flex;align-items:center;min-height:var(--ui-row-action);padding:2px 6px;line-height:16px;vertical-align:top}
}

@media screen{#content .users-table .project-access-list{display:flex;align-items:center}}

@media screen{body.onsite-child-dialog-open #onsite-feedback-button{visibility:hidden;pointer-events:none}}

/* Canonical AB popup reference: the user-management profile dialog.
   All normal AB dialogs share one palette, form grid and footer, independent of page CSS.
   Geometry of drawers/fullscreen is retained by dialog-controls.js. */
@media screen {
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog{
  --surface:var(--admin-dialog-field-bg);--surface-alt:var(--admin-dialog-soft-bg);--ink:var(--admin-dialog-ink);--muted:var(--admin-dialog-muted);--line:var(--admin-dialog-line);--deep:var(--admin-dialog-accent);
  --button-surface:var(--admin-dialog-field-bg);--button-line:var(--admin-dialog-line);--button-hover:var(--admin-dialog-soft-bg);
  box-sizing:border-box;border:1px solid var(--admin-dialog-line);border-radius:var(--ui-admin-dialog-radius);background:var(--admin-dialog-bg);color:var(--admin-dialog-ink);box-shadow:var(--admin-dialog-shadow);padding:var(--ui-admin-dialog-padding);font:400 var(--ui-text)/1.5 var(--ui-font)
 }
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog::backdrop{background:var(--admin-dialog-backdrop);backdrop-filter:blur(3px)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog-positioned{top:var(--admin-dialog-top,16px);bottom:auto;margin:0 auto;max-height:calc(100dvh - var(--admin-dialog-top,16px) - 16px);overflow:auto}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.dialog-title,.master-card-heading h2),:is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog>h2,:is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog>form>h2,:is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog>form>header>h2{font:600 var(--ui-title)/1.3 var(--ui-font);letter-spacing:-.04em;margin:6px 0 10px}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.dialog-subtitle,[data-dialog-selection],.form-error,[data-error]):empty{display:none}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .dialog-subtitle{font:400 12px/1.6 var(--ui-font);color:var(--admin-dialog-muted);margin:0 0 22px}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.form-grid,.master-form-grid,.fleet-fields,.staff-form-grid){display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--ui-admin-dialog-grid-gap);margin-top:20px}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(label,.field,.ui-field>label){font:400 var(--ui-small)/1.4 var(--ui-font);color:var(--admin-dialog-ink)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.field,.ui-field){display:grid;gap:var(--ui-admin-dialog-field-gap);margin:0;min-width:0;align-content:start}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.form-grid,.master-form-grid,.fleet-fields,.staff-form-grid)>label:not(:has(input[type=checkbox],input[type=radio])){display:grid;gap:var(--ui-admin-dialog-field-gap);margin:0;align-content:start}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(input:not([type=hidden]):not([type=checkbox]):not([type=radio]):not([type=file]):not([type=range]):not([type=color]):not([type=button]):not([type=submit]),select,textarea){box-sizing:border-box;width:100%;min-width:0;min-height:var(--ui-control);border:1px solid var(--admin-dialog-field-line);border-radius:var(--ui-radius);background:var(--admin-dialog-field-bg);color:var(--admin-dialog-ink);font:600 var(--ui-control-text)/1.4 var(--ui-font);padding:7px 10px}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(input:not([type=hidden]):not([type=checkbox]):not([type=radio]):not([type=file]):not([type=range]):not([type=color]):not([type=button]):not([type=submit]),select:not([multiple])){height:var(--ui-control);padding-block:0}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(input,select,textarea){font-weight:600}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog>form:not(.dialog-close){gap:20px}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog>form>label:not(:has(input[type=checkbox],input[type=radio])){display:grid;gap:var(--ui-admin-dialog-field-gap);margin:0}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog textarea{height:auto;min-height:84px;resize:vertical}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.form-actions,.ui-dialog-actions,form>footer){display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:var(--ui-admin-dialog-footer-gap);border-top:1px solid var(--admin-dialog-line);padding-top:20px;margin:25px 0 0;background:var(--admin-dialog-bg)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.form-actions,.ui-dialog-actions,form>footer)>button{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;gap:8px;height:var(--ui-control);min-height:var(--ui-control);padding:0 14px;border:1px solid var(--admin-dialog-line);border-radius:var(--ui-radius);font:600 var(--ui-control-text)/1.2 var(--ui-font)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.dialog-close button,.master-person-close,.master-drawer-close,.ui-admin-dialog-close){box-sizing:border-box;width:36px;height:36px;min-width:36px;min-height:36px;display:inline-flex;align-items:center;justify-content:center;padding:8px;border:0;border-radius:var(--ui-radius);background:transparent;color:var(--admin-dialog-muted)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog>.ui-admin-dialog-close{position:absolute;top:12px;right:16px}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.dialog-close button,.master-person-close,.master-drawer-close,.ui-admin-dialog-close):hover{background:var(--admin-dialog-soft-bg)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.dialog-close button,.master-person-close,.master-drawer-close,.ui-admin-dialog-close)>svg{width:18px;height:18px;flex:none}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog:has(>.ui-admin-dialog-close)>form>h2{padding-right:36px}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .master-panel{border:0;border-radius:0;background:transparent;padding:0}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .master-info:has(>.master-info-field){grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--ui-admin-dialog-grid-gap)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .master-info-field{display:grid;gap:var(--ui-admin-dialog-field-gap);min-width:0;align-content:start}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .master-info-field dt{font:400 var(--ui-small)/1.4 var(--ui-font);color:var(--admin-dialog-ink)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .master-info-field dd{margin:0;min-height:var(--ui-control);padding:7px 10px;border:1px solid var(--admin-dialog-field-line);border-radius:var(--ui-radius);background:var(--admin-dialog-field-bg);font:600 var(--ui-control-text)/1.4 var(--ui-font);overflow-wrap:anywhere}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog.master-vehicle-drawer{padding:0;border:0;border-left:1px solid var(--admin-dialog-line);border-radius:var(--ui-admin-dialog-radius) 0 0 var(--ui-admin-dialog-radius)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog.master-vehicle-drawer .master-drawer-body{padding:var(--ui-admin-dialog-padding)}
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog.master-vehicle-drawer :is(.master-drawer-footer,.master-drawer-body>.master-card-heading){background:var(--admin-dialog-bg)}
 @media(max-width:600px){
  :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog{padding:24px 18px}
  :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog.master-vehicle-drawer{padding:0;border-radius:var(--ui-admin-dialog-radius)}
  :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog.master-vehicle-drawer .master-drawer-body{padding:24px 18px}
  :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(.form-grid,.master-form-grid,.fleet-fields,.staff-form-grid,.master-info:has(>.master-info-field)){grid-template-columns:minmax(0,1fr)}
 }
 @media(max-width:760px),(pointer:coarse){:is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog :is(input:not([type=hidden]),select,textarea,.master-info-field dd){font-size:var(--ui-touch-input)!important}}
}

@media screen{
 :is(#content,.onsite-admin) dialog.onsite-admin-module-dialog{position:fixed;inset:var(--admin-module-top) auto auto var(--admin-module-left);margin:0;width:var(--admin-module-width);max-width:var(--admin-module-width);height:var(--admin-module-height);max-height:var(--admin-module-height)}
 .master-vehicle-photo-tooltip{position:fixed;z-index:12050;max-width:min(360px,calc(100vw - 16px));padding:6px;border:1px solid var(--line);border-radius:var(--ui-radius,8px);background:var(--surface);box-shadow:var(--shadow);pointer-events:none}
 .master-vehicle-photo-tooltip img{display:block;max-width:100%;max-height:240px;object-fit:contain}
 .master-entity-dialog .master-card-heading{justify-content:space-between;align-items:center;gap:12px}.master-entity-dialog .master-card-heading h2{font:600 var(--ui-title)/1.3 var(--ui-font);margin:6px 0 10px}
}

/* Reusable connected view switch, following the Audio planning reference. */
@media screen{
 .segmented.ui-segmented{display:flex;align-items:center;gap:2px;box-sizing:border-box;max-width:100%;padding:2px;border:1px solid var(--line);border-radius:9px;background:var(--surface-alt);min-height:36px}
 .segmented.ui-segmented>button{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;gap:4px;min-height:30px;padding:5px 9px;border:0;border-radius:7px;background:transparent;color:var(--muted);box-shadow:none;font:400 12px/1.2 var(--ui-font);white-space:nowrap;cursor:pointer}
 .segmented.ui-segmented>button:is(.active,[aria-selected=true]){background:var(--surface);color:var(--ink);box-shadow:0 1px 4px #0001;font-weight:600}
 .segmented.ui-segmented>button:hover:not(.active):not([aria-selected=true]){color:var(--ink)}
 .segmented.ui-segmented>button:focus-visible{outline:2px solid var(--muted);outline-offset:-2px}
}

@media screen{
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .master-base-readonly .master-info-field dd{background:var(--admin-dialog-readonly-bg);color:var(--admin-dialog-muted);border-color:var(--admin-dialog-line);cursor:default}
}

@media screen{
 :is(#content,.onsite-admin,.resource-embedded) dialog.onsite-admin-dialog .cargo-readonly :is(input,select,textarea):disabled{--admin-dialog-field-bg:var(--admin-dialog-readonly-bg);--admin-dialog-ink:var(--admin-dialog-muted);opacity:1}
}

@media screen{
 .favorite-sort-active{opacity:.4}
 .favorite-sort-target{outline:2px solid var(--brand-deep);outline-offset:-2px;border-radius:var(--ui-radius,8px)}
 .favorite-sort-ghost{position:fixed;z-index:4000;pointer-events:none;max-width:240px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:8px 12px;border:1px solid var(--line);border-radius:var(--ui-radius,8px);background:var(--surface);color:var(--ink);font:600 12px/1.45 var(--ui-font)}
}

/* Title action spacing: one screen contract for AB/PB, including group/fold boundaries. */
@media screen{
 :is(.page-head,.equipment-heading,.section-head,.panel-head,.ui-module-heading,.ui-data-panel-header,.admin-module-heading,.library-heading,.patch-heading,.mvr-header,.mvr-heading,.shitlist-heading){column-gap:var(--ui-title-action-gap)!important;row-gap:var(--ui-title-action-gap)!important}
 :is(.page-head,.equipment-heading,.section-head,.panel-head,.ui-module-heading,.ui-data-panel-header,.admin-module-heading,.library-heading,.patch-heading,.mvr-header,.mvr-heading,.shitlist-heading) :is(.head-actions,.toolbar,.ui-toolbar,.admin-module-tools,.library-tools,.mvr-header-tools,.equipment-toolbar,.project-export-buttons,.file-format-buttons,.master-edit-actions,.wireless-page-actions){gap:var(--ui-title-action-gap)!important;padding:0!important}
 :is(.page-head,.equipment-heading,.section-head,.panel-head,.ui-module-heading,.ui-data-panel-header,.admin-module-heading,.library-heading,.patch-heading,.mvr-header,.mvr-heading,.shitlist-heading) :is(.head-actions,.toolbar,.ui-toolbar,.admin-module-tools,.library-tools,.mvr-header-tools,.equipment-toolbar,.project-export-buttons,.file-format-buttons,.master-edit-actions,.wireless-page-actions)>:is(button,a,.btn,.file-format-buttons,.project-export-buttons,.master-edit-actions){margin:0!important}
}

/* Native link/image callouts follow the global context-menu policy on iOS. */
@media screen{body{-webkit-touch-callout:none}}

/* SOURCE ui-components.css */
/* Canonical new components. Existing pages opt in; global geometry remains in its current owners. */
@media screen{
 .onsite-time-label{display:inline-flex;align-items:center;justify-content:center;flex-wrap:nowrap;flex:none;gap:0;box-sizing:border-box;width:max-content;white-space:nowrap;padding:1px 3px;background:var(--time-label-surface,var(--surface));color:var(--ink);line-height:1.1;font-variant-numeric:tabular-nums;pointer-events:none}
 .onsite-time-label>:is(button,input,select,textarea),.onsite-time-label[data-time-label-interactive]{pointer-events:auto}
 .onsite-time-label:has(>button){background:linear-gradient(to bottom,transparent calc(50% - .65em),var(--time-label-surface,var(--surface)) calc(50% - .65em),var(--time-label-surface,var(--surface)) calc(50% + .65em),transparent calc(50% + .65em))}
 .onsite-time-label-hidden{visibility:hidden}
 .onsite-time-label-divider{display:inline-block;padding-inline:4px;color:var(--muted)}
 .ui-clear-button.btn{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;flex:0 0 var(--ui-control);width:var(--ui-control);min-width:var(--ui-control);height:var(--ui-control);min-height:var(--ui-control);padding:8px;color:var(--red);border-radius:var(--ui-radius)}
 .ui-clear-button.btn>svg{display:block;flex:none;width:18px;height:18px}
 .ui-clear-button.btn:hover:not(:disabled){background:var(--red-soft)}
 .ui-field{display:grid;gap:var(--ui-gap);min-width:0}.ui-field>label{font-size:var(--ui-small);font-weight:600;color:var(--muted)}
 .ui-field-controls{display:flex;align-items:center;gap:var(--ui-gap);min-width:0}.ui-field-controls>.onsite-date-input,.ui-field-controls>.ui-input{flex:1;min-width:0;width:100%}
 :is(.ui-input,.ui-form-control){box-sizing:border-box;height:var(--ui-control,36px);min-height:var(--ui-control,36px);padding:var(--ui-control-padding,7px 10px);border:1px solid var(--line);border-radius:var(--ui-radius,8px);background:var(--surface);color:var(--ink)}
 .ui-input{font:400 var(--ui-control-text)/1.4 var(--ui-font)}
 .ui-dialog-actions{display:flex;align-items:center;justify-content:flex-end;gap:var(--ui-dialog-action-gap,8px);margin-top:var(--ui-dialog-action-margin,16px);flex-wrap:wrap}
 :is(.ui-input,.ui-form-control):focus-visible{outline:2px solid var(--brand);outline-offset:2px}
 .ui-toolbar{display:flex;align-items:center;justify-content:flex-start;gap:var(--ui-gap);min-width:0}.ui-toolbar>.file-format-buttons{margin-left:auto;display:flex;gap:var(--ui-gap);align-items:center}
 .ui-module,.ui-data-panel{border:1px solid var(--line);border-radius:var(--radius,16px);background:var(--surface);box-shadow:var(--shadow);padding:0;min-width:0}.ui-module{margin-bottom:var(--ui-module-gap)}
 :is(#content,.ui-reference) .ui-module-heading{list-style:none;display:grid;grid-template-columns:minmax(0,1fr) auto 16px;align-items:center;gap:var(--ui-title-action-gap);margin:0;border-radius:inherit;cursor:pointer}
 :is(#content,.ui-reference) .ui-module-heading>h2{grid-column:1;grid-row:1}
 :is(#content,.ui-reference) .ui-module-heading>.ui-toolbar{grid-column:2;grid-row:1;align-self:center;min-width:0;margin:0;max-width:100%}
 .ui-module-heading>.ui-toolbar:empty{display:none}
 .ui-module-heading::-webkit-details-marker{display:none}.ui-module-heading>h2{font:600 var(--ui-section)/1.3 var(--ui-font);margin:0;min-width:0;flex:1}
 .ui-module-heading::after{grid-column:3;grid-row:1;justify-self:end;content:'⌄';flex:none;color:var(--muted)}.ui-module:not([open])>.ui-module-heading::after{rotate:-90deg}
 .ui-module:not([open])>.ui-module-heading{border-radius:var(--radius,16px);border-bottom-color:transparent}
 .ui-module[open]>.ui-module-heading{border-radius:var(--radius,16px) var(--radius,16px) 0 0;border-bottom:1px solid var(--line)}.ui-module-body{padding:var(--ui-module-body-padding);min-width:0}
 .ui-number{text-align:right}.ui-number>.table-column-label{justify-content:flex-end}
 
 @media(pointer:coarse){:is(.ui-input,.ui-form-control){font-size:var(--ui-touch-input,16px)}}
 @media(max-width:600px){.ui-module-body{padding:14px}:is(#content,.ui-reference) .ui-module-heading>h2{grid-column:1/3}:is(#content,.ui-reference) .ui-module-heading>.ui-toolbar:not(:empty){grid-column:1/3;grid-row:2;overflow-x:auto;width:100%;flex-wrap:nowrap}.ui-module-heading:has(>.ui-toolbar:not(:empty))::after{grid-row:2}.ui-module-heading>.ui-toolbar>*{flex-shrink:0}.ui-toolbar{gap:var(--ui-gap)}}
}

/* Shared data-module shell for AB/PB; screen only, no export-layout changes. */
@media screen{
 :is(#content,.resource-planner) .ui-data-panel{box-sizing:border-box;border:1px solid var(--ui-data-panel-line);border-radius:var(--radius,16px);background:var(--surface);box-shadow:var(--ui-data-panel-shadow);padding:0;min-width:0;overflow:visible}
 .ui-data-panel-header{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:var(--ui-title-action-gap);padding:var(--ui-module-heading-padding);border-bottom:1px solid var(--ui-data-panel-line);min-width:0}
 .ui-data-panel-header>h2{display:flex;align-items:center;min-height:var(--ui-control);margin:0;font:600 var(--ui-section)/1.3 var(--ui-font);min-width:0}
 .ui-data-panel-header>.ui-toolbar{margin:0 0 0 auto;flex-wrap:wrap;justify-content:flex-end}
 .ui-data-panel-header>.ui-toolbar:empty{display:none}
 .ui-data-panel-controls{box-sizing:border-box;display:grid;gap:12px;min-width:0;padding:var(--ui-module-body-padding)}
 .ui-data-panel-controls:empty{display:none}
 .ui-data-panel-controls>:is(.toolbar,.table-filter-bar,.help,.master-help,.resource-summary,p){margin:0}
 .ui-data-panel-controls>.ui-toolbar{flex-wrap:wrap;align-items:end}
 .ui-data-panel-controls>.ui-toolbar>.ui-field:first-child{flex:1;min-width:180px}
 .ui-data-panel-scroll{box-sizing:border-box;min-width:0;max-width:calc(100% - 2 * var(--ui-module-body-padding));margin:0 var(--ui-module-body-padding) var(--ui-module-body-padding)}
 .ui-data-panel-header+.ui-data-panel-scroll{margin-top:var(--ui-module-body-padding)}
 .ui-data-panel-scroll>.table-wrap{margin:0}
 :is(#content,.resource-planner) :is(.equipment-card,.card.panel):has(table):not(.equipment-card .equipment-card){border:1px solid var(--ui-data-panel-line);border-radius:var(--radius,16px);background:var(--surface);box-shadow:var(--ui-data-panel-shadow)}
 @media(max-width:760px){.ui-data-panel-header{padding:var(--ui-module-heading-mobile-padding)}.ui-data-panel-controls{padding:14px}.ui-data-panel-scroll{max-width:calc(100% - 28px);margin:0 14px 14px}.ui-data-panel-header+.ui-data-panel-scroll{margin-top:14px}}
}

@media screen{:is(#content,.ui-reference) :is(.ui-module-heading,.equipment-heading) h2{display:flex;align-items:center;min-height:var(--ui-control)}}

@media screen{
 :is(#content,.resource-planner) .ui-data-panel-controls>.toolbar{flex-direction:row;flex-wrap:wrap!important}
 :is(#content,.resource-planner) .ui-data-panel-controls>.toolbar>input[type=search]{flex:1;min-width:0;width:0;max-width:none}
 @media(max-width:760px){:is(#content,.resource-planner) .ui-data-panel-controls>.toolbar>span:first-child{flex:1 0 100%!important}}
}
