/* Manufacturer tokens: the one source for the scanner's result sheet, the vehicle pages (t/<TWIN>/) and «Ab Werk».
   Values from the art direction (drafts/hersteller/BRIEF.md, measured on the makers' model pages, 10.11.2026). Each brand
   keeps its own scheme, independent of the system setting. Gellix carries every brand (the makers' faces are not licensed).
   Changed for legibility (WCAG 4.5:1 for small text): De Tomaso text 2 #888888 -> #6E6E6E, its button #8EC7E7 with white
   capitals -> #2B7BAA (the brief's own text blue); Lamborghini rows use #333333, the brief's #D8D8D8 stays for text 2.
   Pagani accent and loop carbon blue #6A8BC8 instead of silver #C9C7CC (critic 10.11.: silver read as HICONIUM grey). */
[data-brand]{
  --b-font:Gellix,-apple-system,"Helvetica Neue",sans-serif;
}
[data-brand=ferrari]{color-scheme:dark;--b-scheme:dark;
  --b-bg:#181818;--b-surface:#303030;--b-ink:#ffffff;--b-ink2:#969696;--b-accent:#DA291C;--b-on-accent:#ffffff;--b-line:#404040;
  --b-radius:999px;--b-head-case:uppercase;--b-head-track:.08em;--b-head-weight:500;--b-loop:#DA291C}
[data-brand=detomaso]{color-scheme:light;--b-scheme:light;
  --b-bg:#F3F3F3;--b-surface:#FFFFFF;--b-ink:#000000;--b-ink2:#6E6E6E;--b-accent:#2B7BAA;--b-on-accent:#ffffff;--b-line:#E2E2E2;
  --b-radius:999px;--b-head-case:uppercase;--b-head-track:.02em;--b-head-weight:500;--b-loop:#2B7BAA}
[data-brand=porsche]{color-scheme:light;--b-scheme:light;
  --b-bg:#FFFFFF;--b-surface:#F1F1F4;--b-ink:#010205;--b-ink2:#6B6D70;--b-accent:#010205;--b-on-accent:#ffffff;--b-line:#D8D8DB;
  --b-radius:8px;--b-head-case:none;--b-head-track:-.01em;--b-head-weight:400;--b-loop:#7D5530}
[data-brand=pagani]{color-scheme:dark;--b-scheme:dark;
  --b-bg:#000000;--b-surface:#141414;--b-ink:#FFFFFF;--b-ink2:#A1A1A1;--b-accent:#6A8BC8;--b-on-accent:#000000;--b-line:rgba(255,255,255,.3);
  --b-radius:0px;--b-head-case:uppercase;--b-head-track:.1em;--b-head-weight:400;--b-loop:#6A8BC8}
[data-brand=lamborghini]{color-scheme:dark;--b-scheme:dark;
  --b-bg:#000000;--b-surface:#181818;--b-ink:#F5F5F5;--b-ink2:#D8D8D8;--b-accent:#FFC000;--b-on-accent:#000000;--b-line:#333333;
  --b-radius:0px;--b-head-case:uppercase;--b-head-track:.01em;--b-head-weight:500;--b-loop:#FFC000}

/* ---------------------------------------------------------------- brand logo (original SVG, or the name until it is placed) */
.b-logo{display:inline-flex;align-items:center;height:var(--b-logo-h,22px);color:var(--b-ink)}
.b-logo img{height:100%;width:auto;max-width:var(--b-logo-w,150px);object-fit:contain;object-position:left center;display:block}
/* emblems at one optical size (same ink, not the same box): shields full height, the heavy T at 76 %, the flat Pagani
   oval by its width. On dark grounds the grey oval turns silver as a negative (no light plate: it read as a pill, 10.11.) */
img.lg-detomaso{height:76%}
img.lg-lamborghini{height:90%}
img.lg-pagani{height:auto!important;width:calc(var(--b-logo-h,22px) * 2.6);max-width:none}
img.lg-pagani.on-dark{filter:brightness(0) invert(.8)}
.b-logo span{font:var(--b-head-weight) 15px/1 var(--b-font);text-transform:var(--b-head-case);letter-spacing:var(--b-head-track);white-space:nowrap}

/* ---------------------------------------------------------------- result sheet of a Werkssignet (werksblatt.js) */
.wb{background:var(--b-bg);color:var(--b-ink);font-family:var(--b-font);font-size:15px;line-height:1.4;font-variant-numeric:tabular-nums lining-nums;
  font-synthesis:none;-webkit-font-smoothing:antialiased;text-align:left}
.wb *{box-sizing:border-box}
.wb p,.wb h2,.wb dl,.wb dd,.wb figure{margin:0}
.wb-ph{position:relative;aspect-ratio:3/2;background:var(--b-bg);overflow:hidden}
/* no box in the box: the studio ground of every car picture is the maker's ground, so the picture sits frameless on the
   sheet; the car (62 % of the picture's width) spans the sheet with 16 px air left and right (critic 10.11., round 2) */
/* fitted, never cut: each studio picture's car spans --x0 to --x0 + --span of its width (measured incl. wing and mirrors);
   the picture is scaled so exactly that span fills the sheet minus 16 px each side, and shifted so the car starts at 16 px */
.wb-ph img{position:absolute;left:16px;top:50%;width:calc((100% - 32px) / var(--span,.62));height:auto;max-width:none;
  transform:translate(calc(-100% * var(--x0,.19)),var(--wb-cy,-52%))}
.wb[data-brand=ferrari] .wb-ph img{--x0:.189;--span:.621}
.wb[data-brand=detomaso] .wb-ph img{--x0:.176;--span:.665}
.wb[data-brand=porsche] .wb-ph img{--x0:.175;--span:.653}
.wb[data-brand=pagani] .wb-ph img{--x0:.19;--span:.621}
.wb[data-brand=lamborghini] .wb-ph img{--x0:.185;--span:.626;--wb-cy:-64%}
.wb-ph .b-logo{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);--b-logo-h:44px;--b-logo-w:180px;opacity:.35}
.wb-ph .b-logo img{object-position:center}
.wb-in{padding:18px 20px 20px}
.wb-top{display:flex;align-items:center;justify-content:space-between;gap:12px;--b-logo-h:32px;--b-logo-w:140px}
.wb-lab{font-size:13px;color:var(--b-ink2)}
.wb-from{font-size:13px;color:var(--b-ink2);margin-top:12px;text-wrap:pretty}
.wb-from span{white-space:nowrap}
.wb-nm{font-size:24px;line-height:1.1;font-weight:var(--b-head-weight);text-transform:var(--b-head-case);letter-spacing:var(--b-head-track);margin-top:4px;text-wrap:balance}
.wb-yr{font-size:15px;color:var(--b-ink);margin-top:2px}
.wb-id{font-size:13px;color:var(--b-ink2);margin-top:6px;letter-spacing:.02em}
.wb .wb-checks{margin-top:14px;border-top:1px solid var(--b-line)}
.wb .wb-checks div{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 14px;padding:10px 0;border-bottom:1px solid var(--b-line);font-size:13px}
.wb .wb-checks div:last-child{border-bottom:1px solid var(--b-line)}
.wb .wb-checks dt{color:var(--b-ink2)}
.wb .wb-checks dd{text-align:right;font-weight:500;white-space:nowrap}
.wb-checks .seal dd{display:flex;align-items:center;gap:7px;justify-content:flex-end}
.wb-checks .seal dd::before{content:"";width:8px;height:8px;border-radius:50%;background:#30d158;flex:none}
.wb-checks .seal.bad dd::before{background:#ff453a}
.wb-checks .seal p{grid-column:1/-1;color:var(--b-ink2);font-size:12px;text-wrap:pretty}
.wb-acts{display:grid;gap:8px;margin-top:16px}
.wb-btn{all:unset;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:48px;padding:0 20px;
  border-radius:var(--b-radius);background:var(--b-accent);color:var(--b-on-accent);font:500 15px/1 var(--b-font);text-transform:var(--b-head-case);
  letter-spacing:min(var(--b-head-track),.08em);cursor:pointer;text-decoration:none;transition:transform .16s ease-out,opacity .16s ease-out;touch-action:manipulation;
  -webkit-tap-highlight-color:transparent}
.wb-btn.alt{background:var(--b-surface);color:var(--b-ink)}
.wb-btn:focus-visible{outline:2px solid var(--b-ink);outline-offset:3px}
@media (hover:hover) and (pointer:fine){.wb-btn:hover{opacity:.86}}
@media (prefers-reduced-motion:no-preference){.wb-btn:active{transform:scale(.96)}}
.wb-btn svg{width:18px;height:18px;fill:currentColor;flex:none}
.wb-fail{margin-top:12px;color:var(--b-ink2);font-size:13px;text-wrap:pretty}
