/* whirrcrew.com: the inner-page templates beyond the kit (src/views/site/{pages,sections,case-study}.js). Loaded after
   site.css on every page; it uses the kit's tokens (whc.css) and adds no fonts and no colours of its own.
     1. rhythm: even, generous space between the blocks of a page
     2. testimonials: one person and the quote at a time, taking turns slowly (public/site/pages.js)
     3. the four practices as links (About)
     4. About: a composition across the whole width
     5. service pages: a tile the services map links to
     6. client logos: one ink, one optical size */

/* ---------- 1. rhythm ---------- */
/* a list that opens a section without a heading would draw its own top rule right under the section's rule */
.page-body>.wrap>.blk>:is(.tiles,.ticks,.steps,.faq,.stats,.rows):first-child{border-top:0}
.page-body>.wrap>.smap--page+*{margin-top:var(--space-stack)}
/* the line of more links under a block keeps the block's own air, not the page's */
.page-body>.wrap>.blk+.blk-more{margin-top:calc(var(--space-stack) - 8px)}

/* a heading beside its words: on About, a section of text; on a service page, a section whose heading has a lead or
   text before its list. From 1101px the heading on the left and its words on the right, on the same 6/6 grid as the
   page's opening (so every text on the page starts on one axis), the heading's first line on the words' first line;
   what the section lists runs under both, across the width. Below 1101px, one column */
@media (min-width:1101px){
  :is(.page-body--about>.wrap>.blk--text,.page-body--service>.wrap>.blk:has(>.blk-h+:is(.blk-lead,.blk-p))){display:grid;grid-template-columns:minmax(0,6fr) minmax(0,6fr);column-gap:var(--col-gap);align-items:baseline}
  :is(.page-body--about>.wrap>.blk--text,.page-body--service>.wrap>.blk)>.blk-h{grid-column:1}
  :is(.page-body--about>.wrap>.blk--text,.page-body--service>.wrap>.blk)>.blk-h+:is(.blk-lead,.blk-p){grid-column:2;margin-top:0;max-width:36em}
  :is(.page-body--about>.wrap>.blk--text,.page-body--service>.wrap>.blk:has(>.blk-h+:is(.blk-lead,.blk-p)))>:not(.blk-h,.blk-lead,.blk-p){grid-column:1/-1}
  /* a list of one card (a practice with one case study, an article with one related one) stands beside its heading
     on the same grid, not alone in a third of the width */
  .page-body>.wrap>.blk:has(>.blk-h+.cards>li:only-child){display:grid;grid-template-columns:minmax(0,6fr) minmax(0,6fr);column-gap:var(--col-gap);align-items:start}
  .page-body>.wrap>.blk:has(>.blk-h+.cards>li:only-child)>.blk-h{grid-column:1}
  .page-body>.wrap>.blk:has(>.blk-h+.cards>li:only-child)>.cards{grid-column:2;grid-template-columns:minmax(0,1fr);margin-top:0}
  .page-body>.wrap>.blk:has(>.blk-h+.cards>li:only-child)>:not(.blk-h,.cards){grid-column:2}
}

/* ---------- 2. testimonials (sections.js testimonials) ---------- */
/* each one: the person on the left, the quote beside them in the quote size, behind today's two-bar mark. Without the
   script every quote shows, one under another on hairlines; with it (.vx.on) they take turns in one place */
.vx{margin-top:var(--space-stack)}
.vx-stage{display:grid;gap:0}
.vx-q{display:grid;grid-template-columns:minmax(0,4fr) minmax(0,8fr);grid-template-areas:"who text";column-gap:var(--col-gap);align-items:start;margin:0}
.vx-q+.vx-q{margin-top:var(--space-block);padding-top:var(--space-block);border-top:1px solid var(--line)}
.vx-text{grid-area:text;position:relative;isolation:isolate;max-width:31em;padding-top:12px;font-size:var(--t-quote);font-style:italic;font-weight:400;line-height:1.45;letter-spacing:-.01em;color:var(--text);text-wrap:pretty}
.vx-text::before,.vx-text::after{content:"";position:absolute;top:-4px;z-index:-1;width:17px;height:40px;background:var(--qbar)}
.vx-text::before{left:-19px}
.vx-text::after{left:2px}
.vx-text p+p{margin-top:.7em}
.vx-who{grid-area:who;display:grid;justify-items:start;align-content:start;gap:18px;font-size:var(--t-small);line-height:1.5;color:var(--muted)}
.vx-who .face{width:88px;height:88px;font-size:24px}
.vx-who b{display:block;margin-bottom:3px;font-size:var(--t-body);font-weight:500;line-height:1.35;color:var(--text)}
.vx-who>span{max-width:18em}

/* taking turns: every quote in one cell, so the block keeps the height of the longest and nothing below it moves */
/* a turn is one calm sequence, nothing in it jumps (owner, 29 Oct): the quote being left fades where it stands, the bar
   glides (ease-in-out, never a snap) to where the next one ends, and the next one fades in, rising a few pixels. The order
   follows the direction (pages.js sets .vx-down): a longer quote waits until the bar is out of its way, below a shorter
   one the bar follows it up once the old one has gone */
.vx.on{--vx-glide:.22s;--vx-in:.32s}
.vx.on.vx-down{--vx-glide:0s;--vx-in:.62s}
.vx.on .vx-q{grid-area:1/1;align-self:start;margin:0;padding:0;border:0;opacity:0;visibility:hidden;transition:opacity .4s ease,visibility 0s .4s}
.vx.on .vx-q.is-on{opacity:1;visibility:visible;animation:vx-in .9s var(--out) var(--vx-in) backwards;transition:opacity .8s ease-out var(--vx-in),visibility 0s}
@keyframes vx-in{from{transform:translateY(6px)}}
/* the controls: a hairline that draws while one is read (the hero verb's rule, slowed down), where we are, the arrows
   and the pause; only with the script */
.vx-bar{display:none}
/* the bar keeps its place in the flow (so nothing below moves) but rises to stand right under the quote being read:
   --vx-lift is how much shorter it is than the tallest (pages.js) */
.vx.on .vx-bar{display:flex;align-items:center;gap:8px;margin-top:clamp(18px,2vw,26px);transform:translateY(calc(-1 * var(--vx-lift,0px)));transition:transform .78s cubic-bezier(.45,0,.25,1) var(--vx-glide)}
.vx-rule{position:relative;flex:1 1 auto;height:1px;margin-right:16px;background:var(--line-2)}
.vx-rule>span{position:absolute;inset:0;background:var(--text);transform:scaleX(0);transform-origin:left}
/* at a turn the drawn hairline fades rather than snapping back; the next one starts drawing once the bar has arrived */
.vx-rule.out>span{opacity:0;transition:opacity .3s ease;animation-play-state:paused}
.vx-rule.run>span{animation:vx-draw var(--vx-dwell,5s) linear forwards}
.vx.held .vx-rule>span{animation-play-state:paused}
@keyframes vx-draw{to{transform:scaleX(1)}}
.vx-count{min-width:3.4em;margin-right:6px;text-align:right;font-size:var(--t-caption);font-weight:600;color:var(--muted);font-variant-numeric:tabular-nums}
.vx-btn{display:grid;place-items:center;flex:none;width:40px;height:40px;border-radius:9px;border:1px solid var(--line-2);color:var(--text-2);transition:border-color .2s,color .2s}
.vx-btn:hover{border-color:var(--text);color:var(--text)}
.vx-btn .i{width:16px;height:16px}
.vx-play .vx-i-play,.vx.stopped .vx-play .vx-i-pause{display:none}
.vx.stopped .vx-play .vx-i-play{display:block}
@media (max-width:1100px){ .vx-q{grid-template-columns:minmax(0,3fr) minmax(0,8fr);column-gap:clamp(28px,4vw,48px)} }
@media (max-width:720px){
  .vx-q{grid-template-columns:minmax(0,1fr);grid-template-areas:"text" "who"}
  .vx-text{padding-top:10px}
  /* the two bars as the home page's quotes have them on a phone: smaller, and inside the gutter, not on the bezel */
  .vx-text::before,.vx-text::after{top:-2px;width:11px;height:26px}
  .vx-text::before{left:-13px}
  .vx-text::after{left:1px}
  .vx-who{grid-template-columns:56px minmax(0,1fr);align-items:center;gap:14px;margin-top:24px}
  .vx-who .face{width:56px;height:56px;font-size:18px}
  .vx-rule{margin-right:8px}
}

/* ---------- 3. the four practices as links (sections.js practiceIndex; About) ---------- */
/* four equal ruled cells in the fixed order: the practice's figure, its name and its one line; the whole cell is the
   link, its rule draws in ink and its figure moves when pointed at */
.prx{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));column-gap:var(--grid-gap);list-style:none}
.prx-p{position:relative;display:flex;flex-direction:column;gap:12px;padding:32px 32px 34px 0;border-top:1px solid var(--line-2)}
.prx-p::before{content:"";position:absolute;left:0;right:0;top:-1px;height:1px;background:var(--text);transform:scaleX(0);transform-origin:left;transition:transform .7s var(--out)}
.prx-p:is(:hover,:focus-within)::before{transform:scaleX(1)}
.prx-p .fig{width:40px;height:40px;margin-bottom:14px}
.prx-name{font-size:var(--t-h3);font-weight:500;line-height:1.25;letter-spacing:-.02em;color:var(--text);text-wrap:balance}
.prx-name a::after{content:"";position:absolute;inset:0}
.prx-name a:focus-visible{outline:0}
.prx-p:has(a:focus-visible){outline:2px solid var(--accent);outline-offset:6px;border-radius:4px}
.prx-line{max-width:24em;font-size:var(--t-small);line-height:1.6;color:var(--text-2);text-wrap:pretty}
.prx-go{position:absolute;right:0;top:40px;color:var(--muted);transition:transform .3s var(--out),color .2s}
.prx-p:hover .prx-go{color:var(--accent);transform:translateX(3px)}
.prx-p:hover .prx-name{color:var(--accent)}
.prx-name{transition:color .2s}
@media (max-width:1100px){ .prx{grid-template-columns:repeat(2,minmax(0,1fr));row-gap:8px} }
@media (max-width:560px){
  .prx{grid-template-columns:minmax(0,1fr);row-gap:0}
  .prx-p{display:grid;grid-template-columns:32px minmax(0,1fr) 16px;column-gap:16px;row-gap:6px;padding:22px 0}
  .prx-p .fig{width:32px;height:32px;margin:0;grid-row:span 2}
  .prx-line{grid-column:2}
  .prx-p{padding-right:0}
  .prx-go{position:static;grid-column:3;grid-row:1;align-self:center}
}

/* ---------- 4. About (pages.js aboutPage): the whole width, never one column beside an empty half ---------- */
/* the opening, one story about the company: its words on the left, the page's values on the right (or, without them,
   the picture it carries); under both, how the company grew, its paragraphs in two columns on the same grid, so the
   text lines up with the words and the values above it */
.about-intro{display:grid;grid-template-columns:minmax(0,6fr) minmax(0,6fr);column-gap:var(--col-gap);align-items:center}
.about-intro--one{grid-template-columns:minmax(0,1fr)}
.about-words{max-width:36em}
.about-words>p:first-child{font-size:var(--t-lead);line-height:1.6;color:var(--text)}
.about-story{grid-column:1/-1;margin-top:var(--space-block)}
.about-story-h{font-size:var(--t-h3);font-weight:500;line-height:1.3;letter-spacing:-.015em;color:var(--text);text-wrap:balance}
.about-story-h+.about-story-text{margin-top:var(--space-head)}
.about-story-text{max-width:none;columns:2;column-gap:var(--col-gap)}
/* a paragraph never breaks across the columns; the columns share the height between them (a paragraph's top margin is
   dropped where it starts a column, so both columns start on one line) */
.about-story-text>*{break-inside:avoid}
/* the values (pages.js valuesBlock): the line in the section-heading size, its strong words in the accent, then the
   values ruled two by two, each with the ruled list's short accent marker. Type and tokens only: it reads in both
   lights, at any width, and to a screen reader as words */
.about-values{display:grid;gap:clamp(28px,3vw,40px)}
.about-values-line p{max-width:14em;font-size:var(--t-h2);font-weight:500;line-height:1.1;letter-spacing:-.03em;color:var(--text);text-wrap:balance}
.about-values-line strong{font-weight:500;color:var(--accent)}
.about-values-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:clamp(24px,2.6vw,40px);list-style:none;margin:0}
.about-values-list li{display:grid;grid-template-columns:22px minmax(0,1fr);padding:14px 0;border-bottom:1px solid var(--line);font-size:var(--t-body);font-weight:500;line-height:1.4;color:var(--text)}
.about-values-list li:nth-child(-n+2){border-top:1px solid var(--line-2)}
.about-values-list li::before{content:"";width:12px;height:2px;margin-top:calc(.7em - 1px);background:var(--accent)}
.about-pic>*{margin:0}
.about-pic img{display:block;width:100%;height:auto;border-radius:16px;border:1px solid var(--line);background:var(--bg-2)}
/* a section of text: its heading on the left, the text on the right (1. rhythm → a heading beside its words), the text
   in the lead's size */
.page-body--about .blk--text>.blk-h{max-width:12em}
.page-body--about .blk--text>.blk-p{font-size:var(--t-lead);line-height:1.65}
/* the team: a calm grid of faces, names and roles */
.page-body--about .team{grid-template-columns:repeat(auto-fill,minmax(min(140px,100%),1fr));gap:48px 32px}
.page-body--about .team .face{width:88px;height:88px}
.page-body--about .team b{font-size:var(--t-body);margin-top:4px}
.page-body--about .team li>span{font-size:var(--t-small);color:var(--muted)}
@media (max-width:1100px){
  .about-intro{grid-template-columns:minmax(0,1fr);row-gap:var(--space-stack)}
  .about-words{max-width:var(--measure)}
  /* one column of text at the measure: the story follows the values as the words' next paragraphs */
  .about-story{margin-top:calc(var(--space-block) - var(--space-stack))}
  .about-story-text{columns:auto;max-width:var(--measure)}
}
@media (max-width:560px){ .page-body--about .team{grid-template-columns:repeat(2,minmax(0,1fr));gap:32px 16px} }

/* ---------- 5. service pages: the tile a services map item links to (#penetration-testing …) ---------- */
.tile[id],.steps li[id],.faq details[id]{scroll-margin-top:calc(var(--nav-h) + 32px)}
.tile:target::before{content:"";position:absolute;left:0;right:0;top:-1px;height:2px;background:var(--accent);transform-origin:left;animation:tile-mark 1.2s var(--out)}
@keyframes tile-mark{from{transform:scaleX(0)}}
.tile:target .tile-h{color:var(--accent)}

/* ---------- 6. client logos: one ink, one optical size ---------- */
/* Every client mark is drawn in the same ink in both themes: our one-colour marks (/assets/clients/mono, drawn as a mask)
   and any other uploaded logo (turned to one tone: black by day, white by night, at the strength of the masks). Each is
   sized from what it actually draws, so the marks read as one size and say at once whose case it is (owner, 29 Oct,
   second pass: larger). Measured from the files (29 Oct): the ink's box, its share of the file (the empty margins) and
   its density (how much of its box the ink covers). The ink gets about 3800 px² at a card's scale, more for a light or
   open mark and less for a solid block (density^-0.5, within .75-1.5), a little more for a long wordmark ((ink
   aspect / 3)^0.2, within .85-1.2), 16 to 56 px tall and at most 200 px wide; a few are set by eye: MPSV's and Praha 4's
   small lettering beside their crests and Budvar's crest a little larger, the solid blocks of LINET, Siemens, DHL,
   BulletTech and MALL a little smaller. The table gives each file its proportions (--lr), its box height (--lh, px at a
   card's scale, so its ink comes out at its size) and the empty margins worth cutting off (--pt, --pb, --pl, --pr:
   fractions of the file, taken off with negative margins so the ink, not the file, lines up with the card's edge). A
   file not listed is fitted into a 160 x 30 box. --k scales the whole set (the case page draws them a little larger). */
:is(.card-logo,.case-logo){--k:1;--lr:4;--lh:30;--pt:0;--pb:0;--pl:0;--pr:0;flex:none;max-width:none}
.card-logo--mask,.case-logo--mask{background:var(--text-2);opacity:.8;-webkit-mask:var(--src) no-repeat center/contain;mask:var(--src) no-repeat center/contain}
/* (.card-top> lifts the rule over site.css's .card-top>.card-logo margin) */
:is(.card-top>.card-logo--mask,.card-logo--mask,.case-logo--mask),
:is(.card-logo,.case-logo):is([src$="/a3b84fa1adafb02f.png"],[src$="/e26d7808fd0c7444.png"]){
  display:block;object-fit:contain;
  height:calc(var(--lh) * var(--k) * 1px);
  width:calc(var(--lh) * var(--lr) * var(--k) * 1px);
  margin:calc(var(--pt) * var(--lh) * var(--k) * -1px) calc(var(--pr) * var(--lh) * var(--lr) * var(--k) * -1px) calc(var(--pb) * var(--lh) * var(--k) * -1px) calc(var(--pl) * var(--lh) * var(--lr) * var(--k) * -1px)}
/* an uploaded logo we hold no measure of: fitted into the same box */
img:is(.card-logo,.case-logo){height:calc(30px * var(--k));width:auto;max-width:calc(160px * var(--k));object-fit:contain;object-position:left center;filter:brightness(0);opacity:.56}
@media (prefers-color-scheme:dark){ :root:not([data-theme="light"]) img:is(.card-logo,.case-logo){filter:brightness(0) invert(1);opacity:.6} }
:root[data-theme="dark"] img:is(.card-logo,.case-logo){filter:brightness(0) invert(1);opacity:.6}
/* a client named in words (anonymised cases, our own product) in the same ink and strength as the marks, large enough
   to stand where a mark would */
.card-client{font-size:var(--t-lead);font-weight:600;line-height:1.3;letter-spacing:-.01em;color:var(--text-2);opacity:.8}
/* the case page: the client's mark above the facts, a little larger */
.case-logo-box{padding:4px 0 28px}
.case-logo-box :is(.case-logo,.case-logo--mask){--k:1.1;opacity:.85}
.case-logo-box .case-logo--mask{background:var(--text)}

/* the measures (generated from the files, 29 Oct: see above) */
:is(.card-logo,.case-logo)[style*="/baseus-wordmark.png)"]{--lr:4.511;--lh:27.9;--pt:.015}
:is(.card-logo,.case-logo)[style*="/bluedynamic-h.png)"]{--lr:2.614;--lh:43.9}
:is(.card-logo,.case-logo)[style*="/bluedynamic.png)"]{--lr:.719;--lh:57.1}
:is(.card-logo,.case-logo)[style*="/budvar.png)"]{--lr:1.542;--lh:53.1}
:is(.card-logo,.case-logo)[style*="/bullettech.png)"]{--lr:4.615;--lh:25.8}
:is(.card-logo,.case-logo)[style*="/creativedock.png)"]{--lr:6.383;--lh:29.2;--pt:.016;--pb:.016}
:is(.card-logo,.case-logo)[style*="/creditinfo.svg)"]{--lr:3.226;--lh:61.4;--pt:.231;--pb:.199;--pl:.092;--pr:.082}
:is(.card-logo,.case-logo)[style*="/cscargo.png)"]{--lr:5.769;--lh:28.4}
:is(.card-logo,.case-logo)[style*="/csobpoj.png)"]{--lr:3.117;--lh:38.7}
:is(.card-logo,.case-logo)[style*="/dhl.svg)"]{--lr:4.511;--lh:32.9;--pt:.177;--pb:.177}
:is(.card-logo,.case-logo)[style*="/drmax.svg)"]{--lr:2.934;--lh:38.3}
:is(.card-logo,.case-logo)[style*="/euc.png)"]{--lr:1;--lh:56.6}
:is(.card-logo,.case-logo)[style*="/finchtrade.png)"]{--lr:6.154;--lh:26.2;--pt:.031;--pb:.041}
:is(.card-logo,.case-logo)[style*="/heureka.svg)"]{--lr:4.364;--lh:34.9;--pb:.2}
:is(.card-logo,.case-logo)[style*="/ima.png)"]{--lr:1.762;--lh:42.6}
:is(.card-logo,.case-logo)[style*="/jrd.png)"]{--lr:3.499;--lh:31.1}
:is(.card-logo,.case-logo)[style*="/kb.svg)"]{--lr:2.548;--lh:33.8}
:is(.card-logo,.case-logo)[style*="/lagardere.png)"]{--lr:3.571;--lh:34.6}
:is(.card-logo,.case-logo)[style*="/linet.png)"]{--lr:5.607;--lh:23.6}
:is(.card-logo,.case-logo)[style*="/mall.png)"]{--lr:3.67;--lh:27.7}
:is(.card-logo,.case-logo)[style*="/mpsv.png)"]{--lr:2.649;--lh:51.6}
:is(.card-logo,.case-logo)[style*="/onepak.png)"]{--lr:3.27;--lh:39.6}
:is(.card-logo,.case-logo)[style*="/praha4.png)"]{--lr:1.964;--lh:54.7;--pt:.016;--pb:.015}
:is(.card-logo,.case-logo)[style*="/projectman.png)"]{--lr:3.27;--lh:42.8}
:is(.card-logo,.case-logo)[style*="/siemens.svg)"]{--lr:4.196;--lh:35.2;--pt:.185;--pb:.192;--pl:.032;--pr:.036}
:is(.card-logo,.case-logo)[style*="/siko.png)"]{--lr:2.948;--lh:33.3}
:is(.card-logo,.case-logo)[style*="/tesco.svg)"]{--lr:3.448;--lh:32.3;--pb:.023}
:is(.card-logo,.case-logo)[style*="/tmobile-wordmark.png)"]{--lr:4.8;--lh:29.4}
:is(.card-logo,.case-logo)[style*="/tradingtech.png)"]{--lr:6.897;--lh:29.1;--pt:.017;--pb:.017}
:is(.card-logo,.case-logo)[style*="/vwfs.png)"]{--lr:5.128;--lh:31.8}
/* uploaded logos that have no one-colour mark yet: SÚRAO, AI Reply */
:is(.card-logo,.case-logo)[src$="/a3b84fa1adafb02f.png"]{--lr:2.198;--lh:64.9;--pt:.284;--pb:.223;--pl:.095;--pr:.092}
:is(.card-logo,.case-logo)[src$="/e26d7808fd0c7444.png"]{--lr:3.715;--lh:49.8;--pt:.17;--pb:.115;--pl:.192;--pr:.194}

@media (prefers-reduced-motion:reduce){
  .vx.on .vx-q,.vx.on .vx-q.is-on,.vx.on .vx-bar,.vx-rule.out>span{transition:none}
  .vx.on .vx-q.is-on{animation:none}
  .vx-rule>span{animation:none!important}
  .vx-play{display:none}
  .prx-p::before,.prx-go{transition:none}
  .tile:target::before{animation:none}
}

/* the About banner is a light picture; by night it is dimmed a little so it does not glare on the night ink */
@media (prefers-color-scheme:dark){ :root:not([data-theme="light"]) .about-pic img{filter:brightness(.86)} }
:root[data-theme="dark"] .about-pic img{filter:brightness(.86)}
