:root{--field-blue:#23648d;--field-blue-soft:#eaf3f8;--field-copper:#a8632d;--field-focus:#0d72b9;--field-grid:#e2e6e8;--field-paper:#fcfcfa}
.field-builder-launch{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 16px;padding:14px;border:1px solid #a9c2d0;border-radius:10px;background:linear-gradient(120deg,#f5fafc,#eef5f8)}
.field-builder-launch div{min-width:0}.field-builder-launch strong,.field-builder-launch span{display:block}.field-builder-launch strong{font-size:14px}.field-builder-launch span{margin-top:3px;color:var(--muted);font-size:11px;line-height:1.35}.field-builder-launch button{flex:0 0 auto}
.field-tool-modal{position:fixed;z-index:160;inset:0;display:grid;grid-template-rows:auto minmax(0,1fr) auto;background:#e8ecee;color:#20262a;opacity:0;pointer-events:none;transform:translateY(12px);transition:opacity .15s ease,transform .15s ease}
.field-tool-modal.open{opacity:1;pointer-events:auto;transform:none}
.field-tool-header,.field-tool-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 14px;border-bottom:1px solid #c5cbce;background:rgba(250,251,251,.98);box-shadow:0 2px 12px rgba(26,35,40,.08)}
.field-tool-footer{border-top:1px solid #c5cbce;border-bottom:0;box-shadow:0 -2px 12px rgba(26,35,40,.07)}
.field-tool-title{display:flex;align-items:center;gap:12px;min-width:0}.field-tool-title div{min-width:0}.field-tool-title span,.field-tool-title strong{display:block}.field-tool-title span{color:#637078;font-size:10px;font-weight:850;letter-spacing:.12em;text-transform:uppercase}.field-tool-title strong{overflow:hidden;font-size:17px;text-overflow:ellipsis;white-space:nowrap}
.field-tool-header-actions,.field-tool-footer-actions,.field-inline-actions{display:flex;align-items:center;gap:7px}.field-tool-header button,.field-tool-footer button,.field-chip{min-height:42px}.field-report-link{display:inline-flex;align-items:center;justify-content:center;min-height:42px;text-decoration:none;white-space:nowrap}
.field-tool-body{display:grid;grid-template-columns:230px minmax(0,1fr) 300px;min-height:0}
.field-palette,.field-inspector{overflow:auto;padding:12px;border-right:1px solid #c6cccf;background:#f7f8f7}.field-inspector{border-right:0;border-left:1px solid #c6cccf}
.field-sidebar-head{position:sticky;z-index:4;top:-12px;margin:-12px -12px 10px;padding:12px;background:#f7f8f7}.field-sidebar-head h3{margin:0 0 8px;font-size:11px;letter-spacing:.11em}.field-sidebar-head input{margin:0;padding:9px 10px}
.field-palette-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.field-palette-group{grid-column:1/-1;margin:8px 0 0;color:#68737a;font-size:9px;font-weight:900;letter-spacing:.11em;text-transform:uppercase}
.field-palette-item{display:flex;min-width:0;min-height:78px;padding:7px;border:1px solid #c9ced0;border-radius:8px;background:#fff;color:#293136;cursor:pointer;flex-direction:column;align-items:center;justify-content:center;gap:5px;text-align:center}.field-palette-item:active{background:var(--field-blue-soft);transform:scale(.98)}.field-palette-item svg{width:58px;height:32px;overflow:visible}.field-palette-item span{font-size:10px;font-weight:780;line-height:1.1}
.field-palette-item small{padding:2px 5px;border-radius:999px;background:#edf0f1;color:#68737a;font-size:7px;font-weight:900;letter-spacing:.05em;text-transform:uppercase}.field-palette-item.coverage-recognized{border-color:#79a784;background:#f5faf6}.field-palette-item.coverage-recognized small{background:#dcecdf;color:#2f663a}.field-palette-item.coverage-manual{border-color:#c8aa68;background:#fffbf2}.field-palette-item.coverage-manual small{background:#f5e8c9;color:#78591d}.field-palette-item.coverage-observation{border-style:dashed}
.field-canvas-area{position:relative;display:grid;grid-template-rows:auto minmax(0,1fr) auto;min-width:0;min-height:0;padding:10px;background:#dfe4e6}
.field-canvas-toolbar{display:flex;align-items:center;gap:8px;padding:0 0 8px}.field-canvas-toolbar label{display:flex;align-items:center;gap:6px;color:#566168;font-size:10px;white-space:nowrap}.field-canvas-toolbar input,.field-canvas-toolbar select{width:auto;min-width:76px;margin:0;padding:7px 8px}.field-canvas-toolbar .field-grow{flex:1}
.field-canvas-toolbar{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(0,.9fr) repeat(2,minmax(0,1fr));align-items:end}
.field-canvas-toolbar label{display:grid;min-width:0;gap:4px;white-space:normal}
.field-canvas-toolbar input,.field-canvas-toolbar select,.field-canvas-toolbar button{width:100%;min-width:0;min-height:44px}
.field-canvas-toolbar .field-grow{display:none}
.field-canvas-toolbar .field-chip{grid-column:1/-1;grid-row:2;min-height:0;padding:4px 6px;border:0;border-radius:0;background:none;white-space:normal;text-align:left;font-size:10px}
.field-canvas-frame{position:relative;min-height:370px;overflow:hidden;border:1px solid #aeb7bb;border-radius:7px;background:var(--field-paper);box-shadow:0 3px 14px rgba(24,31,35,.12)}
.field-canvas-frame svg{display:block;width:100%;height:100%;min-height:370px;touch-action:none;user-select:none;-webkit-user-select:none}
.field-scene-grid{stroke:var(--field-grid);stroke-width:1}.field-scene-major{stroke:#ced5d8;stroke-width:1.3}.field-dimension{stroke:#56636a;stroke-width:1.2;fill:none}.field-extension{stroke:#879196;stroke-width:.9;stroke-dasharray:3 3}.field-dimension-text{fill:#364147;font-size:12px;font-weight:750;text-anchor:middle}.field-object{cursor:grab}.field-object:active{cursor:grabbing}.field-object .object-body{fill:#fff;stroke:#303b41;stroke-width:2}.field-object .object-detail{fill:none;stroke:#59666d;stroke-width:1.3}.field-object .hazard-surface{fill:#edf2f3;stroke:#3c484e;stroke-width:1.3}.field-object .object-label{fill:#20272b;font-size:11px;font-weight:800;text-anchor:middle}.field-object .object-subtitle{fill:#5f6b72;font-size:9px;font-weight:650;text-anchor:middle}.field-object.selected .object-body{stroke:var(--field-focus);stroke-width:3;filter:drop-shadow(0 2px 2px rgba(13,114,185,.2))}.field-object .resize-handle{display:none;fill:#fff;stroke:var(--field-focus);stroke-width:3;cursor:ew-resize}.field-object.selected .resize-handle{display:block}.field-gap .object-body{fill:url(#gapHatch);stroke:#7a858a;stroke-dasharray:4 3}.field-gap .object-label{fill:#647077;font-size:9px}.field-duct .object-body{fill:#f7f8f7;stroke:#313c42}.field-duct.selected .object-body{stroke:var(--field-focus);stroke-width:3}.field-duct{cursor:ew-resize}.field-nozzle-line{fill:none;stroke:#a34d4e;stroke-width:2}.field-nozzle-dot{fill:#fff;stroke:#a34d4e;stroke-width:2}.field-nozzle-label{fill:#943f40;font-size:9px;font-weight:800}.field-hood-body{fill:#f2f4f3;stroke:#263238;stroke-width:2}.field-hood-filter{stroke:#657178;stroke-width:1}.field-warning-object .object-body{stroke:#b36c24;stroke-width:3}
.field-duct .duct-opening{fill:#fff;stroke:#313c42;stroke-width:2}.field-duct .duct-throat{fill:none;stroke:#68777e;stroke-width:1.2;stroke-dasharray:4 3}.field-duct .duct-label,.field-duct .duct-size{fill:#263238;paint-order:stroke;stroke:#fff;stroke-width:3px;stroke-linejoin:round}.field-duct .duct-nozzle-symbol{fill:#fff;stroke:#a34d4e;stroke-width:2}.field-duct .duct-detection-line{fill:none;stroke:#806323;stroke-width:1.8}.field-duct .duct-detection-symbol{fill:#fff8df;stroke:#806323;stroke-width:1.8}.field-duct .duct-symbol-label{font-size:9px;font-weight:850;text-anchor:middle;paint-order:stroke;stroke:#fff;stroke-width:3px;stroke-linejoin:round}.field-duct .duct-symbol-label.nozzle{fill:#943f40}.field-duct .duct-symbol-label.detection{fill:#715421}.field-hood-label-bg{fill:#f2f4f3;stroke:#b5bdc1;stroke-width:.7}.field-hood-label{fill:#20272b;font-size:12px;font-weight:800;text-anchor:middle;paint-order:stroke;stroke:#f2f4f3;stroke-width:3px;stroke-linejoin:round}
.field-detection-label{fill:#715421;font-size:9px;font-weight:800;text-anchor:middle;paint-order:stroke;stroke:#f2f4f3;stroke-width:3px}
.field-duct .duct-throat-clear{fill:#fff;stroke:none}
.field-nozzle-aim{fill:none;stroke:#a34d4e;stroke-width:1.2;stroke-dasharray:4 4;opacity:.48}
.field-builder-status{display:flex;align-items:center;gap:8px;min-height:42px;padding:8px 10px;border-radius:7px;background:#f4f6f6;color:#566168;font-size:11px}.field-builder-status.good{background:#eaf4ec;color:#2f643c}.field-builder-status.warning{background:#faf2e4;color:#785419}.field-builder-status.error{background:#f8eaea;color:#8a3435}.field-builder-status b{font-size:12px}
.field-warning-list{display:flex;flex-wrap:wrap;gap:6px;padding-top:8px}.field-warning-list button{max-width:100%;min-height:44px;padding:4px 9px;border:1px solid #dac59e;border-radius:999px;background:#fff9ec;color:#6e511d;font-size:9px;font-weight:750;white-space:normal;text-align:left}.field-warning-list button.error{border-color:#d8aaaa;background:#fff1f1;color:#883435}
.field-inspector-empty{display:grid;min-height:220px;place-items:center;padding:20px;color:#66737a;text-align:center}.field-inspector-empty strong,.field-inspector-empty span{display:block}.field-inspector-empty span{margin-top:8px;font-size:12px;line-height:1.45}.field-inspector h3{margin:0 0 12px;font-size:12px}.field-inspector-grid{display:grid;grid-template-columns:1fr 1fr;gap:9px}.field-inspector-grid .wide{grid-column:1/-1}.field-inspector-grid label{font-size:10px}.field-inspector-grid input,.field-inspector-grid select,.field-inspector-grid textarea{margin-top:4px;padding:9px}.field-inspector-check{display:flex;align-items:center;gap:7px;padding:9px;border:1px solid #cbd2d5;border-radius:7px;background:#fff}.field-inspector-check input{width:auto;margin:0}.field-width-chips{display:flex;flex-wrap:wrap;gap:5px;grid-column:1/-1}.field-chip{min-height:34px;padding:4px 9px;border:1px solid #bcc5c9;border-radius:999px;background:#fff;color:#39454b;font-size:10px;font-weight:800}.field-chip.selected{border-color:var(--field-focus);background:var(--field-blue-soft);color:#0d5e91}.field-danger{border-color:#d5a3a3!important;color:#983d3d!important}
.field-coverage-note{margin:0 0 10px;padding:9px;border-left:3px solid #9aa5aa;background:#eef1f2}.field-coverage-note.recognized{border-left-color:#4f8b5e;background:#edf6ef}.field-coverage-note strong,.field-coverage-note span{display:block}.field-coverage-note strong{font-size:10px}.field-coverage-note span{margin-top:4px;color:#5e6a70;font-size:9px;line-height:1.35}.field-identity-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:3px 0;padding:10px;border:1px solid #c9d0d3;border-radius:8px;background:#fff}.field-identity-grid legend{padding:0 4px;color:#536168;font-size:9px;font-weight:900;letter-spacing:.06em;text-transform:uppercase}.field-identity-grid .wide{grid-column:1/-1}
.field-tool-footer-note{color:#58656c;font-size:10px;line-height:1.35}.field-tool-footer-note strong{color:#303b41}
.field-iso-body{display:grid;grid-template-columns:minmax(0,1fr) 280px;min-height:0}.field-iso-workspace{display:grid;grid-template-rows:auto minmax(0,1fr);min-width:0;min-height:0;padding:10px;background:#dfe4e6}.field-iso-directions{display:flex;align-items:center;gap:6px;padding:0 0 8px;overflow-x:auto}.field-iso-directions button{min-width:48px;min-height:42px;border:1px solid #b8c0c4;border-radius:7px;background:#fff;font-weight:800;white-space:nowrap}.field-iso-directions button.active{border-color:var(--field-focus);background:var(--field-blue-soft);color:#0b608f}.field-iso-canvas{min-height:420px;border:1px solid #aeb7bb;border-radius:7px;background:#fcfcfa}.field-iso-canvas svg{display:block;width:100%;height:100%;min-height:420px;touch-action:none}.iso-grid{stroke:#e1e5e7;stroke-width:1}.iso-pipe{fill:none;stroke:#25343b;stroke-width:5;stroke-linecap:round}.iso-pipe.selected{stroke:var(--field-focus);stroke-width:7}.iso-node{fill:#fff;stroke:#25343b;stroke-width:2}.iso-node.selected{fill:var(--field-blue-soft);stroke:var(--field-focus);stroke-width:3}.iso-component{fill:#fff;stroke:var(--field-copper);stroke-width:2}.iso-label{fill:#39464d;font-size:11px;font-weight:750}.field-iso-panel{overflow:auto;padding:13px;border-left:1px solid #c6cccf;background:#f7f8f7}.field-iso-panel h3{font-size:11px}.field-iso-component-grid{display:grid;grid-template-columns:1fr 1fr;gap:7px}.field-iso-component-grid button{min-height:54px;padding:7px;border:1px solid #c2c9cc;border-radius:7px;background:#fff;font-size:10px;font-weight:800}.field-iso-component-grid button.active{border-color:var(--field-copper);background:#faf0e8;color:#7d461f}
.smart-capture-card{margin-top:14px;padding:14px;border:1px solid #acc4d0;border-radius:9px;background:#f3f8fa}.smart-capture-card h4{margin:0 0 5px;font-size:12px}.smart-capture-card p{margin:0 0 10px;color:#607078;font-size:10px;line-height:1.4}.smart-capture-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.smart-capture-actions input{max-width:320px;margin:0}.smart-capture-progress{margin-top:8px;color:#53636b;font-size:10px}.smart-capture-results{display:grid;gap:7px;margin-top:10px}.smart-capture-suggestion{display:grid;grid-template-columns:1fr auto;gap:8px;padding:9px;border:1px solid #c8d1d5;border-radius:7px;background:#fff}.smart-capture-suggestion span,.smart-capture-suggestion strong{display:block}.smart-capture-suggestion span{color:#6a757b;font-size:9px;text-transform:uppercase}.smart-capture-suggestion strong{margin-top:2px;font-size:12px}.smart-capture-suggestion button{min-height:38px}
.smart-photo-button{display:grid;place-items:center;min-height:44px;cursor:pointer}.smart-photo-button input{position:absolute;width:1px;height:1px;opacity:0}.smart-capture-modal{position:fixed;z-index:220;inset:0;display:grid;padding:18px;background:rgba(22,29,33,.56);backdrop-filter:blur(4px);place-items:center;opacity:0;pointer-events:none}.smart-capture-modal.open{opacity:1;pointer-events:auto}.smart-capture-dialog{display:grid;grid-template-rows:auto minmax(0,1fr) auto;width:min(980px,100%);max-height:min(820px,calc(100vh - 36px));overflow:hidden;border:1px solid #aeb8bc;border-radius:12px;background:#f8faf9;box-shadow:0 18px 60px rgba(0,0,0,.28)}.smart-capture-dialog>header,.smart-capture-dialog>footer{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 14px;border-bottom:1px solid #ccd2d4;background:#fff}.smart-capture-dialog>footer{justify-content:flex-end;border-top:1px solid #ccd2d4;border-bottom:0}.smart-capture-dialog>header span,.smart-capture-dialog>header strong{display:block}.smart-capture-dialog>header span{color:#65727a;font-size:9px;font-weight:900;letter-spacing:.1em;text-transform:uppercase}.smart-capture-dialog>header strong{margin-top:3px;font-size:16px}.smart-capture-content{display:grid;grid-template-columns:minmax(280px,.9fr) minmax(340px,1.1fr);min-height:0;overflow:auto}.smart-capture-image{display:grid;grid-template-rows:minmax(0,1fr) auto;min-height:300px;padding:12px;border-right:1px solid #ccd2d4;background:#e9edef}.smart-capture-image img{width:100%;height:100%;min-height:260px;object-fit:contain;border-radius:6px;background:#252b2e}.smart-capture-image p{margin:8px 0 0;color:#536169;font-size:10px}.smart-capture-review{overflow:auto;padding:14px}.smart-capture-review>p{margin:0 0 12px;padding:10px;border-left:3px solid #4f8b5e;background:#edf6ef;color:#365b3c;font-size:11px;line-height:1.4}.smart-capture-review details{margin-top:12px}.smart-capture-review pre{max-height:160px;overflow:auto;padding:9px;border:1px solid #d3d8da;border-radius:6px;background:#fff;font:10px/1.4 ui-monospace,monospace;white-space:pre-wrap}.smart-capture-suggestion{grid-template-columns:auto minmax(0,1fr);align-items:start;margin-bottom:7px;cursor:pointer}.smart-capture-suggestion>input{width:22px;height:22px;margin:8px 0 0}.smart-capture-suggestion span b,.smart-capture-suggestion span small{display:block}.smart-capture-suggestion span input{margin:4px 0;padding:8px;color:var(--ink);font-size:12px;text-transform:none}.smart-capture-suggestion span small{color:#6b767c;font-size:8px;line-height:1.3;text-transform:none}.smart-capture-empty{padding:18px;border:1px dashed #b9c2c6;border-radius:8px;background:#fff;text-align:center}.smart-capture-empty strong,.smart-capture-empty span{display:block}.smart-capture-empty span{margin-top:5px;color:#68757c;font-size:10px}.field-nameplate-photo{display:grid;gap:8px;padding:10px;border:1px solid #acc4d0;border-radius:8px;background:#f3f8fa}.field-nameplate-photo-head{display:flex;align-items:center;justify-content:space-between;gap:8px}.field-nameplate-photo-head strong{font-size:11px}.field-nameplate-photo-head span{color:#68767d;font-size:9px;font-weight:750}.field-nameplate-photo-head span.saved{color:#2f6a3c}.field-nameplate-photo-actions{display:flex;gap:8px;flex-wrap:wrap}.smart-equipment-photo{display:grid;flex:1 1 120px;place-items:center;min-height:48px;padding:7px 9px;border:1px solid #8bafc0;border-radius:8px;background:#fff;color:#244e65;font-size:10px;font-weight:800;line-height:1.2;text-align:center;cursor:pointer}.smart-equipment-photo.primary{border-color:#1475ab;background:#1475ab;color:#fff}.smart-equipment-photo input{position:absolute;width:1px;height:1px;opacity:0}.field-nameplate-photo>small{color:#596971;font-size:9px;line-height:1.35}
@media(max-width:1050px){.field-tool-body{grid-template-columns:190px minmax(0,1fr) 260px}.field-palette-grid{grid-template-columns:1fr}.field-palette-group{grid-column:auto}.field-inspector-grid{grid-template-columns:1fr}.field-inspector-grid .wide,.field-width-chips{grid-column:auto}}
@media(max-width:900px){.field-tool-modal{grid-template-rows:auto minmax(0,1fr) auto}.field-tool-header{align-items:flex-start}.field-tool-title strong{font-size:14px}.field-tool-header-actions .secondary:not(.field-always){display:none}.field-tool-body{grid-template-columns:1fr;grid-template-rows:auto minmax(330px,1fr) auto;overflow:auto}.field-palette{overflow-x:auto;padding:8px;border-right:0;border-bottom:1px solid #c6cccf}.field-sidebar-head{display:none}.field-palette-grid{display:flex;gap:6px}.field-palette-group{display:none}.field-palette-item{flex:0 0 92px;min-height:66px}.field-palette-item svg{height:25px}.field-canvas-area{min-height:440px;padding:7px}.field-canvas-toolbar{overflow-x:auto}.field-canvas-frame,.field-canvas-frame svg{min-height:390px}.field-inspector{max-height:360px;border-top:1px solid #c6cccf;border-left:0}.field-inspector-grid{grid-template-columns:1fr 1fr}.field-inspector-grid .wide,.field-width-chips{grid-column:1/-1}.field-tool-footer{align-items:flex-end}.field-tool-footer-note{display:none}.field-tool-footer-actions{width:100%}.field-tool-footer-actions button{flex:1;padding-right:9px;padding-left:9px}.field-iso-body{grid-template-columns:1fr;grid-template-rows:minmax(420px,1fr) auto;overflow:auto}.field-iso-panel{border-top:1px solid #c6cccf;border-left:0}.field-iso-component-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:900px){.smart-capture-modal{padding:0}.smart-capture-dialog{width:100%;max-height:100vh;height:100vh;border:0;border-radius:0}.smart-capture-content{grid-template-columns:1fr;grid-template-rows:minmax(230px,38vh) auto}.smart-capture-image{min-height:220px;border-right:0;border-bottom:1px solid #ccd2d4}.smart-capture-image img{min-height:190px}.smart-capture-dialog>footer button{flex:1;min-height:48px}}
@media(max-width:520px){.field-builder-launch{align-items:stretch;flex-direction:column}.field-inspector-grid{grid-template-columns:1fr}.field-inspector-grid .wide,.field-width-chips{grid-column:auto}.field-tool-header{padding:8px}.field-tool-title span{font-size:8px}.field-tool-title strong{max-width:190px}.field-tool-header-actions button{min-height:38px;padding:0 10px}.field-tool-footer{padding:8px}.field-canvas-toolbar label:first-child{display:none}.field-builder-status{font-size:9px}}
@media(orientation:landscape) and (min-width:761px) and (max-height:700px){.field-tool-header,.field-tool-footer{padding-top:6px;padding-bottom:6px}.field-tool-body{grid-template-rows:minmax(0,1fr)}.field-canvas-frame,.field-canvas-frame svg{min-height:300px}.field-inspector{max-height:none}}

/* Mobile field ergonomics and generous, invisible SVG hit areas. */
#isoFieldBuilder{z-index:190}
.iso-pipe-hit{fill:none;stroke:transparent;stroke-width:34;pointer-events:stroke;cursor:pointer}
.iso-node-hit{fill:transparent;stroke:transparent;stroke-width:12;pointer-events:all;cursor:pointer}
.field-object .resize-hit{display:none;fill:transparent;stroke:transparent;pointer-events:none}
.field-object.selected .resize-hit{display:block;pointer-events:all;cursor:ew-resize}
.field-object .resize-handle{pointer-events:none}
.field-tool-header{padding-top:max(10px,env(safe-area-inset-top));padding-right:max(14px,env(safe-area-inset-right));padding-left:max(14px,env(safe-area-inset-left))}
.field-tool-footer{padding-right:max(14px,env(safe-area-inset-right));padding-bottom:max(10px,env(safe-area-inset-bottom));padding-left:max(14px,env(safe-area-inset-left))}
.smart-capture-dialog>header{padding-top:max(12px,env(safe-area-inset-top));padding-right:max(14px,env(safe-area-inset-right));padding-left:max(14px,env(safe-area-inset-left))}
.smart-capture-dialog>footer{padding-right:max(14px,env(safe-area-inset-right));padding-bottom:max(12px,env(safe-area-inset-bottom));padding-left:max(14px,env(safe-area-inset-left))}
.field-tool-header button,.field-tool-footer button,.field-chip,.field-warning-list button,.field-iso-directions button{min-height:44px}
.field-tool-title,.field-tool-title>div,.field-palette,.field-inspector,.field-inspector-grid>*,.field-identity-grid,.field-identity-grid>*,.field-iso-panel,.field-iso-directions{min-width:0}
.field-tool-title span,.field-coverage-note,.field-builder-status,.field-tool-footer-note{overflow-wrap:anywhere}
.field-inspector-check{min-height:44px}
.field-tool-title .close{flex:0 0 44px}
.field-tool-header-actions,.field-tool-footer-actions,.field-inline-actions{flex-wrap:wrap;min-width:0}
.field-tool-footer-note{flex:1 1 260px;margin:0}
.field-tool-footer-actions{flex:0 1 auto;max-width:100%}
.field-iso-directions{flex-wrap:wrap;overflow-x:visible}
.field-iso-directions strong{flex:1 0 100%;font-size:12px}
.field-iso-directions button{flex:1 1 70px;min-width:0;white-space:normal}
.smart-capture-dialog>header button,.smart-capture-dialog>footer button{min-width:44px;min-height:44px}
body .oim-section-pass,body .oim-source-strip a,body .oim-exception-detail button,body .finding-register-head button,body .finding-actions button{min-height:44px}
@supports(height:100dvh){.field-tool-modal{height:100dvh}.smart-capture-dialog{max-height:min(820px,calc(100dvh - 36px))}}

@media(max-width:900px){
  .field-tool-header{display:grid;grid-template-columns:minmax(126px,.65fr) minmax(0,1fr);padding-top:max(8px,env(safe-area-inset-top));padding-right:max(8px,env(safe-area-inset-right));padding-left:max(8px,env(safe-area-inset-left))}
  .field-tool-header-actions{display:flex;width:100%;min-width:0;overflow-x:auto;justify-content:flex-start;flex-wrap:nowrap;overscroll-behavior-x:contain;scrollbar-width:thin;-webkit-overflow-scrolling:touch}
  .field-tool-header .field-tool-header-actions .secondary{display:inline-flex;flex:0 0 auto;align-items:center;justify-content:center;min-height:44px;white-space:nowrap}
  .field-tool-footer{padding-right:max(8px,env(safe-area-inset-right));padding-bottom:max(8px,env(safe-area-inset-bottom));padding-left:max(8px,env(safe-area-inset-left))}
  .field-tool-body{grid-template-rows:minmax(142px,auto) minmax(440px,1fr) auto;overflow:auto}
  .field-palette{display:grid;grid-template-rows:auto minmax(69px,auto);min-height:142px;overflow:visible;padding:8px}
  .field-sidebar-head{position:sticky;z-index:8;top:0;display:block;margin:0 0 7px;padding:0;background:#f7f8f7}
  .field-sidebar-head h3{display:block;margin:0 0 5px;font-size:9px}
  .field-sidebar-head input{min-height:44px;margin:0;padding:9px 10px;font-size:16px}
  .field-palette-grid{display:flex;min-height:69px;gap:6px;overflow-x:auto;padding-bottom:3px;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
  .field-palette-group{position:sticky;z-index:3;left:0;display:grid;flex:0 0 94px;min-height:66px;margin:0;padding:7px;border:1px solid #c9ced0;border-radius:8px;background:#eef1f2;box-shadow:5px 0 8px rgba(37,52,59,.08);place-items:center;text-align:center;line-height:1.25}
  .field-tool-modal input:not([type="checkbox"]):not([type="radio"]),.field-tool-modal select,.field-tool-modal textarea,.smart-capture-dialog input:not([type="checkbox"]):not([type="radio"]),.smart-capture-dialog select,.smart-capture-dialog textarea{font-size:16px}
  .field-canvas-toolbar input,.field-canvas-toolbar select{min-height:44px}
  body input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),body select,body textarea{font-size:16px}
  .smart-capture-dialog{height:100vh;max-height:100vh}
  @supports(height:100dvh){.smart-capture-dialog{height:100dvh;max-height:100dvh}}
}
@media(max-width:520px){
  .field-tool-body{grid-template-rows:minmax(142px,auto) minmax(310px,auto) auto}
  .field-canvas-area{min-height:310px}
  .field-canvas-frame,.field-canvas-frame svg{min-height:230px}
}

/*
 * Tablet/phone field workflow: every control reflows vertically.  The builder
 * previously used four separate horizontal scrollers (header actions,
 * equipment palette, canvas tools, and warning chips), which made the form
 * impractical on an iPad and nearly unusable on a phone.
 */
@media(max-width:900px){
  .field-tool-modal,
  .field-tool-header,
  .field-tool-body,
  .field-palette,
  .field-canvas-area,
  .field-inspector,
  .field-tool-footer{width:100%;max-width:100vw;min-width:0}

  .field-tool-header{display:grid;grid-template-columns:minmax(0,1fr);gap:8px}
  .field-tool-title,.field-tool-title>div{min-width:0}
  .field-tool-title strong{max-width:none;white-space:normal;overflow-wrap:anywhere}
  .field-tool-header-actions{display:grid;width:100%;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;overflow:visible}
  .field-tool-header .field-tool-header-actions .secondary{display:flex;width:100%;min-width:0;padding:6px 8px;white-space:normal;line-height:1.15;text-align:center}

  /* One document-like vertical flow keeps the details inspector at its full
     height instead of squeezing it into the few pixels left by grid tracks. */
  .field-tool-body{display:block;overflow-x:hidden;overflow-y:auto}
  .field-palette{display:grid;height:min(28vh,270px);min-height:220px;grid-template-rows:auto minmax(0,1fr);overflow:hidden;padding:8px}
  .field-sidebar-head{position:static;margin:0 0 7px;padding:0}
  .field-palette-grid{display:grid;min-width:0;min-height:0;grid-template-columns:repeat(6,minmax(0,1fr));gap:6px;overflow-x:hidden;overflow-y:auto;padding:0 2px 4px 0;overscroll-behavior-y:contain}
  .field-palette-group{position:static;display:block;grid-column:1/-1;min-height:0;margin:5px 0 0;padding:6px 8px;box-shadow:none;text-align:left}
  .field-palette-item{width:100%;min-width:0;min-height:68px;padding:6px}
  .field-palette-item svg{max-width:100%}
  .field-palette-item span{overflow-wrap:anywhere}

  .field-canvas-area{overflow-x:hidden}
  .field-canvas-toolbar{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;overflow:visible}
  .field-canvas-toolbar label{display:grid;min-width:0;gap:4px;white-space:normal}
  .field-canvas-toolbar input,.field-canvas-toolbar select,.field-canvas-toolbar button{width:100%;min-width:0}
  .field-canvas-toolbar .field-grow{display:none}
  .field-canvas-toolbar .field-chip{display:block;min-width:0;min-height:0;white-space:normal;line-height:1.2;text-align:left}
  .field-warning-list{flex-wrap:wrap;overflow-x:hidden}
  .field-warning-list button{max-width:100%;white-space:normal;text-align:left}

  .field-inspector{max-height:none;min-height:260px;overflow:visible;border-top:1px solid #c6cccf;border-left:0}

  .field-tool-footer-actions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px}
  .field-tool-footer-actions:has(> #fieldGeneratedPdfLink:not([hidden])){grid-template-columns:repeat(5,minmax(0,1fr))}
  .field-tool-footer-actions button,.field-tool-footer-actions .field-report-link{width:100%;min-width:0;min-height:44px;padding:6px 8px;white-space:normal;line-height:1.15;text-align:center}

  .field-iso-directions{flex-wrap:wrap;overflow-x:hidden}
  .field-iso-directions button{flex:1 1 84px;min-width:0;white-space:normal}
  .field-iso-body{display:block;overflow-x:hidden;overflow-y:auto}
  .field-iso-workspace{min-height:492px}
}

@media(max-width:600px){
  .field-tool-header-actions{grid-template-columns:repeat(3,minmax(0,1fr))}
  .field-tool-footer-actions,.field-tool-footer-actions:has(> #fieldGeneratedPdfLink:not([hidden])){grid-template-columns:repeat(3,minmax(0,1fr))}
  .field-palette{height:min(42vh,330px);min-height:230px}
  .field-palette-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .field-canvas-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))}
  .field-canvas-toolbar .field-chip{grid-column:1/-1}
  .field-iso-component-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}

@media(max-width:360px){
  .field-palette-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .field-tool-footer-actions{grid-template-columns:1fr 1fr}
  .field-tool-footer-actions .primary{grid-column:1/-1}
}
