/* The calculator page's own rules, for the English page (drafts/en/machine-vision-lens-calculator.html) and the Polish
   one (drafts/pl/kalkulator-obiektywu-kamery.html), linked after the site's styles.css. Draft-only: they move into
   site/assets/styles.css when the pages are published (DEPLOY.md, "To publish a draft", step 7). */
/* one column for every block of the tool (round 6): inputs, results, figures, Equations and Assumptions, display
   formulas, the exports, the Q&A and the enquiry block; display formulas are centred in it */
:root{--col:760px}
html{scroll-padding-top:84px}
.tool>:not(h1),.tool .calc,.tool .actions,#contact .card{max-width:var(--col)}
.wrap.tool{max-width:calc(var(--col) + 96px)}
.choice{border:0;margin:0;padding:0;min-width:0}
.choice legend{font-family:var(--mono);font-size:11px;letter-spacing:.08em;color:var(--muted);padding:0;margin-bottom:12px}
.choice label{display:inline-flex;align-items:center;gap:8px;margin:0 22px 6px 0;font-family:var(--serif);font-size:16px;letter-spacing:0;color:var(--ink)}
.choice input{width:auto;margin:0;padding:0;accent-color:var(--signal)}
.units{margin-top:28px}
[data-pre="exSensor"],[data-pre="exWindow"],[data-pre="exPixels"],[data-pre="exScene"]{white-space:nowrap}
.step{border-top:1px solid var(--line);padding-top:28px}
.step h2{margin-bottom:12px}
.step h3{margin:36px 0 10px}
.calc{margin:20px 0 28px}
.calc .spec{margin-top:6px}
.calc .range{display:flex;align-items:center;gap:12px}
.calc .range input[type=range]{flex:1;min-width:0;min-height:32px;padding:0;border:0;background:none;accent-color:var(--signal)}
.calc .range input[type=text]{flex:none;width:7.5em;padding:8px 10px;font-family:var(--mono);font-size:14px;text-align:right}
.calc .range .unit{min-width:2.6em;font-family:var(--mono);font-size:13px;color:var(--ink)}
.calc .msg{color:var(--ink)}
.calc .msg:empty{display:none}
.calc [hidden]{display:none!important}
.calc .uses{margin:0 0 4px}
.calc .bar{--cols:2;margin:28px 0 8px}
.calc .bar[data-cols="1"]{--cols:1}
.calc .bar[data-cols="3"]{--cols:3}
.calc .bar[data-cols="4"]{--cols:4}
.calc .bar b{display:block;font-family:var(--sans);font-weight:800;font-size:32px;letter-spacing:-.02em;color:var(--ink);margin-top:6px}
.calc .bar b sup{font-size:.55em;letter-spacing:0}
.calc .bar .sub{display:block;margin-top:6px;font-size:12px;letter-spacing:.04em;line-height:1.5;color:var(--muted)}
.fig{margin:32px 0 0}
.fig .figtitle{margin:0 0 10px;font-family:var(--mono);font-size:12px;letter-spacing:.04em;line-height:1.5;color:var(--ink)}
.fig .formnote,.calc .scalenote{margin-top:8px}
.diagram svg{display:block;width:100%;height:auto}
.diagram svg.turn{cursor:grab;touch-action:pan-y}
.diagram svg.track{cursor:crosshair;touch-action:pan-y}
.diagram text{font-family:var(--mono);font-size:13px;letter-spacing:.02em;fill:var(--muted);paint-order:stroke;stroke:var(--paper);stroke-width:3px;stroke-linejoin:round}
.diagram text.t{fill:var(--ink)}
.actions{display:flex;flex-wrap:wrap;align-items:center;gap:8px 24px;margin:0;padding-top:14px;border-top:1px solid var(--line)}
.actions .export{display:inline-flex;align-items:center;gap:7px;padding:6px 0;background:none;border:0;cursor:pointer;font-family:var(--mono);font-size:12px;letter-spacing:.06em;color:var(--muted)}
.actions .export:hover{color:var(--ink)}
.actions .export svg{width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.actions .formnote{margin:0}
.vh{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
math{font-family:"STIX Two Math","Cambria Math","Latin Modern Math",math}
math[display="block"]{margin:14px 0;font-size:1.25em}
.eqrow{display:flex;flex-wrap:wrap;justify-content:center;align-items:baseline;column-gap:1.5em}
.eqrow>math{flex:none}
.nobr{white-space:nowrap}
.steplead{margin:0 0 4px}
.calc .bar .lab{display:block}
/* each cell's label, value and sub-lines on rows shared across the bar, so the values in a bar share one line whatever
   the labels' lengths (round 6) */
.calc .bar>div{display:grid;grid-template-rows:subgrid;grid-row:span 4;align-content:start}
.calc .bar math,.calc label math,.calc legend math{font-size:13px}
.calc .bar .sub.remedy{font-family:var(--serif);font-size:14px;letter-spacing:0;line-height:1.5;color:var(--ink)}
.parts{margin-top:28px}
.parts details{border-top:1px solid var(--line)}
.parts details:last-child{border-bottom:1px solid var(--line)}
.parts summary{cursor:pointer;padding:10px 0;min-height:44px}
.parts summary h3{display:inline;margin:0}
.parts details[open]{padding-bottom:16px}
.parts details[open]>summary{margin-bottom:12px}
.cite{margin-top:12px}
.parts ul.plain{margin-top:8px}
@media (max-width:1000px){.actions .export{min-height:44px}}
@media (max-width:620px){.choice label,.calc .range input[type=text]{min-height:44px}}
@media (max-width:620px){math[display="block"]{font-size:1em}}
@media (max-width:400px){math[display="block"]{font-size:.92em}}
