/* Louhos Digital 2026 – WordPress-toteutuksen lisäykset vedoksen tyylien päälle.
   Vedoksen omat säännöt ovat tiedostoissa louhos.css (yhteinen), sub.css (alasivut) ja front.css (etusivu).
   Tänne vain se, mitä vedoksessa ei ollut: sivupuusta muodostuva megamenu, Gutenberg-sisältö ym. */

main:focus{outline:0}
.foot-slogan{max-width:24em;margin:18px 0 0}
.foot h3.s a{color:inherit;text-decoration:none}
.foot h3.s a:hover{color:var(--paperi)}

/* Loppu-CTA:n kappale (palvelusivu) – yhteinen kaikille sivuille */
.cta>p{position:relative;z-index:1;margin:22px 0 0;font-size:clamp(16px,1.2vw,18px);line-height:1.6;color:rgba(254,252,247,.8)}
.cta>p a{color:var(--kulta);text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:3px}
.cta>p a:hover{color:var(--paperi)}

/* ---------- Megamenu sivupuusta (päätös 7, 26.11.) ----------
   Palveluvälilehdellä: vasemmalla intro + referenssikortti, oikealla toisen tason sivut ryhmäotsikoina
   ja niiden alasivut linkkeinä (alin taso jätetään pois 27.11.). Mobiilissa ryhmät ovat haitareita. */
html body .nav-tab.digi{--tab-acc:#e8785a}
html body .nav-tab.web{--tab-acc:var(--turkoosi)}
/* Brändi ja viestintä: kolmas palvelualue omalla kultaisella värillä (27.11.) */
html body .nav-tab.brandi{--tab-acc:var(--kulta)}
.nav-col.brandi h3{display:inline-flex;margin-bottom:18px;padding:6px 12px 5px 10px;border-radius:999px;background:var(--kulta);color:var(--hiili)}
.nav-col.brandi{--nav-acc:var(--kulta)}
@media (max-width:1099px){html body .mm.brandi .mm-head .lbl i{background:var(--kulta)}html body .mm.yritys .mm-head .lbl i{background:var(--paperi)}}
/* Yksitasoinen alue: sivut suoraan linkkeinä, työpöydällä kahdessa sarakkeessa */
@media (min-width:1100px){html body .mm-g.flat ul{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:clamp(18px,2vw,34px)}html body .mm .mm-grp .mm-g.flat li a{padding-top:8px}}
html body .nav-tab.is-cur{color:var(--paperi)}
.mm-gh{display:block;margin:0 0 4px;padding:0 0 10px;border-bottom:1px solid rgba(254,252,247,.14);font-size:12.5px;font-weight:600;letter-spacing:.16em;text-transform:uppercase;line-height:1.35;color:var(--paperi);text-decoration:none;transition:color .4s ease} /* 3.12. (Markus): no family colours on the group links (were rust / turquoise / gold) */
.mm-gh:hover,.mm-gh:focus-visible,.mm-gh[aria-current]{color:var(--nav-acc,var(--kulta))} /* 3.12. (Markus): hover in the colour of the service area, not gold */
html body .mm .mm-grp li a{font-size:15.5px;padding:8px 0;line-height:1.3}
html body .mm .mm-grp li:first-child a{padding-top:8px}
html body .mm .nav-col li a[aria-current]{color:var(--paperi)}
.mm-g ul{margin:0}
html body .mm-groups .mm-intro .mm-side{margin-top:18px}
@media (min-width:1100px){
  html body .mm.mm-groups{grid-template-columns:minmax(220px,.8fr) minmax(0,3fr)}
  html body .mm-grp{display:grid;grid-template-columns:repeat(var(--cols,4),minmax(0,1fr));gap:clamp(18px,2vw,34px);align-content:start}
  html body .mm-groups .mm-intro .big{font-size:clamp(21px,1.7vw,26px)}
  html body .mm-groups .mm-card figure{aspect-ratio:16/9}
  html body .mm-groups .mm-card b{font-size:15px}
  html body .nav-panel>div{max-height:calc(100dvh - 100px);overflow:auto}
}
html body .mm-gt,html body .mm .mm-grp li.mm-gall{display:none}
@media (max-width:1099px){
  html body .mm-grp .mm-g{padding-top:0}
  html body .mm-grp .mm-g:has(.mm-gt) .mm-gh{display:none}
  html body .mm-gt{all:unset;box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;gap:14px;width:100%;min-height:52px;border-bottom:1px solid rgba(254,252,247,.14);font-size:12.5px;font-weight:600;letter-spacing:.16em;text-transform:uppercase;line-height:1.35;color:var(--paperi);cursor:pointer;-webkit-tap-highlight-color:transparent}
  html body .mm-gt:focus-visible{outline:2px solid var(--kulta);outline-offset:2px;border-radius:6px}
  html body .mm-gt .chev{flex:none;width:7px;height:7px;margin-right:6px;border-right:1.6px solid currentColor;border-bottom:1.6px solid currentColor;rotate:45deg;translate:0 -2px;opacity:.8;transition:rotate .5s var(--ease),translate .5s var(--ease)}
  html body .mm-g.exp .mm-gt .chev{rotate:225deg;translate:0 2px}
  html body .mm-g:has(.mm-gt):not(.exp)>ul{display:none}
  html body .mm-g.exp>ul{padding:4px 0 10px}
  html body .mm .mm-grp li.mm-gall{display:list-item}
  html body .mm .mm-grp li.mm-gall a{color:var(--paperi)}
}

/* Valikon tekstit isommiksi (Markus 27.11.: "aika pientä") */
html body .nav-tab{font-size:16px}
html body .nav .nav-col h3{font-size:13.5px}
html body .nav .mm-gh,html body .nav .mm-gt{font-size:13.5px}
html body .nav .mm .mm-grp li a{font-size:17.5px;padding:9px 0}
html body .nav .mm-all,html body .nav .mm-ref{display:block;font-size:16.5px;line-height:1.4}
html body .nav .mm-all .arr,html body .nav .mm-ref .arr{display:inline-block;margin-left:6px}
html body .nav .mm-all,html body .nav .mm-ref,html body .nav .mm-card b{text-wrap:balance}
html body .nav .mm-card small{font-size:12.5px}
html body .nav .mm-card b,html body .nav .mm-groups .mm-card b{font-size:17px}
html body .nav .nav-offer b{font-size:16.5px}
html body .nav .nav-offer small{font-size:14px}
/* Yritys-välilehti samaan kokoon kuin palveluiden linkit (vedoksen 19–22 px oli selvästi isompi) */
@media (min-width:1100px){html body .nav .mm.yritys .nav-col li a{font-size:17.5px;padding:10px 0}html body .nav .mm.yritys .nav-col li:first-child a{padding-top:10px}}
@media (max-width:1099px){
  html body .nav .mm-head{font-size:20px}
  html body .nav .mm-intro .big{font-size:18.5px}
  html body .nav .mm .nav-col li a{font-size:18px}
  html body .nav .mm .mm-grp li a{padding:11px 0}
}

/* ---------- Sisältö Gutenbergistä (artikkelit, perussivut) ---------- */
.ld-prose{max-width:72ch}
.ld-prose>*{margin-block:0 1em}
.ld-prose h2{font-size:clamp(28px,3vw,42px);line-height:1.08;letter-spacing:-.025em;margin-top:1.6em}
.ld-prose h3{font-size:clamp(21px,1.8vw,26px);line-height:1.2;margin-top:1.4em}
.ld-prose a{color:var(--kulta);text-underline-offset:3px}
.ld-prose a:hover{color:var(--paperi)}
.ld-prose img{height:auto;border-radius:16px 16px 16px 0}
.ld-prose blockquote{margin:1.4em 0;padding:0 0 0 22px;border-left:2px solid var(--kulta);font-size:1.15em}
.ld-prose ul,.ld-prose ol{padding-left:1.3em}
.ld-prose li{margin:.3em 0}
.ld-prose table{width:100%;border-collapse:collapse}
.ld-prose th,.ld-prose td{border-bottom:1px solid rgba(254,252,247,.14);padding:10px 8px;text-align:left}

/* ---------- Perussivun hero ja sisältö ---------- */
.ld-hero{padding-bottom:clamp(40px,5vw,72px)}
.ld-hero-in{container-type:inline-size;max-width:1100px}
.ld-hero h1{margin:16px 0 0;font-size:clamp(44px,7vw,100px);line-height:.98;letter-spacing:-.035em;overflow-wrap:normal;hyphens:manual;text-wrap:balance}
.ld-lead{margin:26px 0 0;max-width:54ch;font-size:clamp(18px,1.4vw,21px);line-height:1.5;color:var(--paperi)}
.ld-body{padding:0 0 clamp(80px,9vw,140px)}

/* ---------- Palvelusivun lohkot: WordPress-lisäykset ---------- */
[id^="ps-"],#paketit,#kanavat{scroll-margin-top:110px}
.ps-refsec{padding-bottom:clamp(54px,6.5vw,104px)}
.ps-top{max-width:calc(var(--max));display:grid;gap:22px}
.ps-top .ps-txt{max-width:50ch}
.ps-txt>*:first-child{margin-top:0}
.ps-hero .kupla.ps-kupla{justify-self:end}
.ps-hero .kupla.ps-kupla img{object-position:50% 30%}

/* Palvelualueen kokoomasivu: ryhmät kortteina (ei vedosta; samat osat kuin palvelusivulla) */
.ar-head{display:grid;grid-template-columns:minmax(0,.82fr) minmax(0,1fr);gap:clamp(24px,5vw,90px);align-items:end;margin-bottom:clamp(28px,3vw,44px)}
.ar-head h2{margin:0}
.ar-intro{margin:0;max-width:50ch;color:rgba(254,252,247,.78)}
.ar-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:clamp(14px,1.6vw,22px)}
.ar-card{--acc:var(--kulta);display:flex;flex-direction:column;gap:14px;padding:clamp(22px,2.4vw,34px);border-radius:22px 22px 22px 0;border:1px solid var(--line);background:rgba(10,44,42,.45);transition:border-color .6s ease,background-color .6s ease}
.ar-card.digi{--acc:#e8785a}.ar-card.web{--acc:var(--turkoosi)}.ar-card.brandi{--acc:var(--kulta)}
.ar-card:hover{border-color:rgba(216,165,85,.5)}
.ar-card h3{margin:0;font-size:clamp(24px,2vw,30px);line-height:1.12;letter-spacing:-.02em}
.ar-card h3 a{text-decoration:none;color:var(--paperi)}
.ar-card h3 .arr{display:inline-block;color:var(--acc);transition:translate .6s cubic-bezier(.22,.61,.36,1)}
.ar-card h3 a:hover .arr,.ar-card h3 a:focus-visible .arr{translate:4px 0}
.ar-card p{margin:0;color:rgba(254,252,247,.75);font-size:16px}
.ar-card ul{list-style:none;margin:0;padding:0}
.ar-card li a{display:block;padding:9px 0;border-top:1px solid rgba(254,252,247,.09);font-size:15.5px;color:rgba(254,252,247,.85);text-decoration:none}
.ar-card li a:hover,.ar-card li a:focus-visible{color:var(--acc)}
@media (max-width:900px){.ar-head{grid-template-columns:1fr}}

/* ---------- Blogi ---------- */
.post-grid{padding-bottom:0}
.post-card .rc-body h2,.post-card .rc-body h3{margin-bottom:0}
.post-ex{margin:12px 0 0;font-size:15px;line-height:1.5;color:rgba(254,252,247,.72)}
.ld-pager{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:14px;margin-top:clamp(40px,5vw,70px)}
.ld-pager ul{display:flex;gap:6px;list-style:none;margin:0;padding:0}
.ld-pager li a,.ld-pager li span{display:grid;place-items:center;min-width:44px;height:44px;padding:0 10px;border-radius:999px;border:1px solid rgba(254,252,247,.2);text-decoration:none;font-weight:600}
.ld-pager li a:hover{border-color:var(--kulta)}
.ld-pager li span[aria-current]{background:var(--kulta);border-color:var(--kulta);color:var(--hiili)}
.ld-pager li span.gap{min-width:20px;padding:0;border:0;font-weight:400;color:rgba(254,252,247,.6)}
.ld-post-g{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,.7fr);gap:clamp(30px,5vw,90px);align-items:center}
.ld-post-g .kupla{width:100%;max-width:420px;justify-self:end}
.ld-post-hero h1{font-size:clamp(38px,5.2vw,76px)}
.ld-meta{margin:22px 0 0;font-size:14px;font-weight:600;letter-spacing:.14em;text-transform:uppercase;color:var(--kulta)}
.ld-article{margin-inline:auto;font-size:18px;line-height:1.65}
.ld-article>p:first-child{font-size:clamp(19px,1.5vw,22px);line-height:1.5}
.ld-article figure{margin:1.6em 0}
.ld-article figure img{width:100%}
/* 3.12.: a run of photos in an article (blog import: .ld-fig-grid) as two columns instead of six tall pictures in a row */
.ld-article .ld-fig-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:1.6em 0}
.ld-article .ld-fig-grid figure{margin:0}
.ld-article .ld-fig-grid img{display:block;width:100%;height:100%;aspect-ratio:3/2;object-fit:cover}
@media (max-width:640px){.ld-article .ld-fig-grid{grid-template-columns:1fr}}
.ld-article iframe{width:100%;aspect-ratio:16/9;border:0;border-radius:16px 16px 16px 0}
@media (max-width:900px){.ld-post-g{grid-template-columns:1fr}.ld-post-g .kupla{max-width:min(70vw,300px);justify-self:start}}

/* 30.11.: versaalipillereiden teksti pystysuunnassa keskelle fontin mittasuhteista riippumatta. Tekstilaatikko rajataan
   isojen kirjainten korkeuteen (text-box), jolloin flex-keskitys keskittää näkyvät kirjaimet. Ilman tukea ennallaan. */
/* 2.12.: sama yläpalkin Ota yhteyttä -napille, kielivalinnalle ja historiikin vuosinapeille. Syy: tekstin paikka
   napissa riippuu fontista (Neue Kabel paikallisesti asennettuna, muuten Jost), joten keskitys tehdään kirjainten
   korkeuden mukaan eikä rivilaatikon. */
/* 2.12. (2): sama kaikille sivuston napeille; kit.js (capText) käärii napin tekstin .t-elementtiin. */
html body :is(.fam,.rk-fam,.sv-pill,.nav-col h3,.nav-cta,.nav-lang a,.tlb-years button,.b,.vk-btn,.chip,.ps-add,.ct-copy,.rd-mock-pause,.mm-cta,.ps-toc a)>.t{display:block}
html body .menu-btn>#menuLbl{display:block}
/* 2.12.: the hero's outline button now has an arrow; the unrelated ".g span" rule must not push it down. */
html body .vk-btn>.arr{display:inline-block;margin:0;color:inherit}
/* The wrapped label must look exactly like the bare text did: component rules for "span" must not reach it. */
html body :is(.b,.vk-btn,.chip,.ps-add,.ct-copy,.rd-mock-pause,.mm-cta,.ps-toc a,.nav-cta,.tlb-years button)>.t{margin:0;padding:0;font:inherit;letter-spacing:inherit;text-transform:inherit;color:inherit;opacity:1;background:none;border:0;transform:none;translate:none}
@supports (text-box:trim-both cap alphabetic){
  html body :is(.fam,.rk-fam,.sv-pill,.nav-col h3,.nav-cta,.nav-lang a,.tlb-years button,.b,.vk-btn,.chip,.ps-add,.ct-copy,.rd-mock-pause,.mm-cta,.ps-toc a)>.t,html body .menu-btn>#menuLbl{text-box:trim-both cap alphabetic}
  html body .nav-lang a{padding-top:0}
  html body .nav-col:is(.digi,.web,.brandi,.brand) h3,html body .nav-col.yritys h3:has([data-mark]){height:33px;padding-block:0;box-sizing:border-box}
  html body .sv-pill{min-height:34px;padding-block:0}
}

/* 30.11.: Louhos-merkki hero-kuvakuplan takana alasivuilla (partials/kupla-mark.twig), kuten etusivun herossa:
   sävy sävyyn, keskitetty kuplan kanssa, n. 1,25 × kuvan leveys. Kupla sisennetään, jotta merkki mahtuu kokonaisena. */
.kupla.has-mt{--mt:.125}
.kupla-mt{position:absolute;inset:calc(var(--mt) * -100%);z-index:-1;pointer-events:none}
.kupla-mt svg{display:block;width:100%;height:100%}
.kupla.has-mt img{z-index:0}
/* Room for the mark that reaches past the image (--mt × image size), so the line and text below keep their distance */
.ps-hero .kupla.has-mt,.ld-post-g .kupla.has-mt{--kw:470px;margin-block:calc(var(--mt) * min(100%, var(--kw)))}
.rd-hero .kupla.has-mt{--kw:480px;margin-block:calc(var(--mt) * min(100%, var(--kw)))}
.ld-post-g .kupla.has-mt{--kw:420px}
@media (max-width:900px){.ps-hero .kupla.has-mt{--kw:min(64vw,260px)}.ld-post-g .kupla.has-mt{--kw:min(70vw,300px)}.rd-hero .kupla.has-mt{--kw:380px}}
.ld-post-hero .crumb,.page-top:has(.rd-hero) .crumb{margin-bottom:clamp(18px,1.8vw,28px)}

/* 30.11.: footer tiiviimmäksi ja viiteen sarakkeeseen (logo | digi + web | brändi | työkalut + Louhos | yhteystiedot +
   toimipisteet), jotta se mahtuu tavalliselle näytölle ja paljastuu sisällön alta (site.js). */
html body footer.site-foot{padding-top:64px}
html body .foot .foot-offices{margin-top:22px}
html body .foot address{font-size:14.5px;line-height:1.45}
html body .foot .kv{margin-bottom:8px}
html body .foot li{margin:3px 0}
html body .nl{padding:24px 0;margin-top:8px}
html body .legal{padding:18px 0}
@media (min-width:1101px){html body .foot{grid-template-columns:1.15fr 1fr 1fr 1.05fr 1.05fr;gap:32px 28px}}
@media (max-width:1100px) and (min-width:901px){html body .foot{grid-template-columns:repeat(3,1fr)}}
html body .foot .foot-offices{margin-top:26px}
html body .foot address+address{margin-top:10px}
html body .foot-vintage{--fw:clamp(160px,13vw,190px)}
/* 30.11.: the gold continuation of the CTA heading always starts its own line, so the colour change
   follows the line break instead of landing mid-line ("Seuraava tarina / voi olla teidän"). */
.cta h2 .cta-hl{display:block}
/* 30.11.: related cases right after the CTA section: no doubled padding (was 140 + 115 px) */
.cta-sec+.related{padding-top:0}
/* 30.11.: reference family tiles: more room for the label ("Digimarkkinointi" touched the tile edge) */
@media (min-width:1101px){.rl-hero{grid-template-columns:minmax(0,1.1fr) minmax(0,1fr)}}
.fam-tile{padding:20px 20px 18px}
.fam-tile b{font-size:clamp(15px,1.2vw,18px)}

/* 1.12.: arrows inside round buttons are drawn, not typed. The "→" glyph sits above the centre of its line box, so it
   never landed in the middle of the circle. The glyph stays in the markup (hidden with font-size 0), the arrow is a
   mask in currentColor, so hover colours and rotations keep working. */
html body .sv-area .go,html body .ex-go,html body .rk-go,html body .rk-arr,html body .arrows button,html body .rc-go{align-content:center;padding:0;font-size:0;line-height:0;-webkit-text-stroke:0}
html body .sv-area .go::before,html body .ex-go::before,html body .rk-go::before,html body .rk-arr::before,html body .arrows button::before,html body .rc-go::before{content:"";width:18px;height:18px;background:currentColor;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12h15M13.5 6l6 6-6 6'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12h15M13.5 6l6 6-6 6'/%3E%3C/svg%3E") center/contain no-repeat}
html body #rkPrev::before,html body #prev::before{scale:-1 1}
html body .rk-arr{display:grid;place-items:center}

/* 2.12. Kieliversiot yläpalkissa: FI / EN / SV. Leveällä näytöllä lyhenteet ennen Ota yhteyttä -painiketta,
   kapealla täydet nimet valikon lopussa. */
.nav-lang{display:flex;align-items:center;gap:2px}
/* Optical centring: caps sit above the line box centre and letter-spacing trails the last glyph. */
.nav-lang a{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:34px;height:30px;padding:2px 8px 0 calc(8px + .12em);border-radius:999px;font-size:12px;font-weight:600;letter-spacing:.12em;color:rgba(254,252,247,.72);text-decoration:none;transition:color .3s ease,background-color .3s ease}
.nav-lang a:hover,.nav-lang a:focus-visible{color:var(--paperi);background:rgba(254,252,247,.12)}
.mm-lang{display:none}
@media (max-width:1099px){
  .nav-lang{display:none}
  .mm-lang{display:flex;flex-wrap:wrap;gap:8px 22px;justify-content:center;margin:18px 20px 0}
  .mm-lang a{display:inline-flex;align-items:center;min-height:44px;font-size:15px;font-weight:600;color:var(--paperi);text-decoration:underline;text-decoration-color:var(--kulta);text-underline-offset:4px}
}
.rf3-intro{max-width:46em;margin:-6px 0 clamp(22px,2.4vw,34px);font-size:clamp(17px,1.25vw,19px);line-height:1.6;color:rgba(254,252,247,.82)}

/* 2.12.: sivun sisäisen linkin kohde saa kohdistuksen (site.js); koko osion ympärille ei piirretä kehystä. */
main [tabindex="-1"]:focus,#sisalto[tabindex="-1"]:focus{outline:0}
/* 2.12.: footer contact links at least 24 px tall (WCAG 2.2 target size; they were 22 px and stacked) */
html body .foot .kv a{display:inline-block;padding-block:2px}
/* 3.12.: the S / M / L letter sits in the middle of its bubble with either font (same idea as the buttons above:
   the letter's box is trimmed to the capital height, then centred). Without support: plain line-height centring. */
html body :is(.hp-tier-k b,.ps-k)>.t{display:block;line-height:1}
@supports (text-box:trim-both cap alphabetic){
  html body :is(.hp-tier-k b,.ps-k)>.t{text-box:trim-both cap alphabetic}
}

/* 3.12.: an article without a picture shows the Louhos mark, tone on tone, instead of an empty tile (blog cards,
   the latest articles under a post, the front page news). Brand greens only. */
.post-ph{position:absolute;inset:0;display:grid;place-items:center;overflow:hidden;background:linear-gradient(140deg,#1b5a54,#114540);color:rgba(10,44,42,.5)}
.post-ph svg{width:44%;height:auto;transition:transform 1.1s var(--ease)}
.rc:hover .post-ph svg,.rc:focus-visible .post-ph svg,.post:hover .post-ph svg{transform:scale(1.045)}
.post .th{position:relative}
/* 3.12.: the family pill in the mega menu has a fixed height, so it must stay on one line. On 1100–1250 px screens
   "Brändi ja viestintä" wrapped and the two lines ran over the pill. The first column is now wide enough for it
   also with the wider Neue Kabel. */
html body .nav-col:is(.digi,.web,.brandi,.brand) h3,html body .nav-col.yritys h3:has([data-mark]){white-space:nowrap;max-width:none}
@media (min-width:1100px){html body .mm.mm-groups{grid-template-columns:minmax(256px,.8fr) minmax(0,3fr)}}
/* 3.12. (Markus, Arttu): the smallest texts are bigger on every screen, so that they can be read with ageing eyes too.
   Uppercase labels at least 13 px (the family pills 12.5 px, they sit in tight rows), all other small text at least
   14.5 px. Before: 10.5–13.5 px. Text inside the illustrations (mock screens) is part of the picture and keeps its size. */
html body :is(.fam,.rk-fam){font-size:12.5px}
html body :is(.rk-info small,.post .cat,.post .cat time,.feat .lbl,dl.facts dt,.start small,.metrics .mt small,.ex-h,.clients .lbl,.scan-form label,.foot h3:not(.nl *),.foot h3:not(.nl *) a,.ps-toc>span,.vk-stats span,.sv-area small,.eyebrow,.ct-k,.rc-client,.rc-client time,.feat-body .client,.rd-hero .client span,.pf .k,.sample small){font-size:13px}
html body :is(.feat-res small,.rc-num small,#fiList small,.chip small,.kivi figcaption span,.te-gauges small,.hp-sv-p small,.hp-tier-p small,.hp-sv-p i,.hp-tier-p i,.foot .kv span,.ps-seg button,.ct-lbl,.ct-dl dt,.ct-copy,.hp-bar-t span,.proof-note,.metrics-note,.ch-h small,.legal,.legal a,.legal button,.ct-priv,.ct-priv a,.hp-sv-st,.hp-tier-k,.feat blockquote cite,.rc-svc li,.chip-res span,.metrics .mt p,.tm small,.cta small){font-size:14.5px}
/* 3.12. Mega menu (feedback from Joonas, Tuukka, Esko and Petteri):
   - lighter to draw: no backdrop blur behind the open panel or on the page dimmer (a growing blurred area was repainted
     on every frame), and shorter transitions so that the panel keeps up with the pointer
   - no scrollbar while the panel is opening (site.js sets .anim for the opening)
   - the top items show a focus ring for keyboard use (they only had the same underline as the open tab) */
html body .nav.open{background:rgba(9,39,37,.985);backdrop-filter:none;-webkit-backdrop-filter:none}
html body .page-dim{backdrop-filter:none;-webkit-backdrop-filter:none;background:rgba(5,20,19,.6)}
html body .nav-panel{transition-duration:.38s}
html body .nav .js-stagger>*{transition-duration:.32s}
@media (min-width:1100px){
  html body .nav.open .mm.cur{animation-duration:.28s}
  html body .nav.anim .nav-panel>div{overflow:hidden}
}
html body .nav-tab:focus-visible,html body .nav-lang a:focus-visible{outline:2px solid var(--kulta);outline-offset:3px;border-radius:10px}
/* 3.12. (Petteri): on the narrowest phones (320–360 px) the menu button fits inside the bar */
@media (max-width:360px){
  html body .nav-bar{gap:10px;padding:0 8px 0 14px}
  html body .nav .logo{--lh:25px}
  html body .menu-btn{gap:8px;padding:0 13px}
}

/* 3.12. (Markus): 10 px more room on the right end of the header bar, so that the Ota yhteyttä / Valikko button
   sits as far from the edge as the logo does on the left (20 px; was 10). Narrow phones: 14 px on both sides. */
@media (min-width:361px){html body .nav-bar{padding-right:20px}}
@media (max-width:360px){html body .nav-bar{padding-right:14px}}

/* 3.12. (Markus): the bottom row links of the footer get the same hover as the Evästeasetukset button next to
   them (only the button turned gold). */
html body .legal :is(a,.ld-cookie-settings){transition:color .25s ease}
html body .legal a:hover{color:var(--kulta)}

/* 3.12. (Markus): "3,5 M€" in the hero figures. At the size of the number the unit read as a word of its own and
   the M and the € ran together; now it is a smaller unit after the number, like a unit after a measurement. */
html body .vk-stats b i{font-size:.56em;font-weight:600;letter-spacing:.06em}

/* 3.12. (Arttu): lightbox for the Yritys gallery and the pictures in blog articles (assets/js/site.js). */
.lb-t{cursor:zoom-in}
.lb-t:focus-visible{outline:2px solid var(--kulta);outline-offset:3px}
.lb{width:100vw;max-width:none;height:100dvh;max-height:none;margin:0;padding:0;border:0;background:rgba(5,22,21,.94);color:var(--paperi);overflow:hidden}
.lb::backdrop{background:rgba(5,22,21,.6)}
.lb-f{display:grid;place-items:center;align-content:center;gap:14px;height:100%;margin:0;padding:clamp(56px,7vh,80px) clamp(16px,6vw,96px)}
.lb-f img{display:block;max-width:100%;max-height:calc(100dvh - 2 * clamp(56px,7vh,80px) - 44px);width:auto;height:auto;border-radius:14px 14px 14px 0;box-shadow:0 30px 60px -30px rgba(0,0,0,.7)}
.lb-c{max-width:70ch;font-size:15px;line-height:1.45;text-align:center;color:rgba(254,252,247,.8)}
.lb-x,.lb-p,.lb-n{position:absolute;display:grid;place-items:center;width:48px;height:48px;padding:0;border:1px solid rgba(254,252,247,.28);border-radius:50%;background:rgba(10,44,42,.7);color:var(--paperi);font:inherit;font-size:22px;line-height:1;cursor:pointer;transition:background .25s,border-color .25s,color .25s}
.lb-x:hover,.lb-p:hover,.lb-n:hover{background:var(--kulta);border-color:var(--kulta);color:var(--hiili)}
.lb-x:focus-visible,.lb-p:focus-visible,.lb-n:focus-visible{outline:2px solid var(--kulta);outline-offset:3px}
.lb-x{top:max(14px,env(safe-area-inset-top));right:14px;font-size:28px}
.lb-p,.lb-n{top:50%;translate:0 -50%}
.lb-p{left:14px}.lb-n{right:14px}
.lb.one :is(.lb-p,.lb-n){display:none}
.lb-i{position:absolute;left:50%;bottom:max(16px,env(safe-area-inset-bottom));translate:-50% 0;margin:0;font-size:13px;letter-spacing:.14em;color:rgba(254,252,247,.7)}
@media (max-width:700px){.lb-p,.lb-n{top:auto;bottom:max(8px,env(safe-area-inset-bottom));translate:none}.lb-f{padding-inline:12px}}

/* 3.12. (Arttu): Yritys gallery on phones had pictures side by side at different heights (the column layout
   continues a column wherever the previous one ends). Now a grid: pictures in rows, same order as read. All
   pictures are landscape, so nothing changes on wide screens except that the rows line up. */
html body .ga-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:clamp(14px,1.6vw,22px);columns:auto}
html body .ga-grid li{margin:0}
html body .ga-grid img{aspect-ratio:3/2;height:auto;object-fit:cover}
@media (max-width:900px){html body .ga-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:600px){html body .ga-grid{gap:10px}}

/* 3.12. (Aarne): blog pictures were cut at the sides (many old blog pictures carry text). Cards use the
   pictures' own shape (most are about 16:10, was 4:3), and the article page shows the whole picture in a
   rounded frame instead of the round bubble. */
html body .post-card .rc-img{aspect-ratio:16/10}
.ld-post-g .kupla.ld-post-img{aspect-ratio:auto;max-width:540px;border-radius:26px 26px 26px 0}
.ld-post-g .kupla.ld-post-img img{position:relative;inset:auto;height:auto;object-fit:contain}
.ld-post-g .kupla.ld-post-img::before{display:none}
@media (max-width:900px){.ld-post-g .kupla.ld-post-img{max-width:min(100%,520px)}}
html body .post .th{aspect-ratio:16/10}

/* 3.12. (Markus): headings one step heavier now that Neue Kabel comes from the Adobe Fonts kit for everyone
   (500 → 600). :not(#_) only lifts the specificity above the older per-section weight rules (some use ids).
   Figures and card numbers stay at 500. */
html body :is(h1,h2,h3,h4):not(#_){font-weight:600}

/* 3.12. Newsletter (footer) and free audit forms connected to Louhos's data bank (assets/js/lomakkeet.js).
   The consent and privacy texts come from the API as they are; here only their look. */
html body .nl-forms{min-width:0}
html body .nl form.nl-form{display:block}
html body .nl .nl-row{display:flex;gap:8px;flex-wrap:wrap}
html body .nl .nl-row input{flex:1 1 220px}
html body .nl :is(.lu-teksti,.lu-lisatiedot,.lu-testi){margin:10px 0 0;font-size:14.5px;line-height:1.5;color:rgba(254,252,247,.62)}
html body .nl .lu-lisatiedot{margin-top:6px}
html body .nl :is(.lu-lisatiedot a,.louhos-uutiskirje-vara a){color:var(--paperi);text-decoration:underline;text-decoration-color:var(--kulta);text-underline-offset:3px}
html body .nl .lu-viesti{margin:8px 0 0;font-size:15px;color:var(--kulta)}
html body .nl .lu-viesti:empty{display:none}
html body .nl .louhos-uutiskirje-vara{margin:0;font-size:16px}
html body .scan-privacy{margin:10px 0 0;font-size:14.5px;line-height:1.5;color:rgba(254,252,247,.6)}
html body .scan-privacy a{color:var(--paperi);text-decoration:underline;text-decoration-color:var(--kulta);text-underline-offset:3px}

/* 3.12. (Petteri): the typed site's favicon on the mock browser tab of the free audit (assets/js/front.js). */
html body .mock .bar .tab{display:inline-flex;align-items:center;gap:7px;min-width:0}
html body .mock .bar .tab b{font-weight:inherit;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html body .mock .bar .fav{flex:none;width:14px;height:14px;border-radius:3px;object-fit:contain}

/* 3.12. (Arttu, Bänksy): quote basket shortcut, bottom right on the other pages when the basket has services. */
.cart-fab{position:fixed;right:max(16px,env(safe-area-inset-right));bottom:max(16px,env(safe-area-inset-bottom));z-index:60;display:inline-flex;align-items:center;gap:10px;height:52px;padding:0 10px 0 18px;border-radius:999px;background:var(--kulta);color:var(--hiili);font-weight:600;font-size:16px;text-decoration:none;box-shadow:0 18px 40px -16px rgba(2,14,13,.7);transition:transform .25s ease,background .25s ease}
.cart-fab:hover{background:var(--paperi)}
.cart-fab:focus-visible{outline:2px solid var(--paperi);outline-offset:3px}
.cart-fab-ic{width:18px;height:18px;background:currentColor;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 5h2l2.2 10.2a1 1 0 0 0 1 .8h8.7a1 1 0 0 0 1-.8L20 8H6.2'/%3E%3Ccircle cx='9' cy='20' r='1.4'/%3E%3Ccircle cx='17' cy='20' r='1.4'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 5h2l2.2 10.2a1 1 0 0 0 1 .8h8.7a1 1 0 0 0 1-.8L20 8H6.2'/%3E%3Ccircle cx='9' cy='20' r='1.4'/%3E%3Ccircle cx='17' cy='20' r='1.4'/%3E%3C/svg%3E") center/contain no-repeat}
.cart-fab-n{display:grid;place-items:center;min-width:32px;height:32px;padding:0 8px;border-radius:999px;background:var(--hiili);color:var(--paperi);font-size:14px;font-variant-numeric:tabular-nums}
@media (prefers-reduced-motion:no-preference){.cart-fab:not([hidden]){animation:cartIn .4s cubic-bezier(.22,.61,.36,1)}@keyframes cartIn{from{transform:translateY(20px);opacity:0}}}

/* 3.12. The article picture is now in its own shape (not the round bubble), so the Louhos mark behind it was
   stretched to the picture's rectangle and showed only as stray pieces above and below. The mark stays square,
   centred on the picture and sized from the picture's width, like the mark behind the round bubbles. */
.ld-post-g .kupla.ld-post-img .kupla-mt{inset:auto;left:50%;top:50%;width:100%;aspect-ratio:1;translate:-50% -50%}
/* Room above and below for the mark, so it does not run under the title or the first paragraph. */
.ld-post-g .kupla.ld-post-img.has-mt{margin-block:clamp(36px,13%,110px)}
/* 3.12. (Markus): the mark shows more from behind the picture: larger than the picture and nudged up-right. */
.ld-post-g .kupla.ld-post-img .kupla-mt{width:132%;translate:-44% -54%}
.ld-post-g .kupla.ld-post-img.has-mt{margin-block:clamp(56px,22%,170px)}
/* Phones: the picture is a bit narrower so the larger mark still fits on the screen (no sideways scrolling). */
@media (max-width:900px){.ld-post-g .kupla.ld-post-img{max-width:min(84%,480px);margin-inline:auto}.ld-post-g .kupla.ld-post-img .kupla-mt{width:118%;translate:-48% -52%}}

/* 3.12. (Markus): the text beside the map was as tall as the map. Lighter list so the map stays the taller one:
   the two offices as rows with their address, the four team towns two by two without the repeated "Tiimiläisiä"
   (the paragraph above already says it; it stays for screen readers). Wide screens only. */
@media (min-width:901px){
  html body .map-sec .cities ul{display:grid;grid-template-columns:1fr 1fr;column-gap:24px}
  html body .map-sec .cities li:nth-child(-n+3){grid-column:1/-1}
  html body .map-sec .cities button{padding:10px 0}
  html body .map-sec .cities li:nth-child(-n+2) b{font-size:clamp(20px,1.6vw,24px)}
  html body .map-sec .cities .team b{font-size:clamp(17px,1.3vw,19px)}
  html body .map-sec .cities .team small{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
  html body .map-sec .cities li:nth-last-child(2) button{border-bottom:1px solid rgba(254,252,247,.14)}
  html body .map-sec .cities>p{margin-bottom:16px}
}

/* 3.12. (Markus): the four team towns under one label "Tiimiläisiä" (a list item without data-city; fi-map.js reads
   only li[data-city]). The label is hidden from screen readers, which still hear "Tiimiläisiä" after each town. */
html body .map-sec .cities .team-h{grid-column:1/-1;margin:22px 0 2px;font-size:13px;font-weight:600;letter-spacing:.16em;text-transform:uppercase;color:rgba(254,252,247,.62)}
html body .map-sec .cities .team small{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}

/* 3.12. (Markus, Valtteri P.: "pääotsikko laatikoituna"): mega menu easier to read without new colours. The group
   heading (Verkkosivut yritykselle, Verkkokaupat…) is a box of its own with the stone corner, in sentence case with
   an arrow (the heading links to the group's overview page); the links under it are a step dimmer. Wide screens
   only; on narrow screens the groups are an accordion and stay as they are. */
@media (min-width:1100px){
  html body .nav .mm .mm-grp .mm-gh{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 8px;padding:13px 16px 13px 18px;border:1px solid rgba(254,252,247,.14);border-radius:16px 16px 16px 0;background:rgba(254,252,247,.07);font-size:19px;font-weight:600;letter-spacing:-.01em;text-transform:none;line-height:1.25;transition:background .3s,border-color .3s,color .3s}
  html body .nav .mm .mm-grp .mm-gh::after{content:"→";font-size:.9em;opacity:.55;transition:translate .3s var(--ease),opacity .3s}
  html body .nav .mm .mm-grp .mm-gh:is(:hover,:focus-visible){background:rgba(254,252,247,.11);border-color:rgba(254,252,247,.24)}
  html body .nav .mm .mm-grp .mm-gh:is(:hover,:focus-visible)::after{opacity:1;translate:4px 0}
  html body .nav .mm .mm-grp .mm-g:not(.flat) li a{color:rgba(254,252,247,.76);font-size:16.5px;padding-inline:4px}
  html body .nav .mm .mm-grp .mm-g:not(.flat) li a:is(:hover,:focus-visible),html body .nav .mm .mm-grp .mm-g:not(.flat) li a[aria-current]{color:var(--nav-acc,var(--paperi))}
}
@media (min-width:1100px) and (max-width:1339px){html body .nav .mm .mm-grp .mm-gh{font-size:16px;padding:11px 12px 11px 14px;gap:6px}}

/* 3.12. (Valtteri P.): on screens over 1300 px the header (and the mega menu inside it) is a little wider than the
   page content, which lifts it out, and the menu gets more air between the intro column and the groups. */
@media (min-width:1300px){
  html body .nav{width:min(calc(100% - 48px),1448px)}
  html body .nav .mm.mm-groups{column-gap:clamp(48px,4.6vw,88px)}
}

/* 3.12. (Markus): with the wider header the page content and the footer are widened too, so that they start at the
   left edge of the header logo and end at the right edge of the Ota yhteyttä button (header 24 px from the screen
   edge + 1 px border + 20 px bar padding = 45 px; widest header 1448 px - 42 px = 1406 px of content). The header
   stays a little wider than the content. Screens over 1300 px only. */
@media (min-width:1300px){html:root{--gut:45px;--max:1496px}}
@media (min-width:901px){html body .nl{align-items:start}}

/* 3.12. ilta (Markus): service cards' arrow wrapped alone onto the next line. The arrow is now a round button in the
   card's bottom right corner and the whole card is clickable (the sub-page links stay clickable above it). Elsewhere the
   arrow after a link text is tied to the last word with a no-break space (views). */
.ar-card{position:relative;padding-bottom:calc(clamp(22px,2.4vw,34px) + 52px)}
.ar-card h3{font-size:clamp(21px,1.7vw,28px);hyphens:manual}
.ar-card h3 a::after{content:"";position:absolute;inset:0;border-radius:inherit}
.ar-card h3 .arr{position:absolute;bottom:clamp(16px,1.8vw,24px);right:clamp(16px,1.8vw,24px);display:grid;place-items:center;width:40px;height:40px;border-radius:50%;border:1px solid rgba(254,252,247,.18);font-size:18px;line-height:1;transition:background-color .3s ease,color .3s ease,border-color .3s ease}
.ar-card:hover h3 .arr,.ar-card h3 a:focus-visible .arr{translate:none;background:var(--acc);border-color:var(--acc);color:var(--hiili)}
.ar-card ul,.ar-card p{position:relative;z-index:1}
.ar-card p{pointer-events:none}

/* ====== 3.12. ilta: koko sivuston UI-läpikäynti (työpöytä 1440 ja mobiili 390) ====== */
@media (max-width:900px){
  /* Hero and section photos were pushed right or small and left-aligned on phones: centred and the same size. */
  .ps-hero .kupla.ps-kupla{justify-self:center;max-width:min(80vw,320px)}
  .ps-hero .kupla.has-mt{--kw:min(80vw,320px)}
  html body .ps-2 .kupla{justify-self:center;max-width:min(80vw,320px)}
  .rd-hero .kupla.has-mt{justify-self:center;max-width:min(86vw,340px);--kw:min(86vw,340px)}
  /* Closing call to action: the heading used the full card width only on wide screens. */
  html body .cta h2{max-width:none}
  /* Year chips scroll under the arrows: fade them out at the edge instead of cutting a number in half. */
  .tlb-years{-webkit-mask-image:linear-gradient(90deg,#000 calc(100% - 34px),transparent);mask-image:linear-gradient(90deg,#000 calc(100% - 34px),transparent)}
  /* Two-column photo gallery: an odd last photo spans the row instead of standing alone. */
  html body .ga-grid>:last-child:nth-child(odd){grid-column:1/-1}
  /* Card buttons that wrap stay centred and full width. */
  .ps-ch .b{width:100%;justify-content:center;text-align:center}
}
/* "Kaikki referenssit →" next to a heading: one line; on phones under the heading. */
.related-h a{white-space:nowrap}
@media (max-width:600px){.related-h{flex-direction:column;align-items:flex-start;gap:12px}}
/* Reference card service list: the dot goes after an item, so a wrapped line never starts with "·". */
.rc-svc li+li::before{content:none}
.rc-svc li:not(:last-child)::after{content:"";width:3px;height:3px;border-radius:50%;background:rgba(254,252,247,.4);margin-left:7px}
/* Big figures never break between the number and its unit ("469 %"). */
:is(.rc-num,.feat,.rd-hero,.ps-ref-n,.vk-stats) b{white-space:nowrap}
/* Service area grid: six cards in two rows of three (not 4 + 2). */
@media (min-width:1101px){.ar-grid:has(>.ar-card:nth-child(6)):not(:has(>.ar-card:nth-child(7))){grid-template-columns:repeat(3,minmax(0,1fr))}}
/* The result chip on a reference hero kept a gutter-less edge on phones: it now sits inside the picture's edge. */
@media (max-width:900px){html body .rd-hero .chip-res{right:0;bottom:-3%}}

/* 4.12. (tuki): megavalikon linkkien hover kultainen kaikilla palvelualueilla (ei Digimarkkinoinnin ruoste- eikä
   Verkkopalveluiden turkoosia). Vain hover/fokus – alueen merkki, Kaikki-linkit ja välilehti pysyvät alueen värisinä.
   Kumoaa r. 29:n "hover in the colour of the service area" hover-osalta. */
html body .nav-col :is(a.big,li a):is(:hover,:focus-visible){color:var(--kulta)}
html body .nav-col li a .arr{color:var(--kulta)}
html body .mm-gh:is(:hover,:focus-visible){color:var(--kulta)}
html body .nav .mm .mm-grp .mm-g:not(.flat) li a:is(:hover,:focus-visible){color:var(--kulta)}
/* 4.12. (tuki): ryhmäotsikkolaatikon tausta ei vaalene hoverissa – kultainen teksti erottuu paremmin tummalla pohjalla
   (taustan arvo sama kuin levossa, r. 399). Reunan vaalennus ja nuolen liike jäävät hover-vihjeeksi. */
@media (min-width:1100px){html body .nav .mm .mm-grp .mm-gh:is(:hover,:focus-visible){background:rgba(254,252,247,.07)}}
