/* Scoped manufacturing revision. Uses the analysis tool's existing UW palette. */
#p-mfg:not([hidden]){display:flex;flex-direction:column;height:100%;min-height:0}
#mfApp{height:100%;flex:1;min-height:0;font-size:16px;line-height:1.55;color:var(--ink,#17202a)}
#mfApp *{box-sizing:border-box}
.mx{height:100%;min-height:0;display:flex;flex-direction:column;gap:15px}
.mx button,.mx input,.mx select,.mx textarea{font:inherit;color:inherit}
.mx button,.mx select,.mx input[type=checkbox]{cursor:pointer}
.mx button:focus-visible,.mx input:focus-visible,.mx select:focus-visible,.mx textarea:focus-visible,.mx summary:focus-visible,.mx a:focus-visible{outline:3px solid var(--gold,#c9b37a);outline-offset:3px}
.mx-top{display:flex;justify-content:space-between;align-items:center;gap:16px;flex:none;padding:0 4px}
.mx-top p{margin:4px 0 0;font-size:14px;color:var(--muted)}
.mx-eyebrow{font-size:11px;font-weight:700;letter-spacing:.08em;color:var(--accent);display:block}
.mx-tabs{display:flex;gap:5px;padding:4px;border:1px solid var(--line);border-radius:12px;background:var(--surface,#fff)}
.mx-tabs button{border:0;background:transparent;padding:10px 19px;border-radius:8px;font-size:15px}
.mx-tabs button[aria-selected=true]{background:var(--accent);color:var(--accent-ink,#fff);font-weight:600}
.mx-scroll{overflow:auto;min-height:0;flex:1;padding:4px 9px 40px 4px;scrollbar-gutter:stable;scroll-behavior:smooth;overscroll-behavior:contain}
.mx-figure-picker{display:flex;gap:8px;margin:10px 0;overflow-x:auto}
.mx-figure-picker button{padding:2px;background:white;border:1px solid #c6bfd4;border-radius:7px;cursor:pointer;flex:0 0 92px}
.mx-figure-picker img{width:86px;height:58px;object-fit:cover;display:block;border-radius:4px}
.mx-figure-picker button:focus-visible{outline:3px solid #4b2e83;outline-offset:2px}
.mx-intro{display:flex;align-items:center;justify-content:space-between;gap:24px;margin:4px 0 22px}
.mx h3{font-size:clamp(24px,2.4vw,33px);line-height:1.16;margin:0 0 10px;font-weight:600;letter-spacing:-.025em}
.mx h4{font-size:23px;line-height:1.25;margin:0 0 16px;font-weight:600;letter-spacing:-.015em}
.mx h5{font-size:17px;line-height:1.3;margin:15px 0 8px;font-weight:600}
.mx p{margin:0 0 13px;max-width:76ch}
.mx-intro p,.mx-title>p{color:var(--muted);margin:0;font-size:16px;max-width:65ch}
.mx-count,.mx-badge{white-space:nowrap;border:1px solid var(--line);background:var(--surface);border-radius:99px;padding:6px 12px;font-size:12px;color:var(--accent)}
.mx-method-grid,.mx-example-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.mx-tile{background:var(--surface);border:1px solid var(--line);border-radius:14px;overflow:hidden;text-align:left;padding:0;display:flex;flex-direction:column;transition:transform .18s,border-color .18s,box-shadow .18s}
.mx-tile:hover{transform:translateY(-3px);border-color:var(--accent);box-shadow:0 8px 25px #241a3d12}
.mx-tile>img{width:100%;height:180px;object-fit:contain;display:block;background:#faf7f0;border-bottom:1px solid var(--line)}
.mx-tile-copy{display:grid;gap:6px;padding:15px 18px 19px}
.mx-tile small{color:var(--accent);font-size:11px;letter-spacing:.02em}
.mx-tile strong{font-size:19px;font-weight:600;line-height:1.25}
.mx-tile-copy>span{font-size:14px;line-height:1.45;color:var(--muted)}
.mx-callout{background:var(--surface);border:1px solid var(--line);border-left:4px solid var(--gold);border-radius:10px;padding:20px 23px;margin:25px 0}
.mx-callout p:last-child{margin-bottom:0}
.mx-button{display:inline-flex;align-items:center;justify-content:center;gap:7px;border:1px solid var(--line);background:var(--surface);padding:9px 14px;border-radius:8px;line-height:1.3;font-size:14px;text-decoration:none;min-height:40px}
.mx-button:hover{border-color:var(--accent);background:var(--accent-soft)}
.mx-button.primary{background:var(--accent);border-color:var(--accent);color:var(--accent-ink,#fff);font-weight:500}
.mx-button.primary:hover{filter:brightness(1.12)}
.mx-actions,.mx-detail-head,.mx-filters{display:flex;gap:9px;flex-wrap:wrap;align-items:center}
.mx-detail-head{margin-bottom:20px}
.mx-title{margin:0 0 25px;max-width:1000px}
.mx-title h3{font-size:clamp(28px,3vw,42px)}
.mx-chapters{display:flex;gap:7px;padding:10px 0;position:sticky;top:-4px;background:var(--bg,#f1f0f5);z-index:3;border-bottom:1px solid var(--line);margin-bottom:26px;overflow-x:auto}
.mx-chapters button{border:0;background:var(--surface);border-radius:99px;padding:7px 13px;white-space:nowrap;font-size:13px}
.mx-chapters button:hover{background:var(--accent-soft);color:var(--accent)}
.mx-story{display:grid;grid-template-columns:minmax(0,.95fr) minmax(0,1fr);gap:clamp(25px,3vw,55px);align-items:start}
.mx-story-art{position:sticky;top:65px;align-self:start}
.mx-story figure{margin:0}
.mx-story-art figure{border:1px solid var(--line);background:var(--surface);border-radius:14px;overflow:hidden}
.mx-story-art figure>img{display:block;width:100%;height:clamp(230px,31vw,440px);object-fit:contain;background:#faf7f0}
.mx-story figcaption{padding:12px 16px;color:var(--muted);font-size:12px;line-height:1.5}
.mx-stage-label{padding:12px 3px;color:var(--accent);font-size:13px;font-weight:500}
.mx-story-copy>section{padding:15px 0 36px;margin-bottom:16px;scroll-margin-top:70px}
.mx-story-copy>section+section{border-top:1px solid var(--line);padding-top:30px}
.mx-story-copy p,.mx-bullets{font-size:16px;color:var(--muted);line-height:1.65}
.mx-bullets{padding-left:20px;margin:12px 0 22px}
.mx-bullets li{padding-left:3px;margin-bottom:9px}
.mx-sequence{list-style:none;margin:0;padding:0}
.mx-sequence>li{display:flex;gap:16px;border-left:2px solid var(--line);padding:12px 0 30px 20px;min-height:125px;transition:border-color .2s}
.mx-sequence>li.active{border-color:var(--accent)}
.mx-sequence h5{margin:3px 0 8px;font-size:19px}
.mx-step-number{display:grid;place-items:center;width:27px;height:27px;background:var(--accent-soft);color:var(--accent);border-radius:50%;flex:none;font-size:13px;font-weight:600}
.mx-sequence>li.active .mx-step-number{background:var(--accent);color:white}
.mx textarea{width:100%;padding:12px;background:var(--surface-2);border:1px solid var(--line);border-radius:8px;margin:12px 0 8px;resize:vertical;font-size:15px}
.mx-small{color:var(--muted);font-size:12px!important;line-height:1.55!important}
.mx-filters{margin:0 0 18px;gap:7px}
.mx-filters button{border:1px solid var(--line);border-radius:99px;background:var(--surface);padding:6px 14px;font-size:13px}
.mx-filters button[aria-pressed=true]{background:var(--accent-soft);border-color:var(--accent);font-weight:600;color:var(--accent)}
.mx-search-label{font-size:11px;color:var(--muted);min-width:220px}
.mx-search-label input{display:block;width:100%;border:1px solid var(--line);padding:9px 13px;border-radius:8px;background:var(--surface);font-size:14px;margin-top:4px}
.mx-optional{display:flex;gap:9px;align-items:center;margin:20px 0;font-size:13px;color:var(--muted)}
.mx input[type=checkbox]{width:17px;height:17px;accent-color:var(--accent)}
.mx-sources{background:var(--surface);border:1px solid var(--line);border-radius:10px;padding:14px 17px;margin:16px 0;font-size:14px;line-height:1.6}
.mx-sources summary{cursor:pointer;font-weight:600;font-size:14px;list-style-position:outside;margin-left:12px}
.mx-sources[open] summary{margin-bottom:14px}
.mx-sources a{color:var(--accent);text-decoration:underline;text-underline-offset:3px;overflow-wrap:anywhere}
.mx-sources li{margin-bottom:7px}
.mx-sources ul{padding-left:19px}
.mx-related{display:flex;flex-wrap:wrap;gap:8px}
.mx-exact{border:1px solid var(--line);border-radius:10px;background:white;margin:20px 0!important;overflow:hidden}
.mx-exact svg{width:100%;height:auto;display:block}
.mx-selector{display:grid;grid-template-columns:320px minmax(0,1fr);gap:23px;align-items:start}
.mx-input-panel{position:sticky;top:0;background:var(--surface);border:1px solid var(--line);border-radius:13px;padding:18px;max-height:calc(100vh - 225px);overflow:auto;scrollbar-width:thin}
.mx-input-panel h4{font-size:19px;margin-bottom:15px}
.mx-input-panel>details{border-top:1px solid var(--line);padding:14px 0 3px}
.mx-input-panel summary{cursor:pointer;font-size:14px;font-weight:600;margin-bottom:13px}
.mx-input-panel>.mx-button{width:100%;margin-top:10px}
.mx-input-panel>.mx-small{margin:14px 0 0}
.mx-input-pair{display:grid;grid-template-columns:1fr 1fr;gap:10px;align-items:start}
.mx-field{display:block;font-size:12px;line-height:1.35;margin-bottom:12px;min-width:0;font-weight:500}
.mx-unit{font-size:11px;color:var(--muted);margin-left:4px;font-weight:400}
.mx-field input,.mx-field select{display:block;width:100%;min-width:0;padding:8px 9px;border:1px solid var(--line);border-radius:7px;background:var(--surface-2);font-size:14px;margin-top:5px;min-height:38px}
.mx-field small{display:block;font-weight:400;font-size:11px;line-height:1.45;color:var(--muted);margin-top:5px}
.mx-results{min-width:0}
.mx-model-note{background:var(--accent-soft);border:1px solid #d6cce7;padding:15px 18px;border-radius:10px;font-size:14px;display:grid;gap:5px;margin-bottom:18px}
.mx-model-note span{color:var(--muted);font-size:12px}
.mx-table-wrap{overflow:auto;border:1px solid var(--line);border-radius:11px;background:var(--surface);margin-bottom:20px}
.mx-table{border-collapse:collapse;min-width:770px;width:100%;font-size:12px;line-height:1.5;text-align:right}
.mx-table caption{text-align:left;padding:13px 15px;font-weight:600;font-size:13px}
.mx-table th,.mx-table td{border-top:1px solid var(--line);padding:10px 12px;vertical-align:middle}
.mx-table thead th{background:var(--surface-2);font-size:11px;color:var(--muted);font-weight:500}
.mx-table td:first-child{text-align:center;width:48px}
.mx-table th:nth-child(2),.mx-table tbody th{text-align:left;min-width:160px}
.mx-table tbody th small{display:block;color:var(--muted);font-size:10px;font-weight:400;max-width:160px}
.mx-table tbody th button{padding:0;background:none;border:0;text-align:left;font-size:13px;font-weight:600;color:var(--accent)}
.mx-table tbody tr.selected{background:var(--accent-soft)}
.mx-table tbody tr:hover{background:var(--surface-2)}
.mx-chart,.mx-inspect{border:1px solid var(--line);background:var(--surface);border-radius:13px;padding:20px;margin-bottom:21px}
.mx-chart-head,.mx-inspect-head{display:flex;justify-content:space-between;gap:15px;align-items:start;margin-bottom:18px}
.mx-chart h4,.mx-inspect h4{font-size:21px;margin-bottom:8px}
.mx-chart-head p{font-size:13px;color:var(--muted);margin-bottom:0}
.mx-chart svg{display:block;width:100%;height:auto;background:#fff;border-radius:6px}
.mx-chart-legend,.mx-cost-legend{display:flex;gap:12px;flex-wrap:wrap;font-size:11px;color:var(--muted);margin:12px 0}
.mx-chart-legend>span,.mx-cost-legend>span{display:inline-flex;align-items:center;gap:6px}
.mx-chart-legend i,.mx-cost-legend i{display:inline-block;width:10px;height:10px;border-radius:2px;flex:none}
.mx-inspect-grid{display:grid;grid-template-columns:minmax(160px,.6fr) 1fr;gap:20px;align-items:center}
.mx-inspect-grid>img{width:100%;max-height:260px;object-fit:contain;border-radius:9px;background:#faf7f0}
.mx-metric-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.mx-metric-grid>div{display:grid;gap:4px}
.mx-metric-grid small{font-size:11px;color:var(--muted)}
.mx-metric-grid strong{font-size:24px;font-weight:600;line-height:1.2;letter-spacing:-.03em;color:var(--accent)}
.mx-metric-grid span{font-size:11px;color:var(--muted);line-height:1.4}
.mx-stack{display:flex;height:15px;border-radius:4px;overflow:hidden;margin-top:20px;background:var(--surface-2)}
.mx-cost-0{background:#4b2e83}.mx-cost-1{background:#a388bb}.mx-cost-2{background:#387e78}.mx-cost-3{background:#b69142}.mx-cost-4{background:#778995}
.mx-cost-legend{gap:7px 12px}.mx-cost-legend b{font-weight:500;color:var(--ink)}
.mx-warning{background:var(--warn-soft,#fbefd9);color:var(--warn,#8a5300);border-radius:8px;padding:10px 16px;margin:16px 0}
.mx-warning ul{margin:0}.mx-warning li{font-size:13px;margin:4px 0}
.mx-assumption-grid{display:grid;grid-template-columns:1fr 1fr;gap:0 16px;margin-top:15px}
.mx-empty{padding:35px;background:var(--surface);border:1px dashed var(--line);border-radius:12px;text-align:center;color:var(--muted)}
@media(min-width:1600px){.mx-method-grid,.mx-example-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.mx-selector{grid-template-columns:340px minmax(0,1fr)}}
@media(max-width:1150px){.mx-selector{grid-template-columns:280px minmax(0,1fr);gap:15px}.mx-input-panel{padding:14px}.mx-inspect-grid{display:block}.mx-inspect-grid>img{max-height:190px;margin-bottom:18px}.mx-top>div{max-width:48%}.mx-tile>img{height:150px}}
@media(max-width:900px){.mx-top{display:block}.mx-top>div{display:none}.mx-tabs{width:100%;justify-content:space-around}.mx-tabs button{flex:1}.mx-method-grid,.mx-example-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.mx-selector{display:block}.mx-input-panel{position:static;max-height:none;margin-bottom:20px}.mx-input-panel>details{padding:13px}.mx-input-panel>details[open]{display:block}.mx-input-panel>details>.mx-input-pair{grid-template-columns:1fr 1fr}.mx-story{gap:22px;grid-template-columns:minmax(0,.85fr) minmax(0,1fr)}.mx-story-art figure>img{height:240px}.mx-intro{align-items:start}.mx-search-label{min-width:180px}.mx-inspect-grid{display:grid;grid-template-columns:220px 1fr}}
@media(max-width:650px){#p-mfg:not([hidden]){height:auto;min-height:65vh}#mfApp{height:auto}.mx{height:auto}.mx-scroll{overflow:visible}.mx-method-grid,.mx-example-grid{grid-template-columns:1fr 1fr;gap:10px}.mx-tile>img{height:120px}.mx-tile-copy{padding:11px;gap:4px}.mx-tile strong{font-size:16px}.mx-tile-copy>span{font-size:12px}.mx-tile small{font-size:9px}.mx-intro{display:block}.mx-search-label{display:block;margin-top:16px}.mx-count{display:none}.mx-story{display:block}.mx-story-art{position:static;margin-bottom:15px}.mx-story-art figure>img{height:250px}.mx-chapters{top:0}.mx-story-copy>section{padding-bottom:18px}.mx-title h3{font-size:30px}.mx-inspect-grid{display:block}.mx-inspect-head,.mx-chart-head{display:block}.mx-inspect-head .mx-button{margin-top:10px}.mx-chart-head>.mx-small{display:block;margin-top:10px}.mx-assumption-grid{grid-template-columns:1fr}.mx-metric-grid strong{font-size:23px}.mx-metric-grid{gap:17px}.mx-chart,.mx-inspect{padding:15px}.mx-top p{display:none}.mx-input-panel{padding:15px}.mx-actions>.mx-button{flex:1}.mx-badge{white-space:normal;font-size:11px}.mx-sequence>li{padding-left:10px;gap:10px}.mx-story-copy p{font-size:15px}}
@media(prefers-reduced-motion:reduce){.mx-scroll{scroll-behavior:auto}.mx-tile{transition:none}.mx-tile:hover{transform:none}}

/* Stage illustrations: sticky desktop story, inline mobile reading. */
.mx-step-copy{min-width:0;flex:1}
.mx-story figcaption>strong,.mx-story figcaption>span{display:block}
.mx-story figcaption>strong{font-size:14px;color:var(--text);margin-bottom:5px}
.mx-figure-sources{margin-top:8px;font-size:11px;line-height:1.55}
.mx-figure-sources a{color:var(--accent);text-decoration:underline;text-underline-offset:2px}
.mx-stage-art{display:none}
.mx-stage-view{border:0;background:transparent;padding:3px 0;color:var(--accent);font:inherit;font-size:13px;text-decoration:underline;cursor:pointer}
.mx-stage-view:focus-visible{outline:2px solid var(--accent);outline-offset:4px}
.mx-figure-picker button[aria-pressed="true"]{outline:2px solid var(--accent);outline-offset:2px}
@media(max-width:650px){.mx-stage-art{display:block!important;margin-top:14px!important;border:1px solid var(--line);border-radius:10px;overflow:hidden;background:var(--surface)}.mx-stage-art>img{display:block;width:100%;height:auto}.mx-stage-art figcaption{padding:10px;font-size:12px}.mx-stage-view{display:none}.mx-story-art .mx-figure-picker{display:none}}
@media print{.mx-stage-art{display:block}.mx-stage-art>img{max-width:100%;max-height:280px;object-fit:contain}.mx-stage-view{display:none}}

.mx-story-art figure>img{height:clamp(200px,25vw,330px)}
.mx-process-visual>img{display:block;width:100%;height:auto;background:#fff}

/* Tabs at the left, as the first thing on the page */
.mx-top{display:flex!important;justify-content:flex-start!important;padding:0}
.mx-top>div{display:none}
.mx-tabs{width:auto!important;justify-content:flex-start!important;gap:6px;padding:5px;border-radius:14px}
.mx-tabs button{flex:none!important;padding:11px 26px;font-size:16px;font-weight:600;color:var(--muted)}
.mx-tabs button:hover{color:var(--ink);background:color-mix(in srgb,var(--accent) 7%,transparent)}
.mx-tabs button[aria-selected=true]{color:var(--accent-ink,#fff)}
.mx-intro{display:flex!important;align-items:center;justify-content:space-between;gap:16px;margin:4px 0 14px}
.mx-note{margin:0;font-size:13.5px!important;color:var(--muted)}

/* Qualitative process selector: one step at a time */
.mx-selector2{display:flex;flex-direction:column;gap:18px;padding:4px 2px 20px}
.mx-sel-step h4{display:flex;align-items:center;gap:10px;margin:0 0 10px;font-size:18px}
.mx-sel-step h4 span{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:var(--accent);color:var(--accent-ink,#fff);font-size:14px}
.mx-sel-step.off h4{color:var(--muted)}.mx-sel-step.off h4 span{background:var(--line);color:var(--muted)}
.mx-sel-chips{display:flex;flex-wrap:wrap;gap:8px}
.mx-sel-chips button{cursor:pointer;border:1px solid var(--line);background:var(--surface,#fff);color:var(--ink);border-radius:12px;padding:9px 14px;font-size:15px;text-align:left}
.mx-sel-chips button:hover{border-color:var(--accent)}
.mx-sel-chips button[aria-pressed=true]{background:var(--accent);border-color:var(--accent);color:var(--accent-ink,#fff)}
.mx-sel-mats button{display:flex;flex-direction:column;gap:2px;min-width:220px}
.mx-sel-mats small{font-size:12.5px;opacity:.8}
.mx-sel-needs{display:grid;gap:10px}
.mx-sel-need{display:grid;grid-template-columns:minmax(220px,1fr) auto;align-items:center;gap:14px;padding:8px 12px;border:1px solid var(--line);border-radius:12px}
.mx-sel-need strong{display:block;font-size:15px}.mx-sel-need small{font-size:13px;color:var(--muted)}
.mx-sel-need .mx-sel-chips button{min-width:72px;text-align:center}
.mx-sel-tags{display:flex;flex-wrap:wrap;gap:4px;margin-top:6px}
.mx-sel-tags i{font-style:normal;font-size:11.5px;padding:2px 7px;border-radius:99px;background:color-mix(in srgb,var(--accent) 8%,transparent);color:var(--ink)}
.mx-sel-why{display:block;margin-top:6px;font-size:13px;color:#b42318}
.mx-sel-near{margin:18px 0 8px;font-size:15px;color:var(--muted)}
.mx-sel-need.off{opacity:.55}

/* Finished-part introduction is separate from the scrolling process study. */
.mx-example-grid .mx-tile>img{height:auto;aspect-ratio:3/2;object-fit:contain;background:#e6e8e9}
.mx-part-kicker{font-size:10px!important;font-weight:700;letter-spacing:.075em;text-transform:uppercase;color:var(--accent)!important}
.mx-part-overview{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:clamp(24px,3vw,46px);align-items:start;margin:0 0 42px;padding-bottom:32px;border-bottom:1px solid var(--line)}
.mx-part-photo{margin:0;border:1px solid var(--line);border-radius:14px;overflow:hidden;background:var(--surface,#fff)}
.mx-part-photo>img{display:block;width:100%;height:auto;aspect-ratio:3/2;object-fit:contain;background:#e6e8e9}
.mx-part-photo figcaption{font-size:12px;line-height:1.55;padding:14px 17px;color:var(--muted)}
.mx-part-photo figcaption>strong,.mx-part-photo figcaption>span{display:block}
.mx-part-photo figcaption>strong{color:var(--ink);font-size:14px;margin-bottom:5px}
.mx-part-intro h4{font-size:clamp(24px,2.4vw,32px);margin:7px 0 12px;line-height:1.15}
.mx-part-intro .mx-part-recognize{font-size:18px;line-height:1.45;color:var(--ink);margin-bottom:20px}
.mx-part-intro .mx-eyebrow{margin-top:4px}
.mx-part-intro .mx-sources{margin-top:15px}
.mx-example-process{padding-top:3px}
@media(max-width:800px){.mx-part-overview{grid-template-columns:1fr;gap:22px}.mx-part-photo{max-width:680px}.mx-part-intro .mx-part-recognize{font-size:17px}}
@media(max-width:650px){.mx-part-overview{margin-bottom:25px;padding-bottom:22px}.mx-part-photo figcaption{padding:12px}.mx-part-intro h4{font-size:25px}.mx-example-grid .mx-tile>img{height:auto}.mx-intro{flex-wrap:wrap}.mx-intro>div{min-width:0}}
@media print{.mx-part-overview{break-inside:avoid}.mx-part-photo>img{max-height:300px}}

/* Selector geometry: native schematic views, separate from process photographs. */
.mx-geometry-note{margin:0 0 14px!important}
.mx-geometry-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:13px;max-width:1200px}
.mx-geometry-card{position:relative;display:flex;flex-direction:column;align-items:flex-start;min-width:0;text-align:left;padding:13px 17px 16px;border:1px solid var(--line);border-radius:13px;background:var(--surface,#fff);color:var(--ink);cursor:pointer;transition:border-color .15s,box-shadow .15s}
.mx-geometry-card:hover{border-color:var(--accent);box-shadow:0 3px 14px #1d243010}
.mx-geometry-card[aria-pressed=true]{border:2px solid var(--accent);padding:12px 16px 15px;background:var(--accent-soft,#f1eef7)}
.mx-geometry-check{position:absolute;right:11px;top:10px;width:22px;height:22px;border:1px solid var(--line);border-radius:50%;display:grid;place-items:center;font-size:14px;line-height:1;background:var(--surface,#fff);color:var(--accent)}
.mx-geometry-card[aria-pressed=true] .mx-geometry-check{border-color:var(--accent);background:var(--accent);color:var(--accent-ink,#fff)}
.mx-geometry-art{display:block;width:100%;height:116px;margin-bottom:7px;color:var(--ink)}
.mx-geometry-art svg{display:block;width:100%;height:100%;overflow:visible}
.mx-geometry-card strong{font-size:16px;line-height:1.3;font-weight:600}
.mx-geometry-hint{display:block;font-size:12.5px;line-height:1.4;color:var(--muted);margin-top:5px;max-width:32ch}
.mx-geometry-art .geo-face{fill:#e3e9ee;stroke:#4a6072;stroke-width:1.65}
.mx-geometry-art .geo-side{fill:#b8c7d2;stroke:#4a6072;stroke-width:1.65}
.mx-geometry-art .geo-hole{fill:#718797;stroke:#4a6072;stroke-width:1.4}
.mx-geometry-art .geo-line{fill:none;stroke:#4a6072;stroke-width:1.5}
.mx-geometry-art .geo-detail{fill:none;stroke:#879ba9;stroke-width:1.2}
.mx-geometry-art .geo-guide{fill:none;stroke:#99abb8;stroke-width:1;stroke-dasharray:5 4}
.mx-geometry-help{max-width:72ch;margin:13px 0 5px;font-size:12px;color:var(--muted)}
.mx-geometry-help summary{cursor:pointer;text-decoration:underline;text-underline-offset:3px}
.mx-geometry-help p{font-size:13px;margin-top:8px}
@media(max-width:900px){.mx-geometry-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.mx-geometry-art{height:105px}}
@media(max-width:430px){.mx-geometry-card{padding:11px}.mx-geometry-card[aria-pressed=true]{padding:10px}.mx-geometry-card strong{font-size:14px}.mx-geometry-hint{font-size:11.5px}.mx-geometry-art{height:94px}}
@media(prefers-reduced-motion:reduce){.mx-geometry-card{transition:none}}

/* Detail pages: after the process story, defects and sources use the full width. */
.mx-after{margin:8px 0 24px;padding-top:28px;border-top:1px solid var(--line)}
.mx-after #mx-decisions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:clamp(20px,3vw,48px)}
.mx-after #mx-decisions h4,.mx-after #mx-evidence h4{margin-top:0}
.mx-after #mx-evidence{margin-top:26px;max-width:900px}
.mx-after .mx-actions{margin:0 0 14px}
@media(max-width:800px){.mx-after #mx-decisions{grid-template-columns:1fr}}
/* Method tiles: fill the frame */
.mx-method-grid .mx-tile>img,.mx-method-grid .mx-tile picture img{object-fit:cover}
/* Sticky story figure fits the window height, so the image stays visible while the steps scroll. */
@media(min-width:651px){
 .mx-story-art figure>img{height:clamp(150px,min(25vw,calc(100vh - 500px)),330px)}
}
@media(min-width:651px) and (max-height:780px){
 .mx-story-art .mx-figure-picker{display:none}
 .mx-story-art figure>img{height:clamp(130px,calc(100vh - 425px),330px)}
 .mx-story figcaption{padding:8px 14px}
}

/* Welding methods: external equipment alongside energy/load-path sections. */
.mx-weld-intro{max-width:1000px;margin:22px auto}.mx-table-scroll{overflow-x:auto}.mx-weld-comparison{border-collapse:collapse;width:100%;font-size:.92rem;margin:22px 0}.mx-weld-comparison caption{text-align:left;font-weight:650;margin-bottom:10px}.mx-weld-comparison th,.mx-weld-comparison td{padding:12px 14px;border:1px solid var(--line,#d5d9dd);text-align:left;vertical-align:top}.mx-weld-comparison thead{background:var(--surface,#fff)}.mx-weld-options{display:grid;gap:28px;margin:28px 0}.mx-weld-option{padding:clamp(14px,2.3vw,28px);border:1px solid var(--line,#d5d9dd);border-radius:14px}.mx-weld-option>h4{font-size:1.3rem;margin:0 0 20px}.mx-weld-visuals{display:grid;grid-template-columns:1fr 1fr;gap:20px;align-items:start}.mx-weld-visuals figure{min-width:0;margin:0}.mx-weld-visuals img{width:100%;height:auto;display:block;border-radius:9px;object-fit:contain;background:#f5f4ef}.mx-weld-visuals figcaption{font-size:.83rem;line-height:1.5;margin-top:10px}.mx-weld-visuals figcaption strong,.mx-weld-visuals figcaption span{display:block}.mx-weld-explanation{display:grid;grid-template-columns:1fr 1fr;gap:28px;margin-top:18px}.mx-weld-explanation h5{font-size:1rem;margin:16px 0 6px}.mx-weld-explanation p{margin:0 0 12px;line-height:1.65}@media(max-width:900px){.mx-weld-visuals,.mx-weld-explanation{grid-template-columns:1fr}.mx-weld-explanation{gap:0}.mx-weld-comparison{min-width:580px}}

/* One-screen slides for method and example pages (v84) */
.mx-scroll:has(.mx-slides){overflow:hidden;display:flex;flex-direction:column;padding-bottom:12px}
.mx-slides{flex:1 1 auto;min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr);gap:12px}
.mx-sl-head{display:flex;align-items:center;gap:14px;flex-wrap:wrap}
.mx-sl-titles{display:flex;flex-direction:column;min-width:0;flex:1 1 280px}
.mx-sl-titles h3{margin:0;font-size:clamp(20px,1.8vw,26px);line-height:1.2}
.mx-sl-chapters{display:flex;gap:6px;flex-wrap:wrap}
.mx-sl-chapters button{border:1px solid var(--line);background:var(--surface,#fff);border-radius:999px;padding:6px 14px;font:inherit;font-size:13.5px;cursor:pointer;color:var(--ink)}
.mx-sl-chapters button[aria-current="true"]{background:var(--accent);border-color:var(--accent);color:#fff}
.mx-slide{min-height:0;display:grid;grid-template-columns:minmax(0,1.5fr) minmax(330px,1fr);gap:18px;background:var(--surface,#fff);border:1px solid var(--line);border-radius:16px;padding:14px}
.mx-sl-media{min-height:0;display:flex;flex-direction:column}
.mx-sl-fig{flex:1 1 auto;min-height:0;margin:0;display:flex;flex-direction:column;border-radius:12px;overflow:hidden;background:#eef0f1}
.mx-sl-fig img{flex:1 1 auto;min-height:0;width:100%;height:100%!important;object-fit:contain;display:block}
.mx-sl-fig figcaption{flex:none;padding:7px 12px;font-size:12.5px;color:var(--muted);background:var(--surface,#fff)}
.mx-sl-fig figcaption b{color:var(--ink);font-weight:600}
.mx-sl-pair{flex:1 1 auto;min-height:0;display:grid;grid-template-rows:1fr 1fr;gap:10px}
.mx-sl-visual{flex:1 1 auto;min-height:0;display:flex;align-items:center;justify-content:center;background:#fff;border-radius:12px;overflow:hidden}
.mx-sl-visual figure{margin:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center}
.mx-sl-visual img,.mx-sl-visual svg{max-width:100%;max-height:100%;width:auto;height:auto;object-fit:contain}
.mx-sl-text{min-height:0;display:flex;flex-direction:column}
.mx-sl-text h4{margin:4px 0 10px;font-size:clamp(20px,1.7vw,26px);line-height:1.2}
.mx-sl-body{flex:1 1 auto;min-height:0;overflow:auto;padding-right:6px;scrollbar-gutter:stable}
.mx-sl-body p{font-size:15.5px;line-height:1.65;margin:0 0 10px}
.mx-sl-body .mx-sl-lead{font-size:17px;line-height:1.6;color:var(--ink)}
.mx-sl-body h5{margin:12px 0 4px;font-size:14px;color:var(--accent)}
.mx-sl-body .mx-bullets li{font-size:15.5px;line-height:1.6;margin-bottom:6px}
.mx-sl-about{margin-top:6px;font-size:13.5px}.mx-sl-about summary{cursor:pointer;color:var(--accent)}.mx-sl-about p{font-size:13.5px!important;color:var(--muted)}
.mx-sl-foot{flex:none;border-top:1px solid var(--line);padding-top:10px;margin-top:8px;display:flex;flex-direction:column;gap:8px}
.mx-sl-progress{display:flex;align-items:center;gap:4px}
.mx-sl-progress i{flex:1;height:4px;border-radius:2px;background:#e3e0ea}
.mx-sl-progress i.on{background:var(--accent)}
.mx-sl-progress span{margin-left:8px;font-size:12.5px;color:var(--muted);white-space:nowrap}
.mx-sl-nav{display:flex;gap:8px}
.mx-sl-btn{border:1px solid var(--line);background:#fff;border-radius:10px;padding:10px 14px;font:inherit;font-size:14.5px;cursor:pointer;color:var(--ink)}
.mx-sl-btn[disabled]{opacity:.35;cursor:default}
.mx-sl-next{flex:1;text-align:left;background:var(--accent);border-color:var(--accent);color:#fff;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.mx-sl-end{flex:1;align-self:center;font-size:14px;color:var(--muted)}
@media(max-width:900px){.mx-scroll:has(.mx-slides){overflow:auto;display:block}.mx-slides{display:block}.mx-slide{grid-template-columns:1fr;margin-top:10px}.mx-sl-fig img{height:auto!important;aspect-ratio:3/2}.mx-sl-pair{grid-template-rows:none}.mx-sl-body{overflow:visible}.mx-sl-foot{position:sticky;bottom:0;background:var(--surface,#fff);padding-bottom:8px}}
.mx .mx-sl-btn{font-size:14.5px}.mx .mx-sl-next{color:#fff;font-weight:600}.mx .mx-sl-next:hover{filter:brightness(1.12)}.mx .mx-sl-chapters button{font-size:13.5px}

/* v87: one image note for the section; image pairs sit side by side when the panel is wide */
.mx-imgnote{flex:none;margin:10px 2px 0;font-size:13px;line-height:1.5;color:var(--muted);max-width:110ch}
.mx-imgnote b{color:var(--ink);font-weight:600}
@media(min-width:901px){.mx-sl-media{container-type:size}
 @container (min-aspect-ratio:5/4){.mx-sl-pair{grid-template-columns:1fr 1fr;grid-template-rows:minmax(0,1fr)}}}
@media(max-width:900px){.mx-sl-pair{grid-template-columns:minmax(0,1fr)}.mx-slide,.mx-sl-media,.mx-sl-text{min-width:0}.mx-sl-fig img{max-width:100%}}
.mx-imgnote{margin:6px 2px 0;font-size:11.5px;line-height:1.4;color:#9a96a6;max-width:none;width:auto;align-self:stretch}
@media(max-width:900px){.mx-imgnote{white-space:normal}}
.mx .mx-imgnote{max-width:none!important}
/* v88: give the slide more height on short windows */
@media(min-width:901px){
 #content:has(#p-mfg:not([hidden])){padding-top:10px;padding-bottom:6px}
 .mx .mx-tabs{padding:3px}
 .mx .mx-tabs button{padding:7px 22px;font-size:15px}
 .mx-scroll:has(.mx-slides){padding-top:2px;padding-bottom:2px}
 .mx-slides{gap:8px}
 .mx-slide{padding:12px}
 .mx .mx-imgnote{margin:4px 2px 0}
}
.mx .mx-ailine{margin:0 2px 8px;font-size:11.5px;line-height:1.4;color:#9a96a6;max-width:none}
.mx-intro--slim{margin-top:0}

/* v89: search sits in the tab row; AI note beside the tabs */
.mx .mx-top{display:flex;align-items:center;gap:16px;flex-wrap:wrap}
.mx .mx-top .mx-ailine{margin:0;align-self:center}
.mx .mx-top-search{margin-left:auto;width:min(340px,40vw);height:38px;padding:0 12px;border:1px solid var(--line);border-radius:8px;background:#fff;font:inherit;font-size:14px;color:var(--ink)}
.mx .mx-top-search:focus{outline:2px solid var(--accent);outline-offset:1px;border-color:var(--accent)}
.mx .mx-filters{margin-top:4px}
@media(max-width:900px){.mx .mx-top-search{margin-left:0;width:100%}}

/* AI badge on generated images (v90) */
.ai-badge{position:absolute;top:8px;left:8px;z-index:3;padding:3px 6px 2px;border-radius:4px;background:rgba(18,14,30,.55);color:rgba(255,255,255,.95);font:700 10.5px/1.1 Arial,sans-serif;letter-spacing:.08em;backdrop-filter:blur(2px);pointer-events:auto;cursor:help;user-select:none}
.ai-badge{top:8px;left:8px}
.ai-badge{letter-spacing:.02em;font-size:10.5px;padding:3px 7px 2px;font-weight:600}
