/* Crew is a staff presentation, not a separate permission role. */
body.workspace-crew .crew-native-hidden{display:none!important}
body.workspace-crew .crew-quick-controls{display:grid;gap:18px;margin:0 0 18px;min-width:0}
body.workspace-crew .crew-quick-block{display:block;min-width:0;margin:0;padding:0;border:0}
body.workspace-crew .crew-quick-label{display:block;float:none;width:100%;margin:0 0 7px;padding:0;color:var(--ui-muted,#607082);font:inherit;font-size:13px;line-height:1.45}
body.workspace-crew .crew-choice-row{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;min-width:0}
body.workspace-crew .crew-choice-row.crew-four-choices{grid-template-columns:repeat(2,minmax(0,1fr))}
body.workspace-crew .crew-choice{min-width:0;min-height:46px;padding:9px 6px;white-space:normal;overflow-wrap:normal;font-size:14px;line-height:1.4;text-align:center;display:flex;align-items:center;justify-content:center}
body.workspace-crew .crew-choice[aria-pressed=true]{color:var(--ui-blue,#036eb0);background:#e8f3fa;border-color:var(--ui-blue,#036eb0)}
body.workspace-crew .crew-choice:disabled{opacity:.55}
body.workspace-crew .crew-wrap-control{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:46px;margin:0;padding:4px 0;cursor:default}
body.workspace-crew .crew-wrap-wording{display:grid;gap:3px;font-size:14px;line-height:1.5}
body.workspace-crew .crew-wrap-hint{display:block;color:var(--ui-muted,#607082);font-size:12px;line-height:1.4}
body.workspace-crew .crew-wrap-control input{width:23px;height:23px;flex:0 0 23px;margin:0;accent-color:var(--ui-blue,#036eb0)}
body.workspace-crew .crew-tree-card .fields:has(>.crew-native-hidden):not(:has(>label:not(.crew-native-hidden))){display:none}
body.workspace-crew .crew-source-summary{padding:12px!important;border:0!important;border-radius:10px;background:var(--ui-soft,#f4f6f8);margin:0 0 16px!important;min-width:0}
body.workspace-crew .crew-source-summary h3{font-size:12px!important;line-height:1.4;margin:0 0 6px!important;color:var(--ui-muted,#607082)}
body.workspace-crew .crew-source-summary p{font-size:13px!important;line-height:1.5;margin:4px 0!important;overflow-wrap:anywhere}
body.workspace-crew .crew-secondary-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:16px 0 0;min-width:0}
body.workspace-crew .crew-secondary-actions>button{min-height:46px;min-width:0;margin:0;padding:9px 8px;font-size:14px;line-height:1.4;white-space:normal}
body.workspace-crew .crew-note-editor{display:grid;gap:9px;min-width:0;margin-top:12px}
body.workspace-crew .crew-note-editor[hidden]{display:none!important}
body.workspace-crew .crew-note-editor>label{display:grid;gap:7px;margin:0;min-width:0;font-size:13px;line-height:1.5}
body.workspace-crew .crew-note-editor textarea{box-sizing:border-box;width:100%;min-width:0;min-height:94px;font-size:16px;line-height:1.5;padding:10px}
body.workspace-crew .crew-note-actions{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;min-width:0}
body.workspace-crew .crew-note-actions>button{min-height:44px;margin:0;padding:9px 14px;font-size:14px;line-height:1.4}
body.workspace-crew .crew-note-actions>span{font-size:12px;line-height:1.5}
body.workspace-crew .crew-save-feedback{min-width:0;margin-top:14px;font-size:12px;line-height:1.5;color:var(--ui-muted,#607082)}
body.workspace-crew .crew-save-feedback>p,body.workspace-crew .crew-save-feedback>.power-feedback{margin:0!important;padding:0!important;font:inherit;border:0!important;background:transparent!important;line-height:1.5}
body.workspace-crew .crew-save-feedback .error{color:var(--ui-red,#ac3935)}
body.workspace-crew .crew-tree-navigation{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.4fr);gap:8px;margin:20px -16px -16px;padding:13px 16px;border-top:1px solid var(--ui-edge,#dee5eb)}
body.workspace-crew .crew-tree-navigation>button{min-height:46px;min-width:0;margin:0;padding:9px 10px;font-size:14px;line-height:1.4}
body.workspace-crew .crew-map-tabs{position:absolute;left:14px;bottom:42px;z-index:500;display:flex;gap:3px;background:var(--ui-sheet,#fff);padding:4px;border:1px solid var(--ui-edge,#dee5eb);border-radius:10px;box-shadow:0 3px 12px #0e1d4217}
body.workspace-crew .crew-map-tabs button{min-width:64px;min-height:44px;margin:0;border:0;border-radius:7px;padding:8px 11px;font-size:13px;line-height:1.4}
body.workspace-crew .crew-map-tabs button[aria-pressed=true]{color:var(--ui-blue,#036eb0);background:#e8f3fa}
body.workspace-crew .power-tools-top,body.workspace-crew .power-key,body.workspace-crew .power-flow-card,body.workspace-crew .power-direct-flow,body.workspace-crew .power-place-hint,body.workspace-crew .power-connection-entry{display:none!important}
body.workspace-crew .crew-power-card .crew-quick-controls{padding:0;margin:18px 0}
body.workspace-crew .crew-power-city{margin:6px 0 0;font-size:13px;line-height:1.5;color:var(--ui-muted,#607082)}
body.workspace-crew .crew-access-summary{display:grid;gap:5px;min-width:0;padding:12px;background:var(--ui-soft,#f4f6f8);border-radius:10px;font-size:13px;line-height:1.5}
body.workspace-crew .crew-access-summary strong{font-size:13px;line-height:1.5;font-weight:500}
body.workspace-crew .crew-access-summary span{display:block;overflow-wrap:anywhere}
body.workspace-crew .crew-access-summary small{display:block;font-size:12px;line-height:1.5;color:var(--ui-muted,#607082)}
body.workspace-crew .crew-power-report{margin-top:14px;border:0;padding:0}
body.workspace-crew .crew-power-report>summary{display:none}
body.workspace-crew .crew-power-report:not([open]){display:none}
body.workspace-crew .crew-power-report>label{display:grid;gap:7px;font-size:13px;line-height:1.5;margin:0 0 9px}
body.workspace-crew .crew-power-report textarea{width:100%;min-height:94px;font-size:16px;line-height:1.5}
body.workspace-crew .crew-power-report>button{min-height:44px}
body.workspace-crew :is(.asset-more,.asset-note-section,.operating-fields,.issue-updates,#back-list){display:none!important}
body.workspace-crew .crew-source-summary .asset-feed-link button:disabled{opacity:1;color:var(--ui-ink,#0e1d42);cursor:default}
body.workspace-crew .crew-source-summary .asset-feed-link{background:none;padding:0;gap:5px}
body.workspace-crew .crew-source-summary .asset-section-label{display:none}
body.workspace-crew :is(.note-actions,.power-note-actions):empty{display:none!important}
body.workspace-crew .crew-power-card{padding:16px!important}
body.workspace-crew .crew-power-card .power-asset-head{padding:0 0 16px;border:0}
body.workspace-crew .crew-power-card .power-primary-issues{padding:0;margin-top:14px}
body.workspace-crew .crew-power-card .power-primary-issues:empty{margin:0}
body.workspace-crew .crew-power-card .power-issue{padding:10px;border-radius:8px;background:#fff6da;min-width:0;margin:0 0 10px}
body.workspace-crew .crew-power-card .power-issue p{font-size:13px;line-height:1.5;overflow-wrap:anywhere}

/* Compact Crew shell. The map gets every pixel not used by a selected asset. */
body.workspace-crew{display:flex;flex-direction:column;height:100vh;height:100dvh;min-height:0;overflow:hidden;overscroll-behavior:none;background:var(--ui-sheet,#fff)}
body.workspace-redesign.workspace-crew .topbar{width:100%;max-width:480px;min-height:60px;flex:0 0 auto;margin:0 auto;padding:calc(8px + env(safe-area-inset-top,0px)) 10px 8px;gap:7px;flex-wrap:nowrap;z-index:1100}
body.workspace-redesign.workspace-crew .top-actions{width:auto;flex:0 0 auto;gap:2px}
body.workspace-crew .brand{flex:1;min-width:0;gap:8px}
body.workspace-crew .brand-project{min-width:0;padding-left:8px;gap:1px}
body.workspace-crew .brand-project strong{font-size:13px;line-height:1.25;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body.workspace-crew .brand-project span{font-size:10px;line-height:1.3}
body.workspace-crew .clean425-logo{width:78px;height:27px;flex-shrink:0}
body.workspace-crew #workspace-account-trigger,body.workspace-crew .crew-header-icon{width:44px;min-width:44px;min-height:44px;padding:11px;border:0;border-radius:9px;background:transparent;flex-shrink:0}
body.workspace-crew .crew-header-icon[aria-expanded=true],body.workspace-crew #workspace-account-trigger[aria-expanded=true]{background:#e8f3fa;color:var(--ui-blue,#036eb0)}
body.workspace-crew .crew-header-icon svg{width:21px;height:21px}
body.workspace-crew .crew-header-actions{display:flex;align-items:center;gap:2px}
body.workspace-crew :is(#workspace-progress-trigger,#workspace-commandbar,#workspace-close-card,#workspace-details-toggle,#workspace-legend-toggle,#project-tracking,.project-jump,.map-tools,.map-footer,.map-legend,.capture-note,.leaflet-control-zoom,#workflow-nav,.side-top){display:none!important}
body.workspace-crew .crew-header-popover{position:absolute;right:10px;top:calc(100% + 5px);z-index:1400;min-width:0;max-width:calc(100% - 20px);padding:10px;border:1px solid var(--ui-edge,#dee5eb);border-radius:12px;background:var(--ui-sheet,#fff);box-shadow:0 8px 30px #0e1d4226;color:var(--ui-ink,#0e1d42)}
body.workspace-crew .crew-header-popover[hidden]{display:none!important}
body.workspace-crew .crew-search-panel{width:calc(100% - 20px)}
body.workspace-crew .crew-search-panel .workspace-search-wrap{width:100%;max-width:none;min-width:0;position:relative}
body.workspace-crew .crew-search-panel #workspace-search{font-size:16px;min-height:44px;padding:10px 10px 10px 36px;line-height:1.4}
body.workspace-crew .crew-search-panel .workspace-search-wrap>svg{top:13px;left:11px}
body.workspace-crew .crew-search-panel .workspace-search-results{position:relative;inset:auto;width:100%;max-width:100%;min-width:0;max-height:min(360px,55dvh);margin-top:8px;border:0;border-radius:0;box-shadow:none;padding:0}
body.workspace-crew .crew-search-panel .workspace-search-results button{min-height:44px;font-size:13px;padding:10px 5px}
body.workspace-crew .crew-layers-panel{width:186px;display:grid;gap:4px}
body.workspace-crew .crew-popover-title{padding:4px 10px 7px;color:var(--ui-muted,#607082);font-size:12px;line-height:1.4;font-weight:400}
body.workspace-crew .crew-layer-choice{position:relative;width:100%;min-height:44px;padding:10px 34px 10px 10px;margin:0;justify-content:flex-start;border:0;font-size:14px;line-height:1.4}
body.workspace-crew .crew-layer-choice[aria-pressed=true]{background:#e8f3fa;color:var(--ui-blue,#036eb0)}
body.workspace-crew .crew-layer-choice[aria-pressed=true]::after{content:'✓';position:absolute;right:12px}
body.workspace-crew #workspace{width:100%;max-width:480px;height:auto;flex:1 1 auto;min-height:0;margin:0 auto;display:flex;flex-direction:column;position:relative;overflow:hidden;background:var(--ui-sheet,#fff);border:0;border-radius:0;padding-bottom:env(safe-area-inset-bottom,0px)}
body.workspace-crew #workspace>.map-area{order:0;position:relative;width:100%;height:auto;min-height:100px;min-width:0;display:flex;flex-direction:column;flex:1 1 auto;padding:0;overflow:hidden}
body.workspace-crew #workspace .map-stage{height:auto;min-height:0;max-height:none;position:relative;flex:1 1 auto;border-radius:0;overflow:hidden}
body.workspace-crew #workspace #map{position:absolute;inset:0;height:100%;min-height:0}
body.workspace-crew .crew-connection-dock{flex:0 0 auto;min-width:0;background:var(--ui-sheet,#fff);border-top:1px solid var(--ui-edge,#dee5eb)}
body.workspace-crew:not(.crew-connecting) .crew-connection-dock{display:none!important}
body.workspace-redesign.workspace-crew .crew-connection-dock .connection-toolbar{position:relative;inset:auto;width:100%;max-width:none;padding:8px 12px;border:0;border-radius:0;box-shadow:none;background:#f2f7fb;display:block;font-size:13px;line-height:1.45}
body.workspace-crew .crew-connection-dock .connection-toolbar[hidden]{display:none!important}
body.workspace-crew .crew-connection-dock .connection-toolbar-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
body.workspace-crew .crew-connection-dock .connection-toolbar button{font-size:13px;line-height:1.4;min-height:44px;margin:0;padding:8px 12px}
body.workspace-crew .crew-connection-dock [data-connect-mode-toggle]{flex:1}
body.workspace-crew .crew-connection-dock .connection-toolbar p{margin:7px 0 0;max-width:none;font-size:12px;line-height:1.45}
body.workspace-crew .crew-connection-dock .connection-toolbar label{display:flex;align-items:center;gap:8px;margin:8px 0 0;font-size:13px;line-height:1.45}
body.workspace-crew .crew-connection-dock .connection-toolbar select{flex:1;max-width:none;width:auto;min-height:44px;font-size:16px}
body.workspace-crew .crew-connection-dock .connection-input-settings>summary{width:44px;height:44px}
body.workspace-crew .crew-connection-dock .connection-input-settings>div{top:auto;bottom:calc(100% + 4px);left:auto;right:12px}
body.workspace-crew #workspace>.sidebar{order:1;position:relative;inset:auto;width:100%;height:min(46dvh,400px);max-width:none;max-height:calc(100% - 100px);flex:0 0 auto;min-height:0;display:none;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;margin:0;padding:0 0 12px;background:var(--ui-sheet,#fff);box-shadow:0 -3px 16px #0e1d4214;border:0;border-top:1px solid var(--ui-edge,#dee5eb);border-radius:16px 16px 0 0}
body.workspace-crew.crew-has-selection #workspace>.sidebar,body.workspace-crew.crew-has-selection.workspace-card-hidden #workspace>.sidebar{display:block}
body.workspace-crew.crew-sheet-expanded #workspace>.sidebar{height:min(72dvh,640px)}
body.workspace-crew:not(.crew-has-selection) #workspace>.sidebar{display:none!important}
body.workspace-crew .crew-sheet-actions{position:sticky;top:0;z-index:4;display:flex;align-items:center;gap:8px;min-height:44px;padding:0 8px 0 12px;border-bottom:1px solid var(--ui-edge,#dee5eb);background:var(--ui-sheet,#fff)}
body.workspace-crew .crew-sheet-toggle{display:flex;flex:1;min-height:44px;margin:0;padding:8px 4px;justify-content:flex-start;gap:6px;border:0;border-radius:0;background:transparent;color:var(--ui-muted,#607082);font-size:12px;line-height:1.4}
body.workspace-crew .crew-sheet-toggle svg{width:17px;height:17px;transform:rotate(180deg)}
body.workspace-crew.crew-sheet-expanded .crew-sheet-toggle svg{transform:none}
body.workspace-crew .crew-sheet-close{width:44px;min-width:44px;min-height:44px;margin:0;padding:12px;border:0;border-radius:9px;background:transparent}
body.workspace-crew .crew-sheet-close svg{width:18px;height:18px}
body.workspace-crew :is(#side-content,#power-content){padding:0;overflow:visible;max-height:none;min-width:0}
body.workspace-crew .crew-tree-card{padding:0 14px 14px!important;width:100%;max-width:none;min-width:0}
body.workspace-crew .crew-tree-card .asset-card-head{margin:0 -14px 12px;padding:12px 14px;gap:7px}
body.workspace-crew .crew-tree-card .asset-heading{padding-right:0}
body.workspace-crew .crew-tree-card .asset-heading h2{font-size:21px}
body.workspace-crew #tree-form{margin:0;padding:0;min-width:0}
body.workspace-crew .crew-quick-controls{gap:12px;margin-bottom:12px}
body.workspace-crew .crew-quick-label{margin-bottom:5px;font-size:12px}
body.workspace-crew .crew-choice{min-height:44px;font-size:13px}
body.workspace-crew .crew-choice-row.crew-four-choices{grid-template-columns:repeat(4,minmax(0,1fr));gap:5px}
body.workspace-crew .crew-choice-row.crew-four-choices .crew-choice{font-size:12px;padding:7px 4px}
body.workspace-crew .crew-wrap-control{min-height:44px}
body.workspace-crew .crew-connect-entry{width:100%;min-height:44px;justify-content:center;font-size:13px;background:#fff8dd;border-color:#eee0a8;color:#64531e}
body.workspace-crew:not(.crew-sheet-expanded) :is(.crew-source-summary,.crew-access-summary,.crew-power-city,.crew-secondary-actions,.crew-note-editor,.asset-photos,.crew-tree-navigation,.power-pole-details){display:none!important}
body.workspace-crew .crew-power-card{padding:12px 14px!important}
body.workspace-crew .crew-power-card .power-asset-head{padding-bottom:12px}
body.workspace-crew .crew-power-card .crew-quick-controls{margin:12px 0}
body.workspace-crew .asset-issues{margin:0 -14px 12px!important;padding:12px 14px!important}
body.workspace-crew .asset-issues .report-row{min-width:0;overflow-wrap:anywhere}
body.workspace-crew .power-search{padding:12px 14px 0;margin:0 0 12px}
body.workspace-crew .power-search input{font-size:16px;min-height:44px}
body.workspace-crew .power-search select{display:none}
body.workspace-crew .direct-flow-panel{display:block!important;padding:14px!important;min-width:0;scroll-margin-top:44px}
body.workspace-crew .direct-flow-panel[hidden]{display:none!important}
body.workspace-crew .direct-flow-panel .direct-edge-card,body.workspace-crew .direct-flow-panel .direct-flow-confirm{margin:10px 0 0;padding:12px;min-width:0;overflow-wrap:anywhere}
body.workspace-crew .direct-flow-panel :is(button,p){font-size:13px;line-height:1.5}
body.workspace-crew .direct-flow-panel h4{font-size:14px;line-height:1.45;margin:0 0 8px}
body.workspace-crew #workspace .map-message{left:10px;right:64px;top:10px;max-width:none}
body.workspace-crew .leaflet-control-attribution{max-width:100%;font-size:10px;line-height:1.4}
body.workspace-crew #workspace button{min-height:44px}
body.workspace-crew #workspace .crew-source-summary .asset-feed-link button{min-height:44px;justify-content:flex-start;text-align:left}
body.workspace-crew #workspace .power-card-heading>[data-close-card]{min-width:44px;min-height:44px}
body.workspace-crew #toast{bottom:calc(16px + env(safe-area-inset-bottom,0px));max-width:calc(100vw - 24px);font-size:13px;line-height:1.5}
body.workspace-crew #power-content :is(.power-advanced-flow,.power-key-details,.power-browser){display:none!important}
@media(max-width:360px){body.workspace-redesign.workspace-crew .topbar{padding-left:8px;padding-right:8px;gap:4px}body.workspace-crew .brand{gap:5px}body.workspace-crew .clean425-logo{width:66px;height:24px}body.workspace-crew .brand-project{padding-left:5px}body.workspace-crew .brand-project strong{font-size:12px}body.workspace-crew .brand-project span{font-size:10px}}
@media(max-height:540px){body.workspace-crew #workspace>.sidebar{height:51dvh}body.workspace-crew.crew-sheet-expanded #workspace>.sidebar{height:calc(100% - 100px)}}

body.workspace-crew .power-pole-details{margin:14px 0 0;border-top:1px solid var(--ui-edge,#dee5eb);padding:0}
body.workspace-crew .power-pole-details>summary{min-height:44px;padding:12px 0;font-size:14px;line-height:1.5}
body.workspace-crew .power-pole-details :is(input,textarea,select){font-size:16px;min-height:44px}
body.workspace-crew .power-pole-details .power-form-grid{grid-template-columns:minmax(0,1fr);gap:12px}
body.workspace-crew .power-pole-details .power-note-actions{display:flex;flex-wrap:wrap;gap:8px;justify-content:space-between}
body.workspace-crew .crew-power-card [data-close-card]{display:none!important}

/* Saves stay visible without occupying the field map's compact header. */
body.workspace-crew .crew-save-status{position:absolute;z-index:650;top:10px;left:10px;max-width:calc(100% - 68px)}
body.workspace-crew .crew-save-status[hidden],body.workspace-crew .crew-save-panel[hidden]{display:none!important}
body.workspace-crew .crew-save-status-toggle{min-height:36px;margin:0;padding:7px 12px;border:1px solid #d7e5ed;border-radius:18px;background:#193b50;color:#f5fafc;font-size:12px;line-height:1.4;box-shadow:0 2px 10px #142d4326}
body.workspace-crew .crew-save-status.has-errors .crew-save-status-toggle{background:#842e33;border-color:#efcccc}
body.workspace-crew .crew-save-panel{position:absolute;top:calc(100% + 7px);left:0;width:min(310px,calc(100vw - 32px));max-height:38dvh;overflow:auto;overscroll-behavior:contain;padding:13px;border:1px solid #d7e5ed;border-radius:12px;background:#fff;color:#193b50;box-shadow:0 5px 24px #142d4333;font-size:12px;line-height:1.5}
body.workspace-crew .crew-save-panel p{margin:7px 0;overflow-wrap:anywhere}
body.workspace-crew .crew-save-problem{border-top:1px solid #e3e9ed;margin-top:10px;padding-top:4px}
body.workspace-crew .crew-save-problem button{min-height:44px;width:100%;margin:4px 0 0;padding:8px 12px;font-size:13px;color:#842e33;border-color:#dbbfc1;background:#fff7f7}
