/* design-fix 19.11.2026 (reports/design-audit-2026-11-19.md). Injected last by src/middleware.ts on every page. Bump the file name on change (/dt-* is cached immutable). */

/* P0-1 home: decorative grid (inset:-40px) pushed the page to 410px on phones */
.s26-stage{overflow:clip}
@media (max-width:900px){.s26-stage .s26-grid{inset:0}}

/* P0-2/3 phones: chat + accessibility buttons sat on top of the bottom bar (phone link hidden, CTA covered).
   Lift them above the bar while it is shown (the bar hides itself while the cookie bar is open). */
@media (max-width:900px){
  html body:not(:has(#cb:not([hidden]))):has(.mbar) .dtc-launch,
  html body:not(:has(#cb:not([hidden]))):has(.mbar) .a11y-btn{bottom:84px!important}
  html body:not(:has(#cb:not([hidden]))):has(.mbar) .dtc-teaser{bottom:150px!important}
  html body:not(:has(#cb:not([hidden]))):has(.mbar) .a11y-panel{bottom:132px!important}
}

/* P1-4 service heroes: opening answer was cut with "..." on phones; show it in full */
section.hx p.lp.ans{display:block;-webkit-line-clamp:unset;line-clamp:none;overflow:visible}

/* P1-7 posts: h1 clearly above h2 on phones, no negative tracking on Hebrew headings */
h1{letter-spacing:normal!important}
@media (max-width:600px){main:has(.prose) section.hx h1{font-size:32px!important;line-height:1.2}/* !important: the post template sets font-size inline */}

/* P1-8 post tables: short Hebrew words ("ערוץ") must not break mid-word */
.tblw :is(th,td){word-break:normal;overflow-wrap:normal;hyphens:none}
.tblw tr>:first-child{min-width:4.5em}

/* P1-9 text under 12px: home hero cards and the code-built mock graphics */
.s26-card small{font-size:12px}
.gx-stage :is(small,em,b,.gx-chip,.tick){font-size:12px!important}
.gx-in text{font-size:12px}

/* range sliders (home calculator): 28px hit area, the visible track stays 8px */
html .s26-f input[type=range]{height:28px!important;border-block:10px solid transparent!important;background-clip:padding-box;border-radius:14px}

/* footer legal links: not by colour alone, 24px target */
.flegal2 a{text-decoration:underline;text-underline-offset:3px;display:inline-flex;align-items:center;min-height:24px}
@media (max-width:768px){.flegal2 a{min-height:44px}}
/* links inside sentences (consent label, phone/WhatsApp hint): 24px box without moving the line */
.consent a,.nqhint a,.nqi-trust a,aside p>a[href="/about"]{padding-block:3px}

/* P2-10 /automation: "all FAQs" button glued to the next heading */
.moreb:has(+ .h2x){margin-bottom:32px}

/* P2-15 selection in brand colours */
::selection{background:#ff7a1a;color:#002145}

/* ===== design-fix 2 (20.11.2026), reports/design-fix2-2026-11-20.md ===== */
/* 1 phones: the call/WhatsApp bar stays visible while the cookie bar is open; the cookie bar is a compact strip
   (text + one row of actions) that sits above the bar. Accept and decline have the same size and weight */
@media (max-width:640px){
  html body:has(#cb:not([hidden])) .mbar{display:flex}
  html body #cb.cb{bottom:86px!important;padding:10px 12px!important;gap:8px!important}
  #cb .cbt b{display:none}
  #cb .cbt p{font-size:13px;line-height:1.45}
  html body #cb.cb .cba{display:flex!important;flex-wrap:nowrap!important;gap:6px!important;align-items:stretch;margin:0!important}
  html body #cb.cb .cba button{flex:1 1 0!important;width:auto!important;min-width:0!important;min-height:40px;margin:0!important;white-space:nowrap;order:0!important}
  html body #cb.cb .cba button.lk{flex:0 0 auto!important;padding-inline:6px!important}
  /* floating chat/a11y buttons go above the cookie strip, so the call button in the bar stays tappable */
  html body:has(#cb:not([hidden])) :is(.a11y-btn,.dtc-launch){bottom:calc(var(--dtfb,200px) + 8px)!important}
  html body:has(#cb:not([hidden])) .dtc-teaser{display:none!important}
}
/* decline is as prominent as accept on every width (filled, same size) */
html body #cb.cb .cba button[data-a=none]{background:#fff!important;color:#002145!important;border-color:#fff!important}
/* 2 phones/tablets: the article lead-magnet slide-in stays under 25% of the screen until it is opened
   (title + CTA; the description and the form appear after the tap) and never covers the bottom bar */
@media (max-width:899px){
  html body:has(.mbar) .dtp-sl .dtpop{bottom:86px!important}
  .dtp-sl .dtpop:not(.open){grid-template-columns:56px 1fr;padding:12px 14px!important;row-gap:10px}
  .dtp-sl .dtpop:not(.open) .dtp-d{display:none}
  .dtp-sl .dtpop:not(.open) .dtp-fig{grid-row:1;margin:0}
  .dtp-sl .dtpop:not(.open) .dtp-t{font-size:16px;line-height:1.35;margin:0;padding-inline-end:40px;align-self:center}
  .dtp-sl .dtpop:not(.open) .dtp-go{min-height:44px;margin:0}
}
/* 6 kit-demo: 24px targets for links inside sentences and the consent box; orange text on white to AA (4.7:1) */
.dk-alt a,.dk-cons a{padding-block:3px}
.dk-cons input[type=checkbox]{width:24px;height:24px}
.dk-flow-lead [data-st]{color:#c25100}
/* 8 article: the TOC is now first in the DOM (keyboard order = what phones show); desktop keeps it in the side column */
@media (min-width:1000px){
  .w4-grid>nav.w4-toc{grid-column:2;grid-row:1}
  .w4-grid>.w4-col{grid-column:1;grid-row:1}
}
/* 5 topic tabs (/automation, /crm...): an intentional horizontal strip (role=tablist, scroll-snap, arrows/Home/End,
   starts at the right edge in RTL). A tab wider than the strip could never be shown whole: long labels wrap instead */
@media (max-width:640px){
  .dtx-nav>.dtx-t{max-width:100%}
  .dtx-nav>.dtx-t .dtx-l{white-space:normal;text-wrap:balance;text-align:start}
}
/* ===== design-fix 2b (20.11.2026): home hero (header.hero, z-index 90, ~800px tall) covered the call/WhatsApp bar
   on short phones and landscape. The bar sits above the hero; the mobile menu panel (also inside the hero) hides it while open */
@media (max-width:900px){
  html body .mbar{z-index:91!important}
  html body:has(details.mm[open]) .mbar{display:none!important}
}
