.rc-card { box-sizing:border-box; inline-size:100%; min-inline-size:0; margin:8px 0; padding:13px; border:1px solid #d4dee8; border-radius:14px; background:#fff; color:#193451; overflow-wrap:anywhere; }
button.rc-link { display:grid; grid-template-columns:24px minmax(0,1fr) auto; gap:12px; align-items:center; text-align:start; min-height:52px; }
.rc-link > span:last-child { font-size:1.3em; color:#315d89; }
.rc-heading { display:flex; gap:8px; align-items:center; min-width:0; }
.rc-heading > div { flex:1; min-width:0; }
.rc-heading strong { font-weight:700; }
.rc-card small,.rc-heading small { display:block; color:#526779; font-size:.85em; }
.rc-icon { width:23px;height:23px;flex:none;fill:none;stroke:#315d89;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round; }
.rc-category { font-size:.95em; margin:14px 0 4px; }
.rc-card hr,.rc-oil-completion hr { border:0;border-top:1px solid #dce4ea;margin:9px 0; }
.rc-pair { display:flex;justify-content:space-between;gap:12px;align-items:baseline;padding:3px 0; }
.rc-pair strong { text-align:end; }
.rc-card input,.rc-card select,.rc-oil-completion input,.rc-oil-completion select { width:100%;min-width:0;box-sizing:border-box; }
.rc-stock-fields { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px; }
.rc-options { margin-top:9px; }
.rc-options summary { list-style:none;border:1px solid #d4dee8;border-radius:9px;padding:9px;cursor:pointer; }
.rc-options summary::-webkit-details-marker { display:none; }
.rc-options summary::after { content:'⌄';float:right; }
.rc-options[open] summary::after { content:'⌃'; }
.rc-option { padding:8px 0;border-bottom:1px solid #e3e9ef; }
.rc-negative { color:#a32918; }
.rc-positive { color:#186745; }
dialog.rc-complete { background:white;border:1px solid #d4dee8;border-radius:14px; }
.rc-oil-completion { border:0;padding:0;margin:8px 0;min-width:0; }
.rc-oil-completion[hidden] { display:none; }
.rc-oil-completion legend { font-weight:700; }
button.rc-confirm { inline-size:100%;background:#18232e;color:#fff;border-radius:10px; }
@media(max-width:345px){ .rc-stock-fields{grid-template-columns:1fr} }
.rc-completion-heading,.rc-completion-divider { display:none; }
form.rc-complete > .rc-completion-heading { display:flex; }
form.rc-complete > .rc-completion-divider { display:block; }
dialog:has(form.rc-complete) { background:white;border:1px solid #d4dee8;border-radius:14px; }
.app-shell .rc-oil-completion label { display:block; }
.app-shell .rc-oil-completion label[hidden],.rc-oil-completion button[hidden] { display:none; }
dialog.service-dialog .rc-oil-completion label select,
dialog.service-dialog .rc-oil-completion label input { width:100%;max-width:none; }
dialog.service-dialog button.rc-confirm[type=submit] { background:#18232e;color:#fff; }

/* Scoped lubrication chart toolbar: equal cells, no global button changes. */
.rc-chart-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); grid-auto-rows:1fr; gap:8px; margin:8px 0 14px; }
.rc-chart-actions > button { box-sizing:border-box; width:100%; min-width:0; min-height:48px; margin:0; padding:8px; text-align:center; justify-content:center; align-items:center; white-space:normal; overflow-wrap:anywhere; }

.pad-service-next-hours{font-weight:700;display:inline-block;margin-right:8px;color:#18334b}
.pad-service-next-hours.late{color:#b42318}
.service-info.service-early-warning{color:#b42318!important;border-color:#b42318!important}
@media(max-width:700px){.service-dialog{max-width:calc(100vw - 24px);width:calc(100vw - 24px)}}
/* RC23 service preview: consistent compact equipment summary. */
.pad-service-next-hours{display:inline-flex;flex-direction:column;gap:3px;padding:8px 12px;border:1px solid #d5e0e9;border-radius:12px;background:#fff;color:#18334b;vertical-align:middle;line-height:1.45}
.pad-service-next-hours strong{font-weight:700}
.pad-service-next-hours.late{border-color:#b42318;color:#b42318}
.service-info.service-early-warning{background:#b42318!important;color:#fff!important}
.service-dialog{width:min(94vw,640px);max-width:640px;box-sizing:border-box}
.service-dialog form{width:100%;max-width:100%;box-sizing:border-box}
.service-dialog input,.service-dialog select,.service-dialog textarea{max-width:100%;box-sizing:border-box}

/* Scoped upcoming-service presentation; do not affect other inventories. */
.pad-service-next-hours{display:flex;flex-direction:column;gap:4px;padding:12px 14px;border:1px solid #d5e0e9;border-radius:14px;background:#fff;margin:6px 0;min-width:0}
.pad-service-next-hours strong{font-size:.92rem;color:#355b7e}
.pad-service-next-hours>div{font-size:1.12rem;font-weight:700;color:#19354f}
.service-conflict-details{padding:10px 12px;border:1px solid #c83d32;border-radius:10px;margin:12px 0}
.service-conflict-details h3{color:#b42318;margin:0 0 8px}
.service-conflict-details p{margin:5px 0}

/* Consistent service summary for generators and watermaker */
.rc-water-service-summary{margin:8px 0;padding:14px;border:1px solid #d5e0e9;border-radius:14px;background:#fff}
.rc-water-service-stats{margin:10px 0}
.rc-water-service-summary>.service-info{margin-top:8px}
.pad-service-next-hours>small{font-size:.84rem;color:#526779}

/* Watermaker information: keyboard-accessible expandable service tasks. */
.rc-water-service-task>summary{cursor:pointer;font-weight:650;padding:8px 0;color:#315d89}
.rc-water-service-task>summary:focus-visible{outline:2px solid #315d89;outline-offset:3px}
.rc-water-service-task[open]>summary{margin-bottom:8px}

/* Unified layout for every stock inventory, scoped to this view only. */
.rc-unified-inventory{display:flex;flex-direction:column;gap:12px;min-width:0}
.rc-unified-inventory-title{margin:0}
.rc-unified-inventory-toolbar{display:flex;flex-direction:column;gap:10px}
.rc-unified-inventory-add{align-self:flex-start}
.rc-unified-inventory-exports{display:flex;flex-wrap:wrap;gap:8px}
.rc-unified-inventory table{width:100%}
.rc-unified-inventory>div{max-width:100%}

/* RC23 approved compact upcoming-service appearance; scoped to service cards only */
.pad-service-reference-card{display:flex;flex-direction:column;gap:14px;border:1px solid var(--border,#d6dce4);border-radius:18px;padding:20px;max-width:100%;background:var(--card,#fff)}
.pad-service-reference-top,.pad-service-reference-foot{display:flex;justify-content:space-between;align-items:center;gap:12px}
.pad-service-reference-top strong{font-size:1.12rem}.pad-service-reference-top small{color:var(--muted,#777)}
.pad-service-reference-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.pad-service-reference-stats>div{display:flex;flex-direction:column;gap:7px}
.pad-service-reference-stats small{color:var(--muted,#777)}
.pad-service-reference-stats strong{font-size:clamp(1.3rem,2.4vw,2rem);font-weight:650;font-variant-numeric:tabular-nums}
.pad-service-reference-foot .service-info{border-radius:22px;padding:8px 14px}
.service-plan-row{display:grid;grid-template-columns:repeat(5,minmax(120px,1fr));gap:10px;align-items:start;min-width:0}
.service-plan-row>label{min-width:0}.service-plan-row input,.service-plan-row select{max-width:100%;min-width:0}
.rc-service-rule-fields{grid-column:1/-1;display:grid;grid-template-columns:repeat(auto-fit,minmax(165px,1fr));gap:10px;align-items:start;padding:12px;border-top:1px solid var(--border,#ddd)}
.rc-service-rule-fields>label{min-width:0}
@media(max-width:850px){.service-plan-row{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:450px){.service-plan-row{grid-template-columns:minmax(0,1fr)}.pad-service-reference-card{padding:14px}}

/* RC23 inventory correction: same hierarchy as Oil Inventory, scoped to chemical/custom stock. */
.rc-unified-inventory{gap:12px;align-items:stretch}
.rc-unified-inventory>.rc-inventory-primary{align-self:flex-start;max-width:100%;min-height:44px}
.rc-unified-inventory>.pad-data-export{display:flex;flex-wrap:wrap;gap:8px;margin:0}
.rc-unified-inventory>.pad-list-search{display:block;width:100%;max-width:680px;box-sizing:border-box;padding:12px;border:1px solid #b8cbdc;border-radius:10px;font:inherit}
.rc-unified-inventory .pad-shared-list{max-width:100%;min-width:0}
\n/* Inventory stock cards: match approved Oil Inventory read-only stock fields */\n.rc-oil-layout .rc-inventory-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,310px),1fr));gap:14px;margin-top:16px}.rc-oil-layout .rc-inventory-stock-card{min-width:0}.rc-oil-layout .rc-inventory-stock-card[hidden]{display:none!important}.rc-oil-layout .rc-inventory-stock-card .rc-stock-fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:10px}.rc-oil-layout .rc-inventory-stock-card input[readonly]{width:100%}\n
/* Upcoming Service: one full-width card per equipment; no legacy table columns. */
.rc-upcoming-table,.rc-upcoming-table tbody,.rc-upcoming-table tr,.rc-upcoming-table td{display:block;width:100%;border:0;background:transparent;box-sizing:border-box}
.rc-upcoming-table tr{margin:0 0 16px}.rc-upcoming-table td{padding:0!important}.rc-upcoming-scroll{overflow:visible!important}.rc-upcoming-table .pad-service-reference-card{width:100%;max-width:none;cursor:pointer}.rc-upcoming-table .pad-service-reference-card:focus-visible{outline:3px solid #2877b8;outline-offset:3px}
\n.rc-unified-inventory .rc-inventory-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,320px),1fr));gap:14px;margin:16px 0}.rc-unified-inventory .rc-inventory-stock-card[hidden]{display:none!important}.rc-unified-inventory .rc-stock-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.rc-unified-inventory .rc-stock-fields input{width:100%}\n
/* Service fields: stable alignment and equal control heights. */
.service-plan-row,.rc-service-rule-fields{align-items:start;grid-auto-flow:row}
.service-plan-row>label,.rc-service-rule-fields>label{display:flex;flex-direction:column;gap:6px;min-width:0}
.service-plan-row input,.service-plan-row select,.rc-service-rule-fields input,.rc-service-rule-fields select{box-sizing:border-box;width:100%;min-height:40px}

/* Approved Upcoming Service card: title/info above divider; next/remaining below. */
.pad-service-reference-card .pad-service-reference-top{display:flex;align-items:center;justify-content:space-between;gap:12px}
.pad-service-reference-card .pad-service-reference-top .service-info{margin-left:auto;flex-shrink:0}
.pad-service-reference-card>hr{border:0;border-top:1px solid var(--border,#d6dce4);width:100%;margin:0}
.pad-service-reference-card .pad-service-reference-stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.pad-service-reference-card .pad-service-reference-stats strong{overflow-wrap:anywhere}
.service-plan-row{grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}
.service-plan-row>label{display:flex;flex-direction:column;gap:6px;min-width:0}
.service-plan-row .rc-service-rule-fields{grid-column:1/-1}
@media(max-width:500px){.service-plan-row{grid-template-columns:minmax(0,1fr)}.pad-service-reference-card .pad-service-reference-stats{gap:10px}}

/* Upcoming Service RC23 — approved generator-card layout for EVERY asset.
   Scoped styles: do not affect buttons, tables, or cards in other views. */
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary){
 box-sizing:border-box; width:100%; max-width:none; min-width:0;
 margin:0; padding:20px; gap:0; display:flex; flex-direction:column;
 border:1px solid #d6dce4; border-radius:18px; background:#fff;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-top{
 display:flex; justify-content:space-between; align-items:flex-start;
 min-height:50px; gap:12px;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-top>strong{
 color:#2c4f6e; font-size:1rem; line-height:1.4; font-weight:700;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary)>hr{
 border:0; border-top:1px solid #e1e4e6; margin:4px 0 28px; width:100%;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-stats{
 display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin:0 0 24px;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-stats>div{display:flex;flex-direction:column;gap:6px;min-width:0}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-stats small{
 font-size:.78rem;line-height:1.35;color:#66717c;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-stats strong{
 font-size:1rem;line-height:1.4;font-weight:700;color:#2c4f6e;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-foot{
 display:flex;align-items:center;justify-content:flex-start;min-height:26px;margin:0;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-foot>strong{
 font-size:1.08rem;line-height:1.4;font-weight:700;color:#18334b;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-top>button.service-info{
 box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;
 flex:0 0 28px; width:28px;height:28px;min-height:28px;min-width:28px;
 padding:0;margin:0;border:1px solid transparent;border-radius:50%;
 background:transparent;color:#19354f;font-size:14px;line-height:1;font-weight:700;
}
:is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary) .pad-service-reference-top>button.service-info.service-early-warning{
 background:transparent!important;color:#b42318!important;border-color:transparent!important;
}
@media(max-width:500px){
 :is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary){padding:14px}
 :is(.rc-upcoming-table .pad-service-reference-card, #panel > .rc-water-service-summary)>hr{margin-bottom:20px}
}

/* Service planning form — approved alignment; scoped to Equipment > Service Planning only. */
#equipment-service-plan .service-plan-row{display:flex;flex-direction:column;align-items:stretch;gap:14px;padding:18px 0;margin:0;border-top:1px solid #d6e0e8;min-width:0}
#equipment-service-plan .pad-service-primary-fields,
#equipment-service-plan .pad-service-material-fields,
#equipment-service-plan .rc-service-rule-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));align-items:start;gap:12px;width:100%;min-width:0}
#equipment-service-plan .pad-service-primary-fields{grid-template-columns:minmax(0,2fr) minmax(0,1fr)}
#equipment-service-plan .pad-service-material-fields{padding:10px 0;border-top:1px solid #ebeff3}
#equipment-service-plan .rc-service-rule-fields{padding:12px 0;border-top:1px solid #e3eaf0}
#equipment-service-plan .service-plan-row label{display:flex;flex-direction:column;gap:6px;min-width:0;margin:0;align-items:stretch}
#equipment-service-plan .service-plan-row label[hidden],
#equipment-service-plan .rc-service-rule-fields label[hidden]{display:none!important}
#equipment-service-plan .service-plan-row input,
#equipment-service-plan .service-plan-row select{box-sizing:border-box;min-width:0;width:100%;min-height:42px}
#equipment-service-plan .pad-service-remove-task{align-self:flex-end;margin:0}
@media (max-width:760px){
 #equipment-service-plan .pad-service-material-fields,
 #equipment-service-plan .rc-service-rule-fields{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:480px){
 #equipment-service-plan .pad-service-primary-fields,
 #equipment-service-plan .pad-service-material-fields,
 #equipment-service-plan .rc-service-rule-fields{grid-template-columns:minmax(0,1fr)}
}

/* Oil inventory regression fix, scoped to the lubrication views only. */
.rc-chart-layout,.rc-oil-layout{display:flex;flex-direction:column;gap:12px;min-width:0}
.rc-chart-layout>.pad-data-export,.rc-oil-layout>.pad-data-export{display:flex;flex-wrap:wrap;gap:8px}
.rc-chart-layout>.pad-list-search,.rc-oil-layout>.pad-list-search{width:100%;max-width:680px;box-sizing:border-box;padding:12px;border:1px solid #b8cbdc;border-radius:10px;font:inherit}
.rc-chart-categories,.rc-oil-stock-groups{display:flex;flex-direction:column;gap:16px}
.rc-chart-category[hidden],.rc-chart-equipment-card[hidden],.rc-oil-stock-group[hidden]{display:none!important}
.rc-chart-equipment-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;min-width:0}
.rc-chart-equipment-head>.rc-heading{flex:1;min-width:0}
.rc-chart-amount{display:flex;flex-direction:column;align-items:flex-end;gap:3px;flex-shrink:0;text-align:end}
.rc-chart-amount strong{font-size:1.04rem;white-space:nowrap}
.rc-chart-totals{margin-top:8px}
.rc-chart-totals h4,.rc-chart-category h4,.rc-oil-stock-group h4{margin:8px 0}
.rc-oil-layout .rc-inventory-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,310px),1fr));gap:14px}
.rc-oil-layout .rc-inventory-stock-card[hidden]{display:none!important}
.rc-oil-layout .rc-inventory-stock-card .rc-stock-fields{margin:10px 0}
.rc-oil-existing-status{font-size:.87rem;color:#355b7e;margin:4px 0 8px}
@media(max-width:500px){.rc-chart-equipment-head{align-items:flex-start}.rc-chart-amount{max-width:40%}}

/* Lubrication Chart: breathing room between lubricant options and its Edit button. Scoped; no impact on other actions. */
.rc-chart-equipment-card > .rc-options + button { margin-top:12px; }

/* Oil Inventory: separate edit and remove actions, scoped to stock cards only. */
.rc-oil-layout .rc-oil-stock-actions{display:flex;flex-wrap:wrap;gap:12px;margin-top:12px;align-items:center}
.rc-oil-layout .rc-oil-stock-actions>button{min-height:40px}
.rc-oil-layout .rc-oil-stock-remove{background:#fff;color:#a52e38;border:1px solid #ca8b93}
.rc-oil-layout .rc-oil-stock-remove:hover{background:#fff3f4}

/* Chart actions: consistent margins/vertical alignment, no global button overrides. */
.rc-chart-equipment-card .rc-options > .rc-add-commercial { display:block; width:max-content; max-width:100%; min-height:40px; margin:12px 0 4px; white-space:normal; text-align:left; }
.rc-chart-equipment-card .rc-options .rc-unverified-candidate {display:flex;flex-direction:column;align-items:flex-start;gap:6px;min-width:0;}
.rc-chart-equipment-card .rc-options .rc-candidate-warning {font-size:.875rem;line-height:1.45;color:#755a23;background:#fff9e7;border:1px solid #e8d8a2;border-radius:8px;padding:10px;margin:12px 0;}
.rc-chart-equipment-card .rc-options .rc-candidate-action {min-height:36px;margin:4px 0;}
.rc-chart-equipment-card .rc-options .rc-option > a {font-size:.85rem;overflow-wrap:anywhere;}

/* RC23 lubricant option search and scoped product-dialog alignment only. */
.rc-options .rc-option-search {display:block;box-sizing:border-box;width:100%;min-height:44px;margin:12px 0 5px;padding:10px 12px;border:1px solid #aebfce;border-radius:9px;font:inherit;background:#fff;color:#102636}
.rc-options .rc-options-count{display:block;color:#546678;margin:4px 0 8px}
.rc-options .rc-options-results{display:flex;flex-direction:column;gap:4px}
.rc-options .rc-option[hidden],.rc-options .rc-options-empty[hidden]{display:none!important}
.rc-options .rc-option{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px 10px;align-items:center;padding:11px 0}
.rc-options .rc-option strong,.rc-options .rc-option small{min-width:0;overflow-wrap:anywhere}
.rc-options .rc-option>small{grid-column:1;grid-row:2}
.rc-options .rc-option>button{grid-column:2;grid-row:1 / span 2;min-height:38px;max-width:100%}
.rc-options .rc-unverified-candidate{display:flex;flex-direction:column;align-items:flex-start}
.rc-options .rc-unverified-candidate>button{align-self:flex-start}
.rc-chart-equipment-card .rc-options>.rc-add-commercial{display:flex;align-items:center;justify-content:center;text-align:center;width:100%;box-sizing:border-box;min-height:44px;margin:14px 0 4px;white-space:normal}
.rc-product-dialog {box-sizing:border-box;width:min(760px,95vw)!important;}
.rc-product-dialog form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 18px;align-items:start}
.rc-product-dialog form>label{display:flex;flex-direction:column;gap:6px;min-width:0;margin:0;font-weight:600;line-height:1.35}
.rc-product-dialog form>label input,.rc-product-dialog form>label select,.rc-product-dialog form>label textarea{display:block;box-sizing:border-box;width:100%;min-width:0;min-height:44px;padding:10px;margin:0;font:inherit;font-weight:400;border-radius:8px}
.rc-product-dialog form>label:nth-of-type(5){grid-column:1 / -1}
.rc-product-dialog form>[role=alert]{grid-column:1 / -1;margin:0}
.rc-product-dialog form>button[type=submit]{grid-column:2;justify-self:stretch;min-height:44px;margin:0}
.rc-duplicate-notice {border:1px solid #e6bf77;border-radius:10px;padding:10px 14px;background:#fff8e9;overflow-wrap:anywhere}
.rc-duplicate-notice summary{font-weight:650;cursor:pointer}
.rc-duplicate-notice p{margin:8px 0;font-size:.88rem}
@media (max-width:620px){.rc-product-dialog form{grid-template-columns:minmax(0,1fr)}.rc-product-dialog form>label:nth-of-type(5),.rc-product-dialog form>[role=alert],.rc-product-dialog form>button[type=submit]{grid-column:1}}

/* Watermaker equipment instructions: independent of Scheduled Service. */
.pad-watermaker-guide{border:1px solid #cad9e7;border-radius:10px;background:#f7fafc;padding:0 12px 12px;margin:12px 0 18px;max-width:100%;overflow-wrap:anywhere}
.pad-watermaker-guide>summary{cursor:pointer;color:#173b58;font-weight:700;font-size:1.04rem;padding:14px 2px;min-height:44px}
.pad-watermaker-guide section{padding:4px 8px 7px;border-top:1px solid #dce5ed}
.pad-watermaker-guide h4{margin:8px 0;color:#173b58}
.pad-watermaker-guide ol{margin:6px 0 6px 18px;padding:0}
.pad-watermaker-guide li{padding:5px 0 8px}
.pad-watermaker-guide li p{margin:3px 0 0;white-space:normal}
.pad-watermaker-provenance{border-top:1px solid #dce5ed;margin:10px 0 0;padding-top:10px;color:#516473;font-size:.88rem}

/* Battery Inventory only: readable system path on narrow screens. */
.rc-inventory-stock-card .rc-battery-system{display:grid;grid-template-columns:minmax(0,1fr);gap:4px;margin:6px 0 10px;min-width:0}
.rc-inventory-stock-card .rc-battery-system span{font-size:.8rem;color:#52677b}
.rc-inventory-stock-card .rc-battery-system strong{font-size:.93rem;line-height:1.35;overflow-wrap:anywhere;white-space:normal}

/* RC23 visual QA: scoped fixes for controls that already touched or overflowed in production. */
.rc-unified-inventory .rc-inventory-stock-card:has(> .rc-chemical-delete) > button{min-height:44px;max-width:100%;margin:12px 0 0;white-space:normal;overflow-wrap:anywhere;vertical-align:middle}
.rc-unified-inventory .rc-inventory-stock-card > .rc-chemical-delete{margin-inline-start:12px!important}
.equipment-technical-form{grid-template-columns:repeat(auto-fit,minmax(min(100%,220px),1fr));min-width:0;align-items:stretch}
.equipment-technical-form > label{min-width:0;margin-inline:0;grid-template-rows:1fr auto;align-content:stretch;overflow-wrap:anywhere}
.equipment-technical-form > label > input,.equipment-technical-form > label > select,.equipment-technical-form > label > textarea{width:100%;min-width:0;max-width:100%;box-sizing:border-box;font:inherit}
.equipment-technical-form > label > input:not([type=file]){min-height:44px}
.equipment-technical-form > label:has(>input[type=file]){grid-column:1/-1}
.equipment-technical-form > .equipment-photo-grid,.equipment-technical-form > [role=status]{grid-column:1/-1;min-width:0}
.equipment-technical-form > button{min-height:44px;min-width:0;max-width:100%;white-space:normal;overflow-wrap:anywhere;align-self:end}
.equipment-technical-form > .equipment-photo-grid:empty,.equipment-technical-form > [role=status]:empty{display:none}
.equipment-technical-form input[type=file]::file-selector-button{font:inherit}

/* Oil-type chooser: keep Close separate and align all type buttons in a responsive grid. */
.rc-oil-types-dialog > button{margin:0 0 14px;min-height:44px}
.rc-oil-types-actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,210px),1fr));gap:12px;align-items:stretch;min-width:0}
.rc-oil-types-actions > button{margin:0;width:100%;min-width:0;min-height:44px;white-space:normal;overflow-wrap:anywhere;text-align:center;font:inherit}

/* Scoped photo-quality controls; existing dialog layout preserved. */
.pad-photo-quality{display:flex!important;align-items:center;gap:8px;flex-wrap:wrap;margin:8px 0 12px!important;font:inherit;line-height:1.35;max-width:100%;overflow-wrap:anywhere}.pad-photo-quality input[type=checkbox]{width:auto!important;min-width:16px;flex:0 0 auto;margin:0!important}

/* Scoped UAT Share & Delegate panel only. */
.pad-delegate-host .pad-delegate-panel fieldset{margin:12px 0;padding:12px;min-width:0;border:1px solid currentColor;border-radius:8px}.pad-delegate-host .pad-delegate-panel label{display:block;margin:8px 0}.pad-delegate-host .pad-delegate-panel input:not([type=checkbox]),.pad-delegate-host .pad-delegate-panel textarea{max-width:100%;box-sizing:border-box}.pad-delegate-host .pad-delegate-panel textarea{width:100%;min-height:80px}.pad-delegate-host .pad-delegate-panel button,.pad-delegate-host .pad-delegate-panel a{margin:4px;padding:8px 10px}.pad-delegate-host .pad-delegate-panel pre{white-space:pre-wrap;overflow-wrap:anywhere}

/* Scoped material picker: no changes to existing service/inventory forms. */
.pad-delegate-host .pad-delegate-panel select{display:block;width:100%;max-width:100%;box-sizing:border-box;font:inherit;padding:8px;margin-top:4px}.pad-delegate-host .pad-delegate-panel [data-valid="false"]{color:#b43c28}.pad-delegate-host .pad-delegate-panel [data-valid="true"]{font-weight:600}.pad-delegate-host .pad-delegate-panel input[type="number"]{display:block;width:min(100%,160px);margin-top:4px}
/* Share & Delegate: preserve hidden state in the scoped form layout. */
.pad-delegate-panel [hidden]{display:none!important}

/* Scoped layout correction: Handover navigation is outside the scroll body. */
dialog.pad-handover-dialog:has(>.pad-ho-fixed)[open]{display:flex;flex-direction:column;overflow:hidden!important;max-height:85vh;max-height:85dvh!important;min-height:0;box-sizing:border-box}
.pad-handover-dialog>.pad-ho-fixed{flex:0 0 auto;min-width:0;background:#fff;z-index:1}
.pad-handover-dialog>.pad-ho-fixed>.pad-ho-header{margin-bottom:0}
.pad-handover-dialog>.pad-ho-fixed>.pad-ho-tabs{margin:8px 0 0;padding-bottom:8px}
.pad-handover-dialog>.pad-ho-scroll{flex:1 1 auto;min-height:0;min-width:0;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;padding-top:8px}
.pad-handover-dialog>.pad-ho-scroll>.pad-ho-print{margin:22px 0!important}
.pad-ho-fixed .pad-ho-close{min-height:44px}
@media(max-height:500px){.pad-handover-dialog>.pad-ho-fixed>.pad-ho-header{padding:7px 10px}.pad-ho-fixed .pad-ho-header h2{font-size:18px}.pad-ho-fixed .pad-ho-header p{font-size:12px}.pad-ho-fixed .pad-ho-close{top:4px;right:4px}.pad-ho-fixed .pad-ho-tabs{grid-template-columns:repeat(4,minmax(0,1fr));gap:4px;margin-top:4px!important;padding-bottom:4px!important}.pad-ho-fixed .pad-ho-tabs button{font-size:12px;padding:5px 2px;min-height:44px}}
/* Consistent action grid only in the three requested sections. */
#panel .section-banner>.system-actions,#panel .section-banner>.pad-storage-toolbar,#panel .section-banner>.pad-vendor-banner-actions{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch!important;gap:12px;flex:1 1 100%;width:100%;min-width:0;margin:0!important}
#panel .section-banner>.system-actions>button,#panel .section-banner>.pad-storage-toolbar>button,#panel .section-banner>.pad-vendor-banner-actions>button{width:100%;max-width:100%;min-width:0;min-height:44px;margin:0!important;align-self:stretch;white-space:normal;overflow-wrap:anywhere;text-align:center;box-sizing:border-box}
#panel .section-banner>.pad-vendor-banner-actions>button:last-child{grid-column:1/-1}
@media(min-width:900px){#panel .section-banner>.pad-storage-toolbar{grid-template-columns:repeat(4,minmax(0,1fr))}#panel .section-banner>.pad-vendor-banner-actions{grid-template-columns:repeat(3,minmax(0,1fr))}#panel .section-banner>.pad-vendor-banner-actions>button:last-child{grid-column:auto}}

/* System actions must not inherit the full-row first monthly-job button. */
#panel .section-banner>.system-actions>button:first-child{grid-column:auto}

/* Keep the parent-system action compact without changing its target. */
#panel>.pad-system-parent-back{width:auto;max-width:100%;min-height:44px;align-self:flex-start;white-space:nowrap}

/* Share & Delegate — isolated creation dialog. Keep guest and approval logic unchanged. */
dialog.pad-share-dialog[open]{display:flex;flex-direction:column;overflow:hidden!important;padding:0!important;width:min(660px,calc(100vw - 20px))!important;max-width:calc(100vw - 20px)!important;max-height:calc(100dvh - 24px)!important;min-height:0;background:#f2f6fa;color:#17364f;border-radius:16px;box-sizing:border-box}
.pad-share-dialog>.pad-share-head{flex:0 0 auto;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 16px;background:#173b58;color:white;border-bottom:3px solid #bca568;min-width:0}
.pad-share-dialog>.pad-share-head h2{color:white;font-size:clamp(17px,4.7vw,21px);line-height:1.2;margin:0!important;min-width:0;overflow-wrap:anywhere}
.pad-share-dialog>.pad-share-head button{flex:0 0 auto;margin:0!important;min-height:44px;background:#315b7b;color:white;border:1px solid #7591a6;border-radius:8px;padding:8px 12px!important;font-size:14px}
.pad-share-dialog>.pad-delegate-host{flex:1 1 auto;min-height:0;min-width:0;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;padding:12px;scroll-padding-bottom:72px}
.pad-share-dialog .pad-delegate-host>p[role=status]{margin:0 0 8px;overflow-wrap:anywhere;font-size:13px;font-weight:600;color:#274e6c}.pad-share-dialog .pad-delegate-host>p[role=status]:empty{display:none}
.pad-share-dialog .pad-delegate-panel{padding:0!important;margin:0!important;background:transparent!important;box-shadow:none!important;border:0!important;min-width:0;overflow-wrap:anywhere}
.pad-share-dialog .pad-share-create{display:grid;gap:10px;min-width:0}
.pad-share-dialog .pad-share-title{padding:4px 3px 2px}.pad-share-dialog .pad-share-title small{font-size:11px;letter-spacing:.085em;color:#577188;font-weight:700}.pad-share-dialog .pad-share-title h3{margin:4px 0 0;font-size:20px;line-height:1.3;overflow-wrap:anywhere}
.pad-share-dialog .pad-share-card{min-width:0;background:#fff;border:1px solid #c8d7e3;border-radius:12px;padding:12px}
.pad-share-dialog .pad-share-card h3{font-size:15px;line-height:1.4;margin:0 0 8px;color:#234e70;font-weight:700}
.pad-share-dialog .pad-share-fields{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(0,1fr);gap:10px;align-items:end}
.pad-share-dialog .pad-delegate-panel .pad-share-field{display:flex;flex-direction:column;gap:5px;margin:0!important;font-size:13px;font-weight:600;min-width:0;line-height:1.35}
.pad-share-dialog .pad-delegate-panel .pad-share-field input,.pad-share-dialog .pad-delegate-panel .pad-share-search{width:100%!important;max-width:100%;min-width:0;min-height:44px;margin:0!important;padding:8px 10px;font-size:16px;line-height:1.35;border:1px solid #9bb1c4;border-radius:8px;background:#fff;color:#17364f;box-sizing:border-box}
.pad-share-dialog .pad-share-count{margin:0 0 8px;font-size:13px;color:#3e607b;font-weight:650}
.pad-share-dialog .pad-share-selection-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:8px 0 10px}
.pad-share-dialog .pad-delegate-panel .pad-share-selection-actions button{margin:0!important;width:100%;min-width:0;min-height:44px;font-size:13px;white-space:normal;background:#e6eef5;color:#20496b;border:1px solid #b9cddd;line-height:1.25;padding:6px!important}
.pad-share-dialog .pad-share-list{min-width:0}.pad-share-dialog .pad-share-group h4{margin:10px 0 0;padding:7px 8px;background:#eaf1f7;color:#244e6f;border-radius:6px;font-size:13px;line-height:1.35}
.pad-share-dialog .pad-delegate-panel .pad-share-row{display:grid!important;grid-template-columns:minmax(0,1fr) 24px;align-items:center;gap:12px;min-height:46px;padding:9px 2px;margin:0!important;border-bottom:1px solid #e1e9ef;color:#17364f;font-size:15px;line-height:1.4;cursor:pointer;min-width:0;overflow-wrap:anywhere}
.pad-share-dialog .pad-delegate-panel .pad-share-row:last-child{border-bottom:0}.pad-share-dialog .pad-delegate-panel .pad-share-row input[type=checkbox]{appearance:auto;width:20px!important;height:20px!important;min-width:20px;max-width:20px;padding:0!important;margin:0!important;justify-self:center;accent-color:#245a82;cursor:pointer}
.pad-share-dialog .pad-share-row input:disabled{opacity:.55;cursor:not-allowed}.pad-share-dialog .pad-share-static-row{font-size:14px;padding:9px 2px;border-top:1px solid #e1e9ef;overflow-wrap:anywhere}
.pad-share-dialog .pad-share-empty{font-size:14px;color:#516c82;margin:10px 0}.pad-share-dialog .pad-share-footer{position:sticky;bottom:-12px;z-index:2;background:#f2f6fa;padding:9px 0 12px;border-top:1px solid #c8d7e3}
.pad-share-dialog .pad-delegate-panel .pad-share-primary{display:block;width:100%;min-height:46px;margin:0!important;background:#24567e;color:#fff;font-weight:650;border-radius:9px;text-align:center}
.pad-share-dialog .pad-delegate-panel fieldset{background:white;border-color:#c8d7e3}.pad-share-dialog .pad-delegate-panel pre{font-size:13px}.pad-share-dialog .pad-delegate-panel a{display:inline-block}
.pad-share-dialog [hidden]{display:none!important}.pad-share-dialog button:focus-visible,.pad-share-dialog input:focus-visible{outline:2px solid #247aaf;outline-offset:2px}
@media(max-width:360px){.pad-share-dialog>.pad-delegate-host{padding:9px}.pad-share-dialog .pad-share-card{padding:10px}.pad-share-dialog .pad-share-fields{grid-template-columns:minmax(0,1fr)}.pad-share-dialog .pad-share-footer{bottom:-9px}.pad-share-dialog .pad-delegate-panel .pad-share-row{font-size:14px}}

/* Explicitly hide filtered rows despite the scoped grid rule. */
.pad-share-dialog .pad-delegate-panel .pad-share-row[hidden],.pad-share-dialog .pad-delegate-panel .pad-share-group[hidden]{display:none!important}

/* R4: isolated Share & Delegate control spacing. */
.pad-share-dialog .pad-share-organizer{margin-top:12px!important}
.pad-share-dialog .pad-share-organizer select{min-height:44px;width:100%;margin-top:5px!important}
.pad-share-dialog .pad-share-link-area{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-bottom:12px}
.pad-share-dialog .pad-share-link-area input{flex:1 0 100%;min-width:0;min-height:44px;width:100%}
.pad-share-dialog .pad-share-link-area button,.pad-share-dialog .pad-share-link-area a{margin:0!important;min-height:44px;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;max-width:100%;white-space:normal;overflow-wrap:anywhere}

/* R9.2 — scoped battery form only */
.rc-battery-edit-dialog form{display:grid;grid-template-columns:minmax(0,1fr);gap:12px;min-width:0}.rc-battery-edit-dialog form>label{margin:0;min-width:0}.rc-battery-edit-dialog form input,.rc-battery-edit-dialog form select{width:100%;min-width:0;box-sizing:border-box;min-height:44px}.rc-battery-edit-dialog form>button{margin:0;width:100%;min-height:48px;box-sizing:border-box}.rc-battery-edit-dialog form>[role=alert]:empty{display:none}

/* R9.3 — Running Hours only: uniform actions and breathing room below the table. */
#panel .pad-hours-entry-form>.pad-hours-submit{display:block;margin:16px 0 0!important;min-height:48px;box-sizing:border-box;max-width:100%;white-space:normal}
#panel .section-banner>.pad-hours-toolbar{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;flex:1 1 100%;width:100%;min-width:0}
#panel .pad-hours-toolbar>button{width:100%;min-width:0;min-height:48px;margin:0!important;white-space:normal;overflow-wrap:anywhere;box-sizing:border-box}
@media(max-width:600px){#panel .section-banner>.pad-hours-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))}#panel .pad-hours-toolbar>button:last-child{grid-column:1/-1}}
.pad-hours-pdf-dialog>.pad-share-head.pad-r8-sticky-head{background:#173b58}
.pad-hours-pdf-dialog .pad-hours-pdf-footer{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;padding:12px 16px;min-width:0;flex:0 0 auto;background:#f2f6fa;border-top:1px solid #c8d7e3}
.pad-hours-pdf-dialog .pad-hours-pdf-footer>button,.pad-hours-pdf-dialog .pad-hours-pdf-footer>select{width:100%;min-width:0;min-height:48px;box-sizing:border-box;margin:0!important;white-space:normal}
.pad-hours-pdf-dialog .pad-hours-pdf-footer>select{padding:10px;border:1px solid #aebfce;border-radius:8px;background:#fff;color:#173b58}
.pad-hours-pdf-dialog .pad-hours-pdf-status{grid-column:1/-1;margin:0;overflow-wrap:anywhere;font-size:14px}.pad-hours-pdf-dialog .pad-hours-pdf-status:empty{display:none}

/* R9.4: Running Hours and Battery Inventory only. */
#panel>.pad-hours-sticky-banner{position:static;width:100%;max-width:none;box-sizing:border-box;align-self:stretch;background:#174675;color:white}
#panel>.pad-hours-sticky-banner>h2{flex:1 1 100%;width:100%;color:white}
#panel .pad-hours-linked-cell{text-align:center;vertical-align:middle}
#panel .pad-hours-linked-cell>.pad-hours-linked-info{display:inline-flex!important;align-items:center;justify-content:center;box-sizing:border-box;width:44px;min-width:44px;height:44px;min-height:44px;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important;color:#00665e!important;font-size:23px;line-height:1;cursor:pointer}
#panel .pad-hours-linked-cell>.pad-hours-linked-info:focus-visible{outline:2px solid #00665e;outline-offset:1px}
.rc-upcoming-table .pad-service-reference-card{cursor:default}
.pad-battery-two-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:10px 0;min-width:0}
.pad-battery-section{border:1px solid #d5e0e9;border-radius:10px;padding:12px;min-width:0;overflow-wrap:anywhere;display:flex;flex-direction:column;gap:8px}
.pad-battery-section h4,.pad-battery-section p{margin:0}.pad-battery-section>strong{font-size:1.45rem;color:#173b58}.pad-battery-section .rc-pair{display:flex;flex-direction:column;align-items:flex-start;gap:4px;padding:0;border:0}.pad-battery-section .rc-pair strong{text-align:left;overflow-wrap:anywhere}
@media(max-width:350px){.pad-battery-section{padding:9px}.pad-battery-two-columns{gap:8px}}

/* R9.5 battery identity only: keep the approved quantity blocks unchanged. */
.rc-inventory-stock-card .pad-battery-identity{gap:10px;margin:6px 0 12px}
.pad-battery-identity-field{display:grid;grid-template-columns:minmax(0,1fr);gap:3px;min-width:0}
.rc-inventory-stock-card .pad-battery-identity-field strong{white-space:pre-line;overflow-wrap:anywhere;line-height:1.45}
.rc-inventory-stock-card .pad-battery-identity-field:first-child strong{font-size:1.1rem}
