/* ══════════════════════════════════════════════════════════════════════
   Szlif całej strony (18.11.2026), ładowany po nav-v5.css na każdej stronie.
   Jedna paleta jak na stronie głównej v4 (neutralna, bez ciepłego papieru),
   odstępy między blokami, monochromatyczne linki, tabele na telefonie,
   listy z ikonami, ujednolicone przyciski w sekcjach końcowych.
   ══════════════════════════════════════════════════════════════════════ */

/* ── 1. paleta: neutralna szarość jak główna v4, ta sama w jasnym i ciemnym ── */
:root:root{
  --bg:#fbfbfa; --bg-2:#f3f3f2; --bg-3:#eaeae8; --surface:#ffffff; --surface-2:#f6f6f5;
  --fg:#111113; --fg-2:#46464d; --fg-3:#6e6e76;
  --line:rgba(17,17,19,.085); --line-2:rgba(17,17,19,.15);
  --accent:#111113; --accent-ink:#111113; --accent-soft:#f0f0ef; --accent-line:rgba(17,17,19,.22);
  --btn-bg:#111113; --btn-fg:#fbfbfa; --btn-hover:#2a2a2f;
  --page-bg-2:#f3f3f2; --page-surface:#ffffff; --page-surface-2:#f6f6f5;
  --page-fg:#111113; --page-fg-2:#46464d; --page-fg-3:#6e6e76; --page-line:rgba(17,17,19,.085); --page-line-2:rgba(17,17,19,.15);
}
html[data-theme="dark"]:root{
  --bg:#111113; --bg-2:#18181b; --bg-3:#222226; --surface:#18181b; --surface-2:#1e1e22;
  --fg:#f4f4f5; --fg-2:#b4b4bb; --fg-3:#8a8a92;
  --line:rgba(255,255,255,.08); --line-2:rgba(255,255,255,.14);
  --accent:#f4f4f5; --accent-ink:#f4f4f5; --accent-soft:rgba(255,255,255,.07); --accent-line:rgba(255,255,255,.22);
  --btn-bg:#f4f4f5; --btn-fg:#111113; --btn-hover:#ffffff;
  --page-bg-2:#18181b; --page-surface:#18181b; --page-surface-2:#1e1e22;
  --page-fg:#f4f4f5; --page-fg-2:#b4b4bb; --page-fg-3:#8a8a92; --page-line:rgba(255,255,255,.08); --page-line-2:rgba(255,255,255,.14);
}
:root body{ background-color:var(--bg) }

/* ── 2. odstępy: zaokrąglone bloki nie stykają się krawędziami ── */
:root body .page-hero + .section-tint, :root body .page-hero + .sec-tint,
:root body .page-hero + section, :root body .page-hero + .help-topics-sec{ margin-top:14px }
:root body .section-tint + .section-tint, :root body .sec-tint + .sec-tint,
:root body .section-tint + .sec-tint, :root body .sec-tint + .section-tint{ margin-top:14px }
:root body .help-topics-sec{ padding-top:20px }

/* ── 3. linki w kartach i notkach: bez fioletu, podkreślenie ── */
:root body .cta-side .card a, :root body .cta-facts a, :root body .int-note a, :root body .int-box a, :root body .int-steps a,
:root body .md-note a, :root body .md-prose a, :root body .md-links a{
  color:var(--fg); text-decoration:underline; text-decoration-color:color-mix(in srgb, var(--fg) 30%, transparent);
  text-underline-offset:3px; text-decoration-thickness:1px; transition:text-decoration-color .2s var(--ease)
}
:root body .cta-side .card a:hover, :root body .cta-facts a:hover, :root body .int-steps a:hover,
:root body .md-links a:hover{ text-decoration-color:currentColor }
:root body .cta-final .cta-side .card a, :root body .cta-final .cta-facts a{ color:#fff; text-decoration-color:rgba(255,255,255,.4) }

/* ── 4. lista z ptaszkami (.kv): tekst i linki płyną razem, ptaszek obok ── */
:root body .kv li{ display:block; position:relative; padding-left:26px }
:root body .kv li::before{ position:absolute; left:0; top:.32em; margin-top:0; background:var(--fg) }

/* ── 5. stopka: bez dzielenia słów ── */
:root body .foot-col a{ -webkit-hyphens:manual; hyphens:manual }

/* ── 6. nagłówek sekcji pytań i jego wstęp ── */
:root body .faq-grid .h-sec + .lead, :root body .faq-grid h2 + p, :root body .faq-grid h2 + .lead{ margin-top:16px }

/* ── 7. kod w tekście ── */
:root body p code, :root body li code{ padding:.08em .38em; letter-spacing:0; border-radius:6px; background:var(--bg-2); border:1px solid var(--line); font-size:.9em; white-space:nowrap }
:root body .cta-final p code{ background:rgba(255,255,255,.08); border-color:rgba(255,255,255,.14) }

/* ── 8. strony modeli: kroki bez wcięcia przeglądarki, linki „Czytaj dalej” jako pigułki ── */
body.pg-modele .md-steps{ padding-left:0; list-style:none; counter-reset:k; display:grid; gap:10px }
body.pg-modele .md-steps li{ counter-increment:k; position:relative; padding:16px 20px 16px 58px; background:var(--surface); border:1px solid var(--line); border-radius:18px }
body.pg-modele .md-steps li::before{ content:counter(k); position:absolute; left:18px; top:15px; width:26px; height:26px; border-radius:50%; display:grid; place-items:center; font-size:13px; font-weight:600; background:var(--fg); color:var(--bg); font-family:inherit }
body.pg-modele .md-steps li::marker{ content:none }
:root body .md-links, :root body .int-links{ display:flex; flex-wrap:wrap; gap:8px; margin-top:14px; padding:0; list-style:none; columns:auto }
:root body .md-links a, :root body .int-links a{
  display:inline-flex; align-items:center; height:38px; padding:0 16px; border-radius:999px;
  background:var(--surface); border:1px solid var(--line-2); color:var(--fg); font-size:14.5px; font-weight:500;
  text-decoration:none !important; transition:border-color .2s var(--ease), transform .2s var(--ease)
}
:root body .md-links a:hover, :root body .int-links a:hover{ border-color:var(--fg); transform:translateY(-1px) }
:root body .md-links li{ margin:0 }

/* ── 9. integracje: karty nie rozciągają się na pusto, płytki z literą jak logo ── */
body.pg-integracje .int-cols{ align-items:start }
body.pg-integracje .int-steps{ max-width:none }
body.pg-integracje .lg b, body.pg-integracje .int-card .lg b{ font-family:inherit; font-weight:650; font-size:15px; letter-spacing:-.02em; color:var(--fg) }
body.pg-integracje .int-steps li::before, body.pg-integracje .int-steps li::before{ font-family:inherit; font-weight:600 }

/* ── 10. pobieranie: karty obok siebie od góry ── */
body.pg-pl .pl-two{ align-items:start }

/* ── 11. tabele na telefonie: wiersz = karta z podpisami kolumn (js/nav-v5.js nadaje data-k) ── */
@media (max-width:640px){
  :root body .tbl-wrap.n5-karty{ overflow:visible; border:0; background:none; box-shadow:none; padding:0 }
  :root body .tbl-wrap.n5-karty .tbl{ min-width:0 !important; width:100%; display:block; border:0 }
  :root body .tbl-wrap.n5-karty thead{ display:none }
  :root body .tbl-wrap.n5-karty tbody{ display:grid; gap:10px }
  :root body .tbl-wrap.n5-karty tr{ display:grid; grid-template-columns:1fr 1fr; gap:4px 14px; padding:16px 18px; background:var(--surface); border:1px solid var(--line); border-radius:18px }
  :root body .tbl-wrap.n5-karty td{ display:block; padding:0 !important; border:0 !important; min-width:0 !important; max-width:none !important; text-align:left !important; white-space:normal !important }
  :root body .tbl-wrap.n5-karty td:first-child, :root body .tbl-wrap.n5-karty td.op{ grid-column:1 / -1 }
  :root body .tbl-wrap.n5-karty td:first-child{ font-size:16px; font-weight:600 }
  :root body .tbl-wrap.n5-karty td.op{ margin-bottom:8px; font-size:14px }
  :root body .tbl-wrap.n5-karty td[data-k]:not(:first-child):not(.op)::before{ content:attr(data-k); display:block; font-size:12px; color:var(--fg-3); margin-bottom:2px }
}
/* tabele, które zostają przewijane: zanik przy prawej krawędzi mówi, że jest więcej */
@media (max-width:760px){
  :root body .tbl-wrap:not(.n5-karty), :root body .pl-term, :root body .lim-wrap{
    -webkit-mask-image:linear-gradient(90deg,#000 calc(100% - 28px),transparent); mask-image:linear-gradient(90deg,#000 calc(100% - 28px),transparent)
  }
  :root body .tbl-wrap.n5-koniec, :root body .pl-term.n5-koniec{ -webkit-mask-image:none; mask-image:none }
}

/* ── 12. sekcje końcowe na telefonie: przyciski jednej szerokości ── */
@media (max-width:520px){
  :root body .cta-final .cta-row, :root body .page-hero .hero-cta, :root body .cta-final .hero-cta{ display:grid; grid-template-columns:1fr; gap:10px; justify-items:stretch; width:100% }
  :root body .cta-final .cta-row > .btn, :root body .page-hero .hero-cta > .btn, :root body .cta-final .hero-cta > .btn{ width:100%; justify-content:center }
  :root body .cta-final .cta-row > a:has(img), :root body .page-hero .hero-cta > a:has(img), :root body .cta-final .hero-cta > a:has(img){ justify-self:center }
}

/* ── 13. blog: ostatni rząd bez dziury ── */
@media (min-width:981px){
  html body.bl4 .blog-list .post:last-child:nth-child(3n+2){ grid-column:span 2 }
}

/* ── 14. kody do wklejenia nie łamią się w środku słowa ── */
:root body pre, :root body .code-box, :root body .fm-kod{ white-space:pre; overflow-x:auto }

/* ── 15. odznaka „Zaraz startujemy” (dla firm) jak odznaka na głównej ── */
:root body .news-pill{
  align-items:center; gap:4px; height:40px; padding:4px 16px 4px 4px; border-radius:999px; flex-wrap:nowrap;
  background:rgba(255,255,255,.08); border:1px solid rgba(255,255,255,.16);
  -webkit-backdrop-filter:blur(14px); backdrop-filter:blur(14px); color:inherit; max-width:100%
}
:root body .news-pill b{
  display:inline-flex; align-items:center; height:30px; padding:0 12px; margin-right:6px; border-radius:999px;
  background:#fff; color:#111113; font-family:var(--mono, ui-monospace, monospace); font-size:11px; font-weight:600; letter-spacing:.08em; text-transform:uppercase; white-space:nowrap
}
:root body .news-pill b::after{ content:none }
:root body a.news-pill > span{ text-decoration:none; white-space:nowrap; overflow:hidden; text-overflow:ellipsis }
:root body a.news-pill:hover{ border-color:rgba(255,255,255,.34) }
:root body :not(.page-hero):not(.cta-final) > .news-pill{ background:var(--n5-szklo); border-color:var(--n5-obrys) }
:root body :not(.page-hero):not(.cta-final) > .news-pill b{ background:var(--fg); color:var(--bg) }

/* ── 16. wtyczki: wymagania i pomoc widoczne także na telefonie (pod treścią) ── */
@media (max-width:980px){ :root body.pg-info .article-side{ display:block !important; margin-top:32px } }

/* ── 17. modele: nieparzysta ostatnia karta na całą szerokość ── */
body.pg-modele .md-grid > :last-child:nth-child(odd){ grid-column:1 / -1 }

/* ── 18. funkcje: plik wysunięty w prawo nie wystaje poza kartę na telefonie ── */
@media (max-width:640px){ body.pg-funkcje .fx-files > li:nth-child(2){ margin-left:0; margin-right:0 } }

/* ── 19. strona główna: ściana agentów nie przykleja się do stopki, podpis czytelny ── */
:root body .sc-koniec{ margin-bottom:clamp(40px, 6vw, 88px) }
:root body .sc-koniec p{ text-shadow:0 1px 22px rgba(0,0,0,.65), 0 0 2px rgba(0,0,0,.4) }

/* ── 20. podstrony jak /codo (28.11): ciemne hero zaczyna się od samej góry strony, pasek z pigułkami
   unosi się nad nim (wcześniej scena startowała pod jasnym pasem nawigacji). Hero na pełną szerokość,
   zaokrąglone tylko u dołu. Dopóki pasek stoi nad ciemną sceną, ma ciemne szkło i biały napis
   (także rozwijane menu); po przewinięciu i przy otwartym menu na telefonie wraca zwykły pasek. ── */
:root body main > .page-hero:first-child, :root body main > svg.sprite:first-child + .page-hero{
  margin:-72px 0 0; border-radius:0 0 var(--v3-r) var(--v3-r);
  padding-top:calc(72px + clamp(64px, 8vw, 120px));
}
:root:not(.nav-open) body:has(main > .page-hero:first-child, main > svg.sprite:first-child + .page-hero) .nav.nav5:not(.is-scrolled) :is(.brand, .nav-links > .nav-link, .nav-links > .dd > .dd-btn, .nav-pill, .burger){
  --fg:#fff; --fg-2:rgba(255,255,255,.74); --fg-3:rgba(255,255,255,.52); --bg:#111216;
}
:root:not(.nav-open) body:has(main > .page-hero:first-child, main > svg.sprite:first-child + .page-hero) .nav.nav5:not(.is-scrolled) :is(.nav-links, .nav-pill:not(.nav-pobierz), .burger){
  background:rgba(255,255,255,.08); border-color:rgba(255,255,255,.16); box-shadow:inset 0 1px 0 rgba(255,255,255,.08);
}
:root:not(.nav-open) body:has(main > .page-hero:first-child, main > svg.sprite:first-child + .page-hero) .nav.nav5:not(.is-scrolled) .nav-wsk{ --n5-wsk:rgba(255,255,255,.14) }
@media (max-width:980px){
  :root body main > .page-hero:first-child, :root body main > svg.sprite:first-child + .page-hero{
    margin-top:-64px; padding-top:calc(64px + clamp(48px, 8vw, 88px)); border-radius:0 0 22px 22px;
  }
}
