/* ============================================================
   mpFaktura - nowy początek strony
   Light "premium SaaS" system (z opcją ciemną w Tweaks)
   ============================================================ */

:root {
  /* Dostepnosc - skala tekstu (A- / A / A+). 1 = bez zmiany, zakres 0.9-1.5.
     Ustawiana z a11y.js przez --a11y-text-scale; skaluje TYLKO typografie
     (font-size = calc(Npx * var(--a11y-text-scale))), nie zoomuje calej strony,
     wiec nie koliduje z natywnym Cmd +/-/0 przegladarki. */
  --a11y-text-scale: 1;
  /* Light surfaces (default) */
  --bg:            #FAFBFD;
  --bg-2:          #F1F4F9;
  --surface:       #FFFFFF;
  --surface-2:     #F6F8FC;
  --surface-3:     #EDF1F7;
  --border:        rgba(15,23,42,0.09);
  /* WCAG: wzmocniona ramka ogolna (karty, separatory) */
  --border-strong: rgba(15,23,42,0.22);
  /* WCAG: dedykowana ramka pol formularzy - >=3:1 wzgledem tla pola (--bg) */
  --field-border:  #868EA0;

  --text:          #0E1525;
  --text-2:        #46506A;
  /* WCAG: przyciemniony podpis/placeholder (>=4.5:1) - bylo #79829A */
  --text-3:        #5C6478;

  /* subtle theme-aware fills / lines / hover */
  --fill-1:  rgba(15,23,42,0.04);
  --fill-2:  rgba(15,23,42,0.07);
  --line:    rgba(15,23,42,0.06);
  --hover:   rgba(15,23,42,0.05);

  /* Accent - driven by Tweaks (set on :root via JS) */
  --accent:        #2563EB;
  /* WCAG: ciemniejszy cyjan dla tekstu/badge (>=4.5:1) - bylo #0891B2 */
  --accent-2:      #0E7490;
  --accent-ink:    #ffffff;
  --accent-soft:   color-mix(in oklab, var(--accent) 12%, transparent);
  --accent-glow:   color-mix(in oklab, var(--accent) 34%, transparent);

  /* WCAG: ciemniejsza zielen dla tekstu/badge (>=4.5:1) - bylo #059669 */
  --success:       #047857;
  --success-soft:  color-mix(in oklab, var(--success) 13%, transparent);
  /* WCAG: ciemniejszy bursztyn - czytelny tez na tle warn-soft (badge) - bylo #D97706 */
  --warn:          #92400E;

  --grad: linear-gradient(120deg, var(--accent), var(--accent-2));
  /* Gradient TYLKO dla powierzchni przyciskow z bialym napisem.
     Konczy sie ciemnym niebieskim (nie jasnym cyjanem), wiec bialy tekst
     ma >=4.5:1 na calej powierzchni. Akcent marki (badge/linki) bez zmian. */
  --btn-grad: linear-gradient(120deg, #1D4ED8, #1746B8);

  /* Type - driven by Tweaks */
  --font-display: 'Poppins', system-ui, sans-serif;
  --font-body:    'Manrope', system-ui, sans-serif;

  --radius:    18px;
  --radius-sm: 12px;
  --radius-lg: 26px;

  --shadow:    0 18px 44px -20px rgba(15,23,42,0.22);
  --shadow-lg: 0 36px 80px -28px rgba(15,23,42,0.30);

  --maxw: 1200px;
  --gutter: clamp(20px, 5vw, 64px);
}

/* Dark theme (toggle in Tweaks) */
:root[data-theme="dark"] {
  --bg:            #0A0A0F;
  --bg-2:          #0D0D14;
  --surface:       #131320;
  --surface-2:     #17172A;
  --surface-3:     #1E1E33;
  --border:        rgba(255,255,255,0.08);
  --border-strong: rgba(255,255,255,0.14);
  /* WCAG: ramka pol formularzy >=3:1 wzgledem ciemnego tla pola */
  --field-border:  #646482;

  --text:          #F5F6FA;
  --text-2:        #B6B8C8;
  --text-3:        #80849A;

  --fill-1:  rgba(255,255,255,0.04);
  --fill-2:  rgba(255,255,255,0.07);
  --line:    rgba(255,255,255,0.04);
  --hover:   rgba(255,255,255,0.06);

  --accent:        #4F7CFF;
  --accent-2:      #22D3EE;
  --accent-soft:   color-mix(in oklab, var(--accent) 16%, transparent);
  --accent-glow:   color-mix(in oklab, var(--accent) 40%, transparent);

  --success:       #34D399;
  --success-soft:  color-mix(in oklab, var(--success) 16%, transparent);
  --warn:          #FBBF24;

  /* WCAG: gradient przyciskow konczy sie ciemnym niebieskim, bialy napis >=4.5:1 */
  --btn-grad: linear-gradient(120deg, #2D5BD6, #1A47B0);

  --shadow:    0 24px 60px -18px rgba(0,0,0,0.65);
  --shadow-lg: 0 40px 100px -24px rgba(0,0,0,0.75);
}

/* Dim / pośredni theme - głęboki granat-slate z wyraźną głębią (nie płaski szary) */
:root[data-theme="dim"] {
  --bg:            #1b2230;
  --bg-2:          #202838;
  --surface:       #283143;
  --surface-2:     #313c52;
  --surface-3:     #3c4861;
  --border:        rgba(150,170,210,0.16);
  --border-strong: rgba(160,180,220,0.30);
  /* WCAG: ramka pol formularzy >=3:1 wzgledem tla pola w trybie posrednim */
  --field-border:  #697896;

  --text:          #f3f6fb;
  --text-2:        #c6cedd;
  --text-3:        #9aa6bd;

  --fill-1:  rgba(255,255,255,0.045);
  --fill-2:  rgba(255,255,255,0.085);
  --line:    rgba(255,255,255,0.05);
  --hover:   rgba(255,255,255,0.075);

  --accent:        #6f9bff;
  --accent-2:      #3fd9f0;
  --accent-soft:   color-mix(in oklab, var(--accent) 22%, transparent);
  --accent-glow:   color-mix(in oklab, var(--accent) 40%, transparent);

  --success:       #45dda3;
  --success-soft:  color-mix(in oklab, var(--success) 22%, transparent);
  --warn:          #fbc14e;

  /* WCAG: gradient przyciskow konczy sie ciemnym niebieskim, bialy napis >=4.5:1 */
  --btn-grad: linear-gradient(120deg, #2A55C8, #2347AE);

  --shadow:    0 22px 48px -20px rgba(0,0,0,0.60);
  --shadow-lg: 0 36px 76px -26px rgba(0,0,0,0.72);
}
/* przygaszona poświata tła w trybie pośrednim - mniej mgły */
:root[data-theme="dim"] .bg-fx .glow.a { opacity: 0.30; }
:root[data-theme="dim"] .bg-fx .glow.b { opacity: 0.20; }

* { box-sizing: border-box; }

/* color-scheme informuje przegladarke o motywie, zeby natywne elementy
   (paski przewijania, <select>, autofill, pola formularzy) dopasowaly sie
   do jasnego/ciemnego tla. Bez tego w motywie dim/dark paski i autofill
   zostawaly jasne. Domyslnie light; tryby dark/dim nadpisuja na dark nizej. */
/* Tlo TAKZE na html (iOS 26 Liquid Glass): Safari sampluje kolor tla przy krawedziach
   i rozciaga go na swoj toolbar - przezroczyste html daje "ciecia" przy modalach. */
html { scroll-behavior: smooth; overflow-x: clip; color-scheme: light; background-color: var(--bg); }
:root[data-theme="dark"], :root[data-theme="dim"] { color-scheme: dark; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: calc(17px * var(--a11y-text-scale, 1));
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
  /* WCAG 1.4.10: dlugie naglowki lamia sie zamiast rozpychac layout na ~320px */
  overflow-wrap: break-word;
}

/* WCAG 1.4.10: dlugie ciagi (maile, URL-e, dlugie wyrazy) lamia sie na waskich ekranach */
p { margin: 0; text-wrap: pretty; overflow-wrap: break-word; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { display: block; max-width: 100%; }

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- Background atmosphere ---------- */
.page {
  position: relative;
  min-height: 100vh;
  isolation: isolate;
}
.bg-fx {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.bg-fx .grid {
  position: absolute;
  inset: 0;
  background-attachment: fixed;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 100% 75% at 50% 18%, #000 42%, transparent 85%);
}
.bg-fx .glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
}
.bg-fx .glow.a {
  width: 720px; height: 520px;
  top: -220px; left: 50%; transform: translateX(-50%);
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
}
.bg-fx .glow.b {
  width: 460px; height: 460px;
  top: 240px; right: -120px;
  background: radial-gradient(circle, color-mix(in oklab, var(--accent-2) 30%, transparent), transparent 70%);
  opacity: 0.4;
}

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: color-mix(in oklab, var(--bg) 72%, transparent);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.nav.scrolled { border-color: var(--border); }
.nav-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 70px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: calc(21px * var(--a11y-text-scale, 1));
  letter-spacing: -0.02em;
}
.brand .mark {
  width: 34px; height: 34px;
  border-radius: 9px;
  background: var(--grad);
  display: grid;
  place-items: center;
  font-size: calc(16px * var(--a11y-text-scale, 1));
  color: #fff;
  box-shadow: 0 6px 18px -4px var(--accent-glow);
}
.brand .mp { color: var(--accent); }
.nav-links {
  display: flex;
  gap: 4px;
  margin-left: 14px;
}
.nav-links a {
  padding: 8px 14px;
  border-radius: 9px;
  font-size: calc(15px * var(--a11y-text-scale, 1));
  font-weight: 500;
  color: var(--text-2);
  white-space: nowrap;
  transition: color .2s, background .2s;
}
.nav-links a:hover { color: var(--text); background: var(--hover); }
.nav-cta { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.nav-burger { display: none; margin-left: auto; width: 42px; height: 42px; border: 1px solid var(--border); border-radius: 11px; background: var(--fill-1); cursor: pointer; flex-direction: column; align-items: center; justify-content: center; gap: 4px; }
.nav-burger span { display: block; width: 18px; height: 2px; border-radius: 2px; background: var(--text); transition: transform .25s, opacity .2s; }
.nav.menu-open .nav-burger span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav.menu-open .nav-burger span:nth-child(2) { opacity: 0; }
.nav.menu-open .nav-burger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
.nav-mobile { display: none; flex-direction: column; gap: 2px; padding: 0 var(--gutter); max-height: 0; overflow: hidden; background: color-mix(in oklab, var(--bg) 96%, transparent); backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transition: max-height .3s ease, border-color .3s; }
.nav.menu-open .nav-mobile { max-height: 460px; border-bottom-color: var(--border); padding-top: 8px; padding-bottom: 16px; }
.nav-mobile a { padding: 13px 6px; font-size: calc(16px * var(--a11y-text-scale, 1)); font-weight: 600; color: var(--text); border-bottom: 1px solid var(--border); }
.nav-mobile-cta { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.nav-mobile-cta .btn { width: 100%; }
.theme-switch { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid var(--border); border-radius: 100px; background: var(--fill-1); }
.theme-switch button { width: 30px; height: 30px; border-radius: 100px; border: 0; background: transparent; color: var(--text-3); display: grid; place-items: center; transition: color .15s, background .15s; }
.theme-switch button:hover { color: var(--text); }
.theme-switch button.on { background: var(--surface); color: var(--accent); box-shadow: 0 1px 3px rgba(0,0,0,0.18); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 13px 22px;
  border-radius: 12px;
  font-weight: 600;
  font-size: calc(15.5px * var(--a11y-text-scale, 1));
  border: 1px solid transparent;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  /* WCAG: --btn-grad zamiast --grad - koniec gradientu jest ciemnym
     niebieskim (nie jasnym cyjanem), wiec bialy napis ma >=4.5:1 we
     wszystkich trybach. Akcent marki (badge/linki/teksty) bez zmian. */
  background: var(--btn-grad);
  color: #fff;
  box-shadow: 0 10px 28px -8px var(--accent-glow);
}
.btn-primary:hover { box-shadow: 0 16px 38px -8px var(--accent-glow); transform: translateY(-1px); }
.btn-ghost {
  background: var(--fill-1);
  border-color: var(--border-strong);
  color: var(--text);
}
.btn-ghost:hover { background: var(--fill-2); }
.btn-link {
  background: transparent;
  color: var(--text-2);
  padding: 13px 12px;
}
.btn-link:hover { color: var(--text); }
.btn-lg { padding: 16px 28px; font-size: calc(16.5px * var(--a11y-text-scale, 1)); border-radius: 14px; }
.btn-sm { padding: 9px 15px; font-size: calc(14px * var(--a11y-text-scale, 1)); border-radius: 10px; }

/* ============================================================
   SHARED chips / eyebrows
   ============================================================ */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 14px 7px 9px;
  border-radius: 100px;
  border: 1px solid var(--border-strong);
  background: var(--fill-1);
  font-size: calc(13.5px * var(--a11y-text-scale, 1));
  font-weight: 600;
  color: var(--text-2);
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px var(--success-soft);
}
.eyebrow .pill {
  font-size: calc(11px * var(--a11y-text-scale, 1));
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 100px;
  background: var(--accent-soft);
  color: var(--accent-2);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: calc(13px * var(--a11y-text-scale, 1));
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-2);
  margin-bottom: 18px;
}
.section-eyebrow::before {
  content: '';
  width: 22px; height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

/* ============================================================
   HERO (shared scaffolding)
   ============================================================ */
.hero { position: relative; padding-top: clamp(28px, 4.5vw, 56px); padding-bottom: clamp(28px, 4vw, 52px); }
.hero h1 {
  font-size: calc(clamp(38px, 6vw, 68px) * var(--a11y-text-scale, 1));
  margin-bottom: 22px;
}
.hero h1 .accent {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero .lead {
  font-size: calc(clamp(17px, 1.6vw, 20px) * var(--a11y-text-scale, 1));
  color: var(--text-2);
  max-width: 30ch;
  margin-bottom: 30px;
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.hero-note {
  margin-top: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: calc(13.5px * var(--a11y-text-scale, 1));
  color: var(--text-3);
}
.hero-note svg { color: var(--success); flex: none; }

/* micro trust row */
.microtrust {
  margin-top: 34px;
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}
.microtrust .item { display: flex; flex-direction: column; gap: 2px; }
.microtrust .num {
  font-family: var(--font-display);
  font-size: calc(24px * var(--a11y-text-scale, 1));
  font-weight: 700;
  letter-spacing: -0.02em;
}
.microtrust .num .accent { color: var(--accent-2); }
.microtrust .lbl { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }

/* ---------- Variant A: product-first split ---------- */
.heroA { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.hero-visual { position: relative; }

.app-window {
  border-radius: var(--radius);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.app-window .titlebar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}
.app-window .titlebar .dot { width: 11px; height: 11px; border-radius: 50%; }
.app-window .titlebar .dot:nth-child(1){ background:#ff5f57; }
.app-window .titlebar .dot:nth-child(2){ background:#febc2e; }
.app-window .titlebar .dot:nth-child(3){ background:#28c840; }
.app-window .titlebar .addr {
  margin-left: 10px;
  font-size: calc(12px * var(--a11y-text-scale, 1));
  color: var(--text-3);
  background: var(--fill-1);
  padding: 5px 12px;
  border-radius: 7px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 60%;
}
.app-window image-slot { width: 100%; height: 380px; display: block; }
.app-window .mk { border: 0; }
.hero-visual .mk { height: clamp(396px, 40vw, 468px); }
.heroA .hero-visual { position: relative; overflow: visible; }
.heroA .hero-visual .app-window { width: min(760px, 60vw); }
.mk-scaled { width: 100%; overflow: hidden; }
.mk-scaled-in { transform-origin: top left; }
.mk-scaled-in > .mk { width: 100% !important; height: 100% !important; border: 0; }

.float-card {
  position: absolute;
  border-radius: 14px;
  border: 1px solid var(--border-strong);
  background: color-mix(in oklab, var(--surface-2) 88%, transparent);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  padding: 13px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  animation: float 5s ease-in-out infinite;
}
.float-card .ic {
  width: 36px; height: 36px; border-radius: 10px;
  display: grid; place-items: center; flex: none;
}
.float-card .t { font-size: calc(13.5px * var(--a11y-text-scale, 1)); font-weight: 600; line-height: 1.25; white-space: nowrap; }
.float-card .s { font-size: calc(11.5px * var(--a11y-text-scale, 1)); color: var(--text-3); white-space: nowrap; }
.float-card.tl { top: -22px; left: -26px; animation-delay: -1s; }
.float-card.br { bottom: -24px; right: -22px; animation-delay: -2.5s; }
@keyframes float {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

/* ---------- Variant B: KSeF urgency ---------- */
.heroB { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(32px, 5vw, 60px); align-items: center; }
.countdown {
  border-radius: var(--radius);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  padding: 28px;
}
.countdown .head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 22px;
}
.countdown .head .label { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.countdown .head .badge {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: calc(12px * var(--a11y-text-scale, 1)); font-weight: 700;
  color: var(--warn);
  background: color-mix(in oklab, var(--warn) 14%, transparent);
  padding: 5px 11px; border-radius: 100px;
}
.countdown .target {
  font-family: var(--font-display);
  font-size: calc(19px * var(--a11y-text-scale, 1)); font-weight: 600; margin-bottom: 4px;
}
.countdown .target-sub { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-bottom: 22px; }
.cd-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.cd-cell {
  text-align: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 6px;
}
.cd-cell .v {
  font-family: var(--font-display);
  font-size: calc(clamp(26px, 3vw, 36px) * var(--a11y-text-scale, 1));
  font-weight: 700;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cd-cell .u { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-3); text-transform: uppercase; letter-spacing: 0.08em; margin-top: 4px; }
.mini-timeline {
  margin-top: 22px;
  display: flex;
  gap: 0;
  border-top: 1px solid var(--border);
  padding-top: 18px;
}
.mini-timeline .ms { flex: 1; position: relative; padding-left: 16px; }
.mini-timeline .ms::before {
  content:''; position:absolute; left:0; top:4px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--surface-3); border: 2px solid var(--text-3);
}
.mini-timeline .ms.on::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.mini-timeline .ms .d { font-size: calc(12px * var(--a11y-text-scale, 1)); font-weight: 700; }
.mini-timeline .ms .x { font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }

/* ---------- Variant C: AI-forward ---------- */
.heroC { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 60px); align-items: center; }
.ai-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.ai-pick-head { margin-top: 26px; }
.ai-pick-head .ai-pick-t { font-family: var(--font-display); font-weight: 600; font-size: calc(15px * var(--a11y-text-scale, 1)); color: var(--text); }
.ai-pick-head .ai-pick-s { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 3px; max-width: 46ch; line-height: 1.45; }
.ai-pick button {
  display: flex; align-items: center; gap: 9px; width: 100%; justify-content: flex-start;
  padding: 9px 14px 9px 9px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: var(--fill-1);
  color: var(--text-2);
  font-size: calc(13.5px * var(--a11y-text-scale, 1)); font-weight: 600;
  transition: all .2s;
}
.ai-pick button .av {
  width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center; font-size: calc(12px * var(--a11y-text-scale, 1)); color: #fff;
}
.ai-pick button.on { border-color: var(--accent); color: var(--text); background: var(--accent-soft); }

.chat {
  border-radius: var(--radius);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.chat .chat-head {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}
.chat .chat-head .av {
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; color: #fff; font-weight: 700;
  background: var(--grad);
}
.chat .chat-head .nm { font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); }
.chat .chat-head .st { font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--success); display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.chat .chat-head .st::before { content:''; width: 7px; height:7px; border-radius:50%; background: var(--success); box-shadow: 0 0 0 3px var(--success-soft); }
.chat .body {
  padding: 20px 18px;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background:
    radial-gradient(circle at 20% 0%, var(--fill-1), transparent 60%);
}
.msg { max-width: 82%; padding: 11px 15px; border-radius: 14px; font-size: calc(14.5px * var(--a11y-text-scale, 1)); line-height: 1.45; }
.msg.user { align-self: flex-end; background: var(--grad); color: #fff; border-bottom-right-radius: 4px; }
.msg.bot { align-self: flex-start; background: var(--surface-3); border: 1px solid var(--border); border-bottom-left-radius: 4px; }
.msg.bot .step { display: flex; align-items: center; gap: 9px; }
.msg.bot .step .ic { flex: none; }
.typing { display: inline-flex; gap: 4px; align-items: center; padding: 4px 2px; }
.typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); animation: blink 1.2s infinite; }
.typing span:nth-child(2){ animation-delay: .2s; }
.typing span:nth-child(3){ animation-delay: .4s; }
@keyframes blink { 0%,60%,100%{ opacity:.3; transform: translateY(0);} 30%{ opacity:1; transform: translateY(-3px);} }
.chat .composer {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
}
.chat .composer .fakeinput {
  flex: 1; font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-3);
  background: var(--bg-2); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 13px;
}
.chat .composer .send {
  width: 40px; height: 40px; border-radius: 10px;
  background: var(--grad); display: grid; place-items: center; color: #fff; flex: none;
}

/* ============================================================
   TRUST STRIP
   ============================================================ */
.trust-strip {
  border-top: 2px solid var(--border-strong);
  border-bottom: 2px solid var(--border-strong);
  padding: 18px 0;
  margin-top: clamp(20px, 3vw, 32px);
}
.trust-strip + .section { padding-top: clamp(36px, 5vw, 60px); }
.trust-logos { display: flex; align-items: center; gap: clamp(22px, 4vw, 44px); flex-wrap: wrap; justify-content: center; }
.trust-logos .lg {
  font-family: var(--font-display);
  font-weight: 700; font-size: calc(17px * var(--a11y-text-scale, 1));
  color: var(--text-3);
  opacity: .8;
  letter-spacing: -0.01em;
  filter: grayscale(1);
  transition: opacity .2s, color .2s;
}
.trust-logos .lg:hover { opacity: 1; color: var(--text-2); }

/* Pasek zaufania = auto-przewijajacy marquee (klasy nadawane w index.html).
   Lead po lewej (staly), obok okno .trust-marquee z przewijanym torem .trust-track.
   Tor ma ZDUBLOWANY zestaw logotypow -> translacja o -50% = jeden pelny zestaw =
   bezszwowa, ciagla petla. Nazwy firm NIE sa sciskane (font pelny 17px). */
.trust-bar {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 40px);
}
.trust-bar .lead-txt { flex: 0 0 auto; }

/* Okno marquee - obcina tor i wygasza brzegi (lewy/prawy fade). */
.trust-marquee {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  -webkit-mask: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
          mask: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}

/* Przewijany tor - flex w jednej linii, szerszy niz okno (width:max-content),
   bez zawijania -> nazwy zawsze w pelnym foncie. */
.trust-track {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: clamp(22px, 4vw, 44px);
  width: max-content;
  padding: 2px clamp(11px, 2vw, 22px);
  animation: trust-scroll 32s linear infinite;
}
.trust-track .lg { flex: 0 0 auto; white-space: nowrap; }

/* -50% = dokladnie szerokosc jednego (z dwoch) zestawow -> bezszwowe zapetlenie. */
@keyframes trust-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* Pauza przewijania na najechanie myszka. */
.trust-marquee:hover .trust-track { animation-play-state: paused; }

/* Waskie ekrany: lead nad marquee, marquee pelna szerokosc. */
@media (max-width: 720px) {
  .trust-bar { flex-direction: column; align-items: flex-start; gap: 12px; }
  .trust-marquee { width: 100%; }
}

/* Mniej ruchu (preferencja systemowa): statyczny, zawijany rzad bez animacji,
   bez podwojenia logotypow i bez maski wygaszajacej brzegi.
   !important + transform:none, bo strona ma globalny reset *{animation-duration:0.01ms}
   ktory inaczej zostawilby tor przesuniety o -50% (znikneloby pol logotypow). */
@media (prefers-reduced-motion: reduce) {
  .trust-track {
    animation: none !important;
    transform: none !important;
    flex-wrap: wrap;
    width: auto;
    justify-content: center;
  }
  .trust-marquee {
    -webkit-mask: none;
            mask: none;
  }
  .trust-track .lg[aria-hidden="true"] { display: none; }
}

/* ============================================================
   SECTION heading block
   ============================================================ */
.section { padding: clamp(28px, 3.6vw, 40px) 0; }
.section-head { max-width: 640px; margin-bottom: clamp(28px, 3.5vw, 42px); }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head h2 { font-size: calc(clamp(30px, 4.2vw, 46px) * var(--a11y-text-scale, 1)); margin-bottom: 16px; }
.section-head p { font-size: calc(18px * var(--a11y-text-scale, 1)); color: var(--text-2); }

/* ============================================================
   FEATURES - bento
   ============================================================ */
.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
}
.card {
  position: relative;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 26px;
  overflow: hidden;
  transition: border-color .25s, transform .25s, background .25s;
}
.card:hover { border-color: var(--border-strong); transform: translateY(-3px); }
.card .ic-box {
  width: 46px; height: 46px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--accent-soft);
  color: var(--accent-2);
  margin-bottom: 18px;
}
.card h3 { font-size: calc(20px * var(--a11y-text-scale, 1)); margin-bottom: 9px; }
.card p { font-size: calc(14.5px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.card .chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.card .chips > span {
  font-size: calc(12px * var(--a11y-text-scale, 1)); font-weight: 600;
  padding: 5px 11px; border-radius: 100px;
  background: var(--fill-1);
  border: 1px solid var(--border);
  color: var(--text-2);
}
.card.span-3 { grid-column: span 3; }
.card.span-2 { grid-column: span 2; }
.card.span-4 { grid-column: span 4; }
.card.feature-hero { grid-column: span 3; grid-row: span 2; display: flex; flex-direction: column; }
.card.feature-hero .grow { flex: 1; }
.card.accent-card {
  background: linear-gradient(150deg, color-mix(in oklab, var(--accent) 22%, var(--surface)), var(--surface) 60%);
  border-color: var(--accent-glow);
}
.card.accent-card .ic-box { background: var(--grad); color: #fff; box-shadow: 0 6px 16px -6px var(--accent-glow); }
.badge-ok {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: calc(12.5px * var(--a11y-text-scale, 1)); font-weight: 700; color: var(--success);
  background: var(--success-soft); padding: 6px 12px; border-radius: 100px;
  margin-top: 16px;
}

/* feature-hero faux invoice */
.mini-invoice {
  margin-top: 20px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--bg-2);
  padding: 16px;
  font-size: calc(12.5px * var(--a11y-text-scale, 1));
}
.mini-invoice .row { display: flex; justify-content: space-between; gap: 14px; padding: 7px 0; border-bottom: 1px dashed var(--border); color: var(--text-2); }
.mini-invoice .row span:first-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-invoice .row span:last-child { white-space: nowrap; flex: none; }
.mini-invoice .row:last-child { border-bottom: 0; }
.mini-invoice .row.total { color: var(--text); font-weight: 700; font-family: var(--font-display); font-size: calc(15px * var(--a11y-text-scale, 1)); }
.mini-invoice .row .ksef { color: var(--success); font-weight: 700; }

/* ============================================================
   KSeF SECTION
   ============================================================ */
.ksef-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(36px, 5vw, 64px); align-items: start; }
.timeline { position: relative; padding-left: 28px; }
.timeline::before {
  content:''; position:absolute; left: 7px; top: 6px; bottom: 6px;
  width: 2px; background: linear-gradient(var(--accent), transparent);
}
.tl-item { position: relative; padding-bottom: 26px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content:''; position:absolute; left: -28px; top: 4px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--surface); border: 2px solid var(--text-3);
}
.tl-item.done::before { background: var(--success); border-color: var(--success); }
.tl-item.now::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 5px var(--accent-soft); }
.tl-item .date { font-family: var(--font-display); font-size: calc(13px * var(--a11y-text-scale, 1)); font-weight: 700; color: var(--accent-2); letter-spacing: 0.04em; }
.tl-item .ttl { font-size: calc(16px * var(--a11y-text-scale, 1)); font-weight: 600; margin: 3px 0 2px; }
.tl-item .desc { font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.tl-item .tag {
  display: inline-block; margin-top: 6px;
  font-size: calc(11px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 3px 9px; border-radius: 100px;
}
.tl-item.now .tag { background: var(--accent-soft); color: var(--accent-2); }
.tl-item.obl .tag { background: color-mix(in oklab, var(--warn) 16%, transparent); color: var(--warn); }

.ksef-panel {
  border-radius: var(--radius);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  padding: 28px;
  box-shadow: var(--shadow);
  position: sticky; top: 90px;
}
.ksef-panel h3 { font-size: calc(19px * var(--a11y-text-scale, 1)); margin-bottom: 18px; }
.ksef-list { display: grid; gap: 12px; margin-bottom: 22px; }
.ksef-list li { display: flex; gap: 11px; align-items: flex-start; font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); list-style: none; }
.ksef-list li svg { color: var(--success); flex: none; margin-top: 2px; }
.ksef-panel ul { padding: 0; }

/* KSeF - poziomy pasek postępu + termin */
.ksef-track { display: flex; justify-content: space-between; gap: 8px; position: relative; margin: 6px 0 clamp(30px, 4vw, 46px); }
.ksef-track::before { content: ''; position: absolute; left: 8%; right: 8%; top: 14px; height: 2px; background: var(--border-strong); z-index: 0; }
.ksef-node { position: relative; z-index: 1; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.ksef-node .nd-dot { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); border: 2px solid var(--border-strong); color: var(--text-3); }
.ksef-node.done .nd-dot { background: var(--success); border-color: var(--success); color: #fff; }
.ksef-node.now .nd-dot { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 0 0 5px var(--accent-soft); }
.ksef-node .nd-date { font-family: var(--font-display); font-size: calc(12.5px * var(--a11y-text-scale, 1)); font-weight: 700; color: var(--text-2); letter-spacing: 0.02em; }
.ksef-node.now .nd-date { color: var(--accent); }
.ksef-node .nd-t { font-size: calc(11.5px * var(--a11y-text-scale, 1)); color: var(--text-3); max-width: 130px; line-height: 1.3; }

.ksef-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(14px, 2vw, 22px); align-items: stretch; }
.ksef-deadline { border: 1px solid var(--accent-glow); border-radius: var(--radius); padding: clamp(24px, 3vw, 34px); background: linear-gradient(150deg, var(--accent-soft), var(--surface) 72%); display: flex; flex-direction: column; }
.kd-eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: calc(12.5px * var(--a11y-text-scale, 1)); font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 0.06em; }
.kd-date { font-family: var(--font-display); font-size: calc(clamp(28px, 3.4vw, 40px) * var(--a11y-text-scale, 1)); font-weight: 700; letter-spacing: -0.02em; margin: 14px 0 4px; }
.kd-sub { font-size: calc(15px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.kd-count { display: flex; align-items: center; gap: 16px; margin: 22px 0; padding-top: 22px; border-top: 1px solid var(--border); }
.kd-num { font-family: var(--font-display); font-size: calc(clamp(44px, 6vw, 64px) * var(--a11y-text-scale, 1)); font-weight: 700; letter-spacing: -0.03em; line-height: 1; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.kd-unit { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); line-height: 1.4; }
.kd-note { margin-top: auto; display: flex; align-items: center; gap: 9px; font-size: calc(13.5px * var(--a11y-text-scale, 1)); font-weight: 600; color: var(--success); }
.kd-note svg { flex: none; }

/* ============================================================
   STATS band
   ============================================================ */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.stat {
  text-align: center;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 24px 18px;
}
.stat .v {
  font-family: var(--font-display);
  font-size: calc(clamp(30px, 4vw, 44px) * var(--a11y-text-scale, 1));
  font-weight: 700;
  letter-spacing: -0.03em;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.stat .l { font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 6px; }

/* ============================================================
   TESTIMONIALS
   ============================================================ */
.tgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.quote {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 26px;
  display: flex; flex-direction: column;
}
.quote .stars { display: flex; gap: 3px; color: var(--warn); margin-bottom: 14px; }
.quote p { font-size: calc(15px * var(--a11y-text-scale, 1)); color: var(--text); line-height: 1.55; flex: 1; }
.quote .who { display: flex; align-items: flex-start; gap: 12px; margin-top: 20px; }
.quote .who .av {
  width: 42px; height: 42px; border-radius: 50%; flex: none;
  display: grid; place-items: center; font-weight: 700; font-size: calc(14px * var(--a11y-text-scale, 1));
  background: var(--surface-3); border: 1px solid var(--border); color: var(--text-2);
}
.quote .who .nm { font-weight: 700; font-size: calc(14.5px * var(--a11y-text-scale, 1)); line-height: 1.3; }
.quote .who .rl { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); line-height: 1.35; margin-top: 2px; }

/* ============================================================
   FINAL CTA
   ============================================================ */
.cta-ai { max-width: none; margin-inline: auto; border: 1px solid var(--accent-glow); border-radius: var(--radius-lg); background: linear-gradient(160deg, var(--accent-soft), var(--surface) 58%); box-shadow: var(--shadow-lg); overflow: hidden; }
.cta-ai-head { display: flex; align-items: center; gap: 12px; padding: 16px 22px; border-bottom: 1px solid var(--border); background: color-mix(in oklab, var(--surface) 72%, transparent); }
.cta-ai-head .av { width: 44px; height: 44px; border-radius: 13px; background: var(--grad); display: grid; place-items: center; color: #fff; flex: none; box-shadow: inset 0 1px 0 rgba(255,255,255,0.28), 0 6px 16px -6px var(--accent-glow); }
.cta-ai-head .av svg { width: 52%; height: 52%; }
.cta-ai-head .nm { font-family: var(--font-display); font-weight: 700; font-size: calc(16px * var(--a11y-text-scale, 1)); }
.cta-ai-head .st { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--success); display: flex; align-items: center; gap: 6px; }
.cta-ai-head .st::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 3px var(--success-soft); }
.cta-ai-tag { margin-left: auto; font-size: calc(11.5px * var(--a11y-text-scale, 1)); font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent); background: var(--accent-soft); padding: 6px 13px; border-radius: 100px; }
.cta-ai-body { display: grid; grid-template-columns: 1.5fr 1fr; gap: clamp(22px, 4vw, 52px); align-items: center; padding: clamp(24px, 3vw, 40px); }
.cta-ai-msg h2 { font-size: calc(clamp(26px, 3.4vw, 42px) * var(--a11y-text-scale, 1)); margin-bottom: 12px; }
.cta-ai-msg p { font-size: calc(16.5px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.6; }
.cta-ai-actions { display: flex; flex-direction: column; gap: 12px; align-items: stretch; }
.cta-ai-actions .btn { width: 100%; }
.cta-ai-note { display: flex; align-items: center; gap: 9px; font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 4px; justify-content: center; }
.cta-ai-note svg { color: var(--success); flex: none; }
.final {
  position: relative;
  border-radius: var(--radius-lg);
  border: 1px solid var(--accent-glow);
  background:
    radial-gradient(ellipse 80% 120% at 50% 0%, var(--accent-soft), transparent 60%),
    var(--surface);
  padding: clamp(48px, 7vw, 80px) var(--gutter);
  text-align: center;
  overflow: hidden;
}
.final::before {
  content:''; position:absolute; inset:0;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 60% 80% at 50% 50%, #000, transparent 70%);
  pointer-events: none;
}
.final h2 { font-size: calc(clamp(30px, 4.5vw, 50px) * var(--a11y-text-scale, 1)); margin-bottom: 16px; position: relative; }
.final p { font-size: calc(18px * var(--a11y-text-scale, 1)); color: var(--text-2); margin-bottom: 30px; position: relative; }
.final .hero-cta { justify-content: center; position: relative; }

/* footer mini */
.foot {
  padding: 40px 0 56px;
  color: var(--text-3);
  font-size: calc(13.5px * var(--a11y-text-scale, 1));
  text-align: center;
}

/* ============================================================
   AI ASSISTANT SECTION
   ============================================================ */
/* subtelna kratka w tle sekcji-paneli */
#ai, #galeria, #ksef { position: relative; }
#ai::before, #galeria::before, #ksef::before {
  content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  background-attachment: fixed;
  -webkit-mask-image: radial-gradient(ellipse 85% 75% at 50% 0%, #000 30%, transparent 78%);
  mask-image: radial-gradient(ellipse 85% 75% at 50% 0%, #000 30%, transparent 78%);
}
#ai > .wrap, #galeria > .wrap, #ksef > .wrap { position: relative; z-index: 1; }
.assist-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 5vw, 64px); align-items: center; }
.cap-list { display: grid; grid-template-columns: 1fr 1fr; gap: 13px 22px; margin: 4px 0 0; padding: 0; }
.cap-list li { list-style: none; display: flex; gap: 11px; align-items: flex-start; font-size: calc(14.5px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.cap-list li .ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-2); flex: none; }

/* ============================================================
   3-up cards (why)
   ============================================================ */
.tri-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }

/* ============================================================
   GALLERY
   ============================================================ */
.gal-tabs { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-bottom: 26px; }
.gal-tabs button {
  padding: 10px 18px; border-radius: 100px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text-2); font-weight: 600; font-size: calc(14px * var(--a11y-text-scale, 1));
  transition: all .2s;
}
.gal-tabs button:hover { border-color: var(--border-strong); color: var(--text); }
.gal-tabs button { white-space: nowrap; }
/* WCAG: aktywna zakladka ma bialy napis - uzyj --btn-grad (czytelny >=4.5:1) */
.gal-tabs button.on { background: var(--btn-grad); border-color: transparent; color: #fff; box-shadow: 0 8px 22px -8px var(--accent-glow); }
.gal-stage { max-width: 1000px; margin-inline: auto; }
.gal-stage image-slot { width: 100%; height: clamp(320px, 46vw, 540px); display: block; }
.gal-stage .mk[data-mock="dashboard"] { height: clamp(440px, 50vw, 620px); }
.gal-stage .mk[data-mock="sales"] { height: clamp(520px, 58vw, 710px); }
.gal-stage .mk[data-mock="contractors"] { height: clamp(440px, 50vw, 620px); }
.mk-inv-bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; min-height: 0; }
.mk-inv-bottom .mk-ipanel { min-width: 0; }
.gal-cap { text-align: center; margin-top: 16px; font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-3); }

/* ============================================================
   PRICING
   ============================================================ */
.price-note { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-bottom: 30px; }
.price-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; align-items: stretch; }
.plan {
  border: 1px solid var(--border); background: var(--surface);
  border-radius: var(--radius); padding: 28px 24px;
  display: flex; flex-direction: column; position: relative;
}
.plan.pop { border-color: var(--accent); box-shadow: var(--shadow); }
@media (prefers-reduced-motion: no-preference) {
  .plan.pop { animation: planPulse 3.4s ease-in-out infinite; }
}
@keyframes planPulse {
  0%, 100% { box-shadow: var(--shadow), 0 0 0 0 var(--accent-soft); border-color: var(--accent); }
  50% { box-shadow: var(--shadow), 0 0 0 6px color-mix(in oklab, var(--accent) 10%, transparent); border-color: color-mix(in oklab, var(--accent) 70%, var(--border-strong)); }
}
html.a11y-no-motion .plan.pop { animation: none !important; }
.plan .pop-badge {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--grad); color: #fff; font-size: calc(11px * var(--a11y-text-scale, 1)); font-weight: 700;
  padding: 6px 14px; border-radius: 100px; white-space: nowrap; letter-spacing: 0.02em;
}
.plan .name { font-family: var(--font-display); font-weight: 600; font-size: calc(18px * var(--a11y-text-scale, 1)); }
.plan .price { font-family: var(--font-display); font-size: calc(38px * var(--a11y-text-scale, 1)); font-weight: 700; margin: 12px 0 0; letter-spacing: -0.03em; }
.plan .price span { font-size: calc(15px * var(--a11y-text-scale, 1)); color: var(--text-3); font-weight: 500; letter-spacing: 0; }
.plan ul { list-style: none; margin: 20px 0 22px; padding: 0; display: grid; gap: 11px; flex: 1; }
.plan ul li { display: flex; gap: 9px; font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.plan ul li svg { color: var(--success); flex: none; margin-top: 2px; }

/* ============================================================
   FAQ
   ============================================================ */
.faq { max-width: 820px; margin-inline: auto; display: grid; gap: 12px; }
.faq-wide { max-width: none; grid-template-columns: 1fr 1fr; align-items: start; }
.faq-full { max-width: none; }
@media (max-width: 760px) { .faq-wide { grid-template-columns: 1fr; } }
.faq-search { max-width: 560px; margin: 0 auto 28px; position: relative; }
/* WCAG: ramka pola wyszukiwarki - --field-border zapewnia >=3:1 wzgledem tla */
.faq-search input { width: 100%; padding: 14px 16px 14px 46px; border-radius: 12px; border: 1px solid var(--field-border); background: var(--surface); color: var(--text); font-size: calc(15.5px * var(--a11y-text-scale, 1)); font-family: inherit; transition: border-color .2s, box-shadow .2s; }
.faq-search input::placeholder { color: var(--text-3); }
.faq-search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.faq-search .si { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--text-3); display: grid; }
.faq-empty { text-align: center; color: var(--text-3); padding: 30px 0; }
.section-eyebrow { white-space: nowrap; }

/* FAQ search with suggestions */
.faq-search-wrap { position: relative; max-width: 620px; margin: 0 auto; text-align: left; }
.faq-search-wrap .faq-search { max-width: none; margin: 0; }
.sugg { position: absolute; top: calc(100% + 8px); left: 0; right: 0; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 14px; box-shadow: var(--shadow-lg); max-height: 440px; overflow-y: auto; z-index: 40; padding: 6px; }
.sugg .grp { font-size: calc(11px * var(--a11y-text-scale, 1)); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-2); padding: 13px 14px 6px; }
.sugg .item { display: block; width: 100%; text-align: left; padding: 10px 14px; border-radius: 10px; cursor: pointer; background: none; border: 0; }
.sugg .item:hover, .sugg .item.active { background: var(--hover); }
.sugg .item .q { font-weight: 600; font-size: calc(14.5px * var(--a11y-text-scale, 1)); color: var(--text); margin-bottom: 3px; }
.sugg .item .s { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); line-height: 1.45; }
.sugg mark { background: var(--accent-soft); color: var(--accent); font-weight: 700; padding: 0 2px; border-radius: 3px; }
.sugg .none { padding: 18px 16px; color: var(--text-3); font-size: calc(14px * var(--a11y-text-scale, 1)); }
.sugg .none a { color: var(--accent); font-weight: 600; }
.qa-flash { border-color: var(--accent) !important; box-shadow: 0 0 0 3px var(--accent-soft); transition: box-shadow .3s, border-color .3s; }
details.qa { border: 1px solid var(--border); border-radius: 14px; background: var(--surface); padding: 2px 22px; transition: border-color .2s; }
details.qa[open] { border-color: var(--border-strong); }
details.qa summary {
  cursor: pointer; list-style: none; padding: 19px 0;
  font-weight: 600; font-size: calc(16px * var(--a11y-text-scale, 1)); color: var(--text);
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
details.qa summary::-webkit-details-marker { display: none; }
details.qa summary .chev { transition: transform .25s; color: var(--text-3); flex: none; }
details.qa[open] summary .chev { transform: rotate(180deg); color: var(--accent); }
details.qa .ans { padding: 0 0 20px; color: var(--text-2); font-size: calc(14.5px * var(--a11y-text-scale, 1)); margin: 0; line-height: 1.6; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer { border-top: 1px solid var(--border); background: var(--bg-2); padding: 58px 0 30px; margin-top: clamp(48px, 7vw, 90px); }
.footer-grid { display: grid; grid-template-columns: 1.5fr repeat(4, 1fr); gap: 32px; }
.footer .brand { font-size: calc(20px * var(--a11y-text-scale, 1)); }
.footer .brand-col p { font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-3); margin: 16px 0 0; max-width: 32ch; }
.footer h4 { font-family: var(--font-body); font-weight: 700; font-size: calc(12.5px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-3); margin: 0 0 16px; }
.footer .col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
/* WCAG 2.5.8: cel dotykowy linku w stopce min 24px wysokosci (padding + min-height) */
.footer .col ul li a { display: inline-flex; align-items: center; min-height: 24px; padding: 3px 0; font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); transition: color .2s; }
.footer .col ul li a:hover { color: var(--accent); }
.footer-social-link { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border: 1px solid var(--border); border-radius: 8px; color: var(--text-2); transition: color .2s, border-color .2s; }
.footer-social-link:hover { color: var(--accent); border-color: var(--accent); }
.footer-bottom { border-top: 1px solid var(--border); margin-top: 44px; padding-top: 24px; font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
/* Przycisk dostepnosci (fixed, lewy dolny rog, 52px + 18px = ~70px) nie moze
   zaslaniac copyrightu w stopce. Rezerwujemy dolny odstep na mobile. */
@media (max-width: 768px) {
  .footer { padding-bottom: 84px; }
}

/* ============================================================
   SUBPAGES - shared
   ============================================================ */
.page-hero { position: relative; padding: clamp(22px, 3.5vw, 44px) 0 clamp(24px, 3vw, 36px); }
.kontakt-hero .wrap { max-width: calc(1040px + 2 * var(--gutter)); }
.page-hero h1 { font-size: calc(clamp(34px, 5vw, 58px) * var(--a11y-text-scale, 1)); margin-bottom: 18px; }
.page-hero h1 .accent { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.page-hero .ph-sub { font-size: calc(clamp(16px, 1.5vw, 20px) * var(--a11y-text-scale, 1)); color: var(--text-2); max-width: 62ch; }

.crumbs { display: flex; gap: 8px; align-items: center; font-size: calc(13px * var(--a11y-text-scale, 1)); margin-bottom: 22px; color: var(--text-3); flex-wrap: wrap; }
.crumbs a { color: var(--text-3); }
.crumbs a:hover { color: var(--accent); }
.crumbs .cur { color: var(--text-2); }
.crumbs .sep { color: var(--text-3); opacity: .5; }

.ph-stats { display: flex; gap: clamp(26px, 5vw, 56px); margin-top: 32px; flex-wrap: wrap; }
.ph-stat .v { font-family: var(--font-display); font-size: calc(clamp(28px, 3vw, 40px) * var(--a11y-text-scale, 1)); font-weight: 700; letter-spacing: -0.02em; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ph-stat .l { font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }

/* ============================================================
   FUNKCJE - modules
   ============================================================ */
.cat-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 30px; }
.cat-chips a { padding: 8px 15px; border-radius: 100px; border: 1px solid var(--border); background: var(--surface); font-size: calc(13.5px * var(--a11y-text-scale, 1)); font-weight: 600; color: var(--text-2); transition: all .2s; }
.cat-chips a:hover { border-color: var(--accent); color: var(--accent); }

.modules { display: grid; gap: 16px; }
.module { border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius); padding: clamp(24px, 3vw, 34px); display: grid; grid-template-columns: 56px 1fr; gap: 6px 24px; align-items: start; transition: border-color .2s; }
.module:hover { border-color: var(--border-strong); }
.module .mnum { grid-row: 1; font-family: var(--font-display); font-size: calc(16px * var(--a11y-text-scale, 1)); font-weight: 700; color: #fff; width: 48px; height: 48px; border-radius: 12px; background: var(--grad); display: grid; place-items: center; box-shadow: 0 8px 20px -8px var(--accent-glow); }
.module .mhead { grid-column: 2; align-self: center; }
.module .mhead h3 { font-size: calc(clamp(20px, 2.2vw, 25px) * var(--a11y-text-scale, 1)); margin-bottom: 3px; }
.module .mhead .mtag { font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--accent-2); font-weight: 600; }
.module .mfeats { grid-column: 2; display: grid; grid-template-columns: 1fr 1fr; gap: 11px 26px; margin-top: 16px; padding: 0; }
.module .mfeats li { list-style: none; display: flex; gap: 10px; font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.module .mfeats li svg { color: var(--success); flex: none; margin-top: 3px; }
.module-cta { grid-column: 1 / -1; margin-top: 12px; border-radius: 14px; padding: 16px 18px; background: linear-gradient(150deg, var(--accent-soft), var(--surface) 72%); border: 1px solid var(--accent-glow); display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.module-cta .mc-av { width: 38px; height: 38px; border-radius: 11px; background: var(--grad); color: #fff; display: grid; place-items: center; flex: none; box-shadow: inset 0 1px 0 rgba(255,255,255,0.28), 0 6px 16px -6px var(--accent-glow); }
.module-cta .mc-body { min-width: 0; flex: 1; }
.module-cta .btn { flex: none; }
.module-cta .mc-tag { font-size: calc(10.5px * var(--a11y-text-scale, 1)); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--accent); margin-bottom: 3px; }
.module-cta .mc-t { font-family: var(--font-display); font-weight: 600; font-size: calc(16px * var(--a11y-text-scale, 1)); }
.module-cta .mc-s { font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-2); }

/* ============================================================
   BLOG
   ============================================================ */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.post-card { border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: transform .2s, border-color .2s; }
.post-card:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.post-card .thumb { width: 100%; height: 188px; display: block; }
.post-card image-slot { width: 100%; height: 188px; display: block; }
.post-card .pc-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.pc-meta { display: flex; align-items: center; gap: 10px; font-size: calc(12px * var(--a11y-text-scale, 1)); margin-bottom: 13px; }
.pc-cat { font-weight: 700; color: var(--accent-2); background: var(--accent-soft); padding: 4px 11px; border-radius: 100px; }
.pc-date { color: var(--text-3); }
.post-card h3 { font-size: calc(18px * var(--a11y-text-scale, 1)); line-height: 1.28; margin-bottom: 10px; }
.post-card p { font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); flex: 1; }
.pc-link { margin-top: 16px; font-weight: 600; color: var(--accent); font-size: calc(14px * var(--a11y-text-scale, 1)); display: inline-flex; align-items: center; gap: 6px; }
.post-card.feat { grid-column: 1 / -1; flex-direction: row; }
.post-card.feat .thumb, .post-card.feat image-slot { width: 48%; height: auto; min-height: 320px; }
.post-card.feat .pc-body { padding: clamp(28px, 3vw, 44px); justify-content: center; }
.post-card.feat h3 { font-size: calc(clamp(22px, 2.6vw, 30px) * var(--a11y-text-scale, 1)); }
.post-card.feat p { flex: none; font-size: calc(15.5px * var(--a11y-text-scale, 1)); margin-top: 4px; }

/* ============================================================
   ARTICLE
   ============================================================ */
.art-head { max-width: 1040px; margin-inline: auto; }
.art-head h1 { font-size: calc(clamp(30px, 4.2vw, 46px) * var(--a11y-text-scale, 1)); margin: 16px 0 18px; }
.art-head .lead { font-size: calc(19px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.6; }
.article-hero { max-width: 1040px; margin: clamp(28px, 4vw, 44px) auto 0; }
.article-hero image-slot, .article-hero .thumb { width: 100%; height: clamp(240px, 38vw, 440px); display: block; border-radius: var(--radius); }
.prose { max-width: 1040px; margin-inline: auto; font-size: calc(17px * var(--a11y-text-scale, 1)); line-height: 1.75; color: var(--text-2); }
.prose h2 { font-family: var(--font-display); font-size: calc(clamp(23px, 3vw, 31px) * var(--a11y-text-scale, 1)); color: var(--text); margin: 42px 0 16px; letter-spacing: -0.02em; line-height: 1.2; }
.prose h3 { font-size: calc(20px * var(--a11y-text-scale, 1)); color: var(--text); margin: 30px 0 12px; }
.prose p { margin: 0 0 18px; }
.prose ul, .prose ol { margin: 0 0 20px; padding-left: 22px; }
.prose li { margin-bottom: 9px; }
.prose strong { color: var(--text); font-weight: 700; }
.prose a:not(.btn) { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.prose a.btn { text-decoration: none; }
.prose a.btn-primary { color: #fff; }
.prose table { width: 100%; border-collapse: collapse; margin: 6px 0 24px; font-size: calc(14.5px * var(--a11y-text-scale, 1)); }
.prose thead th { text-align: left; background: var(--surface-2); padding: 12px 14px; font-family: var(--font-display); font-weight: 600; font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text); border: 1px solid var(--border); }
.prose td { padding: 11px 14px; border: 1px solid var(--border); color: var(--text-2); vertical-align: top; }
.prose tbody tr:nth-child(even), .prose tbody tr:nth-child(even) { background: var(--surface-2); }
.prose-cta { border: 1px solid var(--accent-glow); background: linear-gradient(150deg, var(--accent-soft), var(--surface) 70%); border-radius: var(--radius); padding: 26px 28px; margin: 30px 0; }
.prose-cta h4 { font-family: var(--font-display); font-size: calc(19px * var(--a11y-text-scale, 1)); margin: 0 0 8px; color: var(--text); }
.prose-cta p { margin: 0 0 16px; font-size: calc(15px * var(--a11y-text-scale, 1)); }
.share { display: flex; gap: 10px; align-items: center; margin: 38px auto; max-width: 1040px; }
.share .lbl { font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-right: 4px; }
.share a { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--border); display: grid; place-items: center; color: var(--text-2); transition: all .2s; }
.share a:hover { border-color: var(--accent); color: var(--accent); }

/* ============================================================
   CONTACT
   ============================================================ */
.contact-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: clamp(26px, 4vw, 48px); align-items: start; }
.form-card { border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius); padding: clamp(26px, 3vw, 36px); box-shadow: var(--shadow); }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: calc(13.5px * var(--a11y-text-scale, 1)); font-weight: 600; margin-bottom: 7px; color: var(--text); }
/* WCAG: ramki pol formularza kontaktowego - --field-border zapewnia >=3:1 */
.field input, .field textarea, .field select { width: 100%; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--field-border); background: var(--bg); color: var(--text); font-family: inherit; font-size: calc(15px * var(--a11y-text-scale, 1)); transition: border-color .2s, box-shadow .2s; }
.field input::placeholder, .field textarea::placeholder { color: var(--text-3); }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.field textarea { min-height: 130px; resize: vertical; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.contact-info { display: grid; gap: 14px; }
.info-card { border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius); padding: 22px; display: flex; gap: 14px; align-items: flex-start; }
.info-card .ic { width: 42px; height: 42px; border-radius: 11px; background: var(--accent-soft); color: var(--accent-2); display: grid; place-items: center; flex: none; }
.info-card .t { font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); margin-bottom: 3px; }
.info-card .d { font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.5; }
.info-card .d a { color: var(--accent); }

/* Skip-link "Przejdz do tresci" - kontrast (WCAG).
   W index.html skip-link ma tlo var(--accent) i bialy tekst. W motywie
   dim/dark var(--accent) to jasny niebieski (#6f9bff) -> bialy na nim ma
   ~2.6:1 (za malo). Wymuszamy stale ciemne tlo (granat) z bialym tekstem
   we WSZYSTKICH motywach -> >=4.5:1. Selektor a.skip-link bije inline
   <style> w naglowku (wyzsza swoistosc niz sama klasa). */
a.skip-link { background-color: #0B2A6B; color: #fff; }
a.skip-link:focus { outline: 3px solid var(--accent-2); outline-offset: 2px; }

/* ============================================================
   ACCESSIBILITY - launcher, panel, funkcje
   ============================================================ */
.a11y-launch { position: fixed; left: 18px; bottom: 18px; width: 52px; height: 52px; border-radius: 50%; background: var(--grad); color: #fff; border: 0; display: grid; place-items: center; box-shadow: var(--shadow); cursor: pointer; z-index: 2147483600; transition: transform .15s, box-shadow .2s; }
.a11y-launch:hover { transform: translateY(-2px); }
/* Mobile: przycisk wciaz klikalny (46px > 44px WCAG) i blizej rogu,
   zeby nie nachodzil na etykiety pol formularza w lewej kolumnie. */
@media (max-width: 768px) {
  .a11y-launch { width: 46px; height: 46px; left: 12px; bottom: 12px; }
  .a11y-panel { left: 12px; bottom: 66px; width: min(300px, calc(100vw - 24px)); }
  /* iOS AUTO-ZOOM: pola < 16px powieksza Safari przy fokusie - na mobile
     wszystkie fokusowalne pola formularza >= 16px. (Regula dla .sc-inputrow textarea
     jest NIZEJ w pliku, po bazowej definicji - tu byla martwa, bo bazowa regula
     z linii ~1398 ja nadpisywala kolejnoscia przy rownej sile selektora.) */
  .field input, .field textarea, .field select { font-size: calc(16px * var(--a11y-text-scale, 1)); }
}
/* Czat FAB otwarty na mobile (widget.js dodaje mpa-lock na body): ikona i panel
   dostepnosci schodza z drogi - ich z-index (2147483600) jest WYZSZY niz panel
   czatu (2147483000), wiec bez tej reguly plywaja NAD oknem rozmowy i zaslaniaja
   pole pisania. Po zamknieciu czatu wracaja (klasa znika). */
body.mpa-lock .a11y-launch, body.mpa-lock .a11y-panel { display: none; }
.a11y-panel { position: fixed; left: 18px; bottom: 82px; width: 300px; max-height: calc(100vh - 116px); overflow-y: auto; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 18px; box-shadow: var(--shadow-lg); z-index: 2147483601; padding: 18px; display: none; font-family: var(--font-body); }
.a11y-panel.open { display: block; }
.a11y-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.a11y-head h3 { font-family: var(--font-display); font-size: 18px; color: var(--text); margin: 0; letter-spacing: -0.01em; }
.a11y-x { width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text-2); display: grid; place-items: center; cursor: pointer; font-size: 15px; }
.a11y-x:hover { color: var(--text); border-color: var(--border-strong); }
.a11y-sec { margin-top: 16px; }
.a11y-sec .a11y-lbl { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); margin-bottom: 9px; }
.a11y-size { display: flex; gap: 8px; }
.a11y-size button { flex: 1; padding: 11px 0; border-radius: 10px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text); font-weight: 700; cursor: pointer; font-family: var(--font-display); font-size: 15px; transition: border-color .15s; }
.a11y-size button:hover { border-color: var(--border-strong); }
.a11y-btn { width: 100%; display: flex; align-items: center; justify-content: center; gap: 9px; padding: 12px; border-radius: 11px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text); font-weight: 600; font-size: 14.5px; cursor: pointer; font-family: var(--font-body); transition: border-color .15s, background .15s; }
.a11y-btn:hover { border-color: var(--border-strong); }
.a11y-btn.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
.a11y-btn svg { flex: none; }
.a11y-reset { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--border); }

/* functional toggles (działają we wszystkich motywach przez zmienne) */
html.a11y-no-motion *, html.a11y-no-motion *::before, html.a11y-no-motion *::after { animation-duration: .001s !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .001s !important; transition-delay: 0s !important; }
html.a11y-no-motion { scroll-behavior: auto !important; }
html.a11y-underline a:not(.btn):not(.a11y-launch):not(.brand) { text-decoration: underline !important; text-underline-offset: 2px; }
html.a11y-readable { --font-display: Verdana, Tahoma, system-ui, sans-serif !important; --font-body: Verdana, Tahoma, system-ui, sans-serif !important; }
html.a11y-readable body { letter-spacing: 0.01em; line-height: 1.7; }
html.a11y-contrast,
html.a11y-contrast[data-theme] { --text-2: var(--text); --text-3: var(--text); --border: var(--border-strong); }
html.a11y-contrast a:not(.btn):focus-visible, html.a11y-contrast button:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
html.a11y-cursor, html.a11y-cursor * { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 24 24'%3E%3Cpath d='M4 2l0 17 4.5-4.2 2.7 5.8 2.6-1.1-2.6-5.6 6.3 0z' fill='white' stroke='black' stroke-width='1.3' stroke-linejoin='round'/%3E%3C/svg%3E") 3 2, auto !important; }

/* ============================================================
   SUPPORT CONSOLE (kontakt AI-first)
   ============================================================ */
.sc-wrap { max-width: 1040px; margin-inline: auto; }
.sc { position: relative; display: grid; grid-template-columns: 1fr; grid-template-rows: auto auto; height: auto; border: 0; border-radius: var(--radius); background: transparent; overflow: visible; }
/* layout sekcyjny zamiast okna czatu: zakładki na górze, treść pod spodem */
.sc-wrap .sc-rail { flex-direction: row; align-items: center; justify-content: flex-start; gap: 6px; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 0 0 14px; }
.sc-wrap .sc-rail .sc-brandrow, .sc-wrap .sc-rail .sc-spacer { display: none; }
.sc-wrap .sc-rail .sc-nav { width: auto; white-space: nowrap; flex: none; }
/* STABILNY rozmiar okna konsoli: min-height (nie height) trzyma jeden rozmiar dla czatu
   i kreatora, wiec przelaczanie Napisz/Baza/Kreator <-> czat NIE powoduje skoku ani zwezenia
   (czat ma TEN SAM rozmiar co formularz). min-height pozwala tez wysokiemu formularzowi B2B
   urosnac do tresci zamiast byc ucinanym. overflow:visible (nie hidden) jest kluczowe: bez
   niego sciezka gridowa .sc nie rosnie pod rozwiniety formularz i nastepna sekcja (promo
   "Testuj za darmo") nachodzi na pola - bug mobile. Czat/Baza wypelniaja okno i przewijaja
   tresc wewnatrz (regula .sc-view ponizej trzyma height:100% + overflow w body). */
.sc-wrap .sc-main { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); margin-top: 4px; overflow: visible; min-height: clamp(560px, 72vh, 760px); }
/* aktywny widok wypelnia okno i jest kolumna flex: naglowek staly, body przewija sie */
.sc-wrap .sc-view:not([hidden]) { display: flex; flex-direction: column; height: 100%; min-height: 0; }
/* nagłówek widoku oraz dolny pasek pisania przyklejone (nie przewijaja sie z trescia) */
.sc-wrap .sc-head { flex: none; }
.sc-wrap .sc-composer { flex: none; }
/* tresc przewija sie wewnatrz okna o stalej wysokosci (nie rozpycha panelu) */
.sc-wrap .sc-view:not([hidden]) .sc-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.sc-wrap .sc-ovbody { overflow-y: auto; }
/* Baza wiedzy: naglowek widoku + wyszukiwarka przyklejone do gory, lista przewija sie pod nimi */
.sc-wrap #view-kb .sc-search { position: sticky; top: 0; z-index: 2; background: var(--surface); padding: 4px 0 16px; margin-top: -4px; }

/* rail */
.sc-rail { background: var(--bg-2); border-right: 1px solid var(--border); padding: 16px 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.sc-brandrow { display: flex; align-items: center; gap: 11px; padding: 4px 8px 14px; }
.sc-aiava { width: 40px; height: 40px; border-radius: 12px; background: var(--grad); display: grid; place-items: center; color: #fff; flex: none; box-shadow: inset 0 1px 0 rgba(255,255,255,0.28), 0 6px 16px -6px var(--accent-glow); }
.sc-aiava svg { width: 54%; height: 54%; }
.sc-brandrow .nm { font-family: var(--font-display); font-weight: 600; font-size: calc(14.5px * var(--a11y-text-scale, 1)); line-height: 1.1; }
.sc-brandrow .st { font-size: calc(11.5px * var(--a11y-text-scale, 1)); color: var(--success); display: flex; align-items: center; gap: 5px; }
.sc-brandrow .st::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 3px var(--success-soft); }
.sc-nav { display: flex; align-items: center; gap: 11px; padding: 11px 12px; border-radius: 11px; border: 0; background: transparent; color: var(--text-2); font-weight: 600; font-size: calc(14px * var(--a11y-text-scale, 1)); text-align: left; cursor: pointer; font-family: var(--font-body); transition: background .15s, color .15s; width: 100%; white-space: nowrap; }
.sc-nav svg { flex: none; }
/* ukryta zakladka paska konsoli (np. #tab-tickets [hidden]) ma realnie zniknac z ekranu i kolejnosci Tab - regula .sc-nav z display:flex nadpisywala domyslne [hidden]{display:none} */
.sc-rail .sc-nav[hidden], .sc-rail [role="tab"][hidden] { display: none !important; }
.sc-nav:hover { background: var(--hover); color: var(--text); }
.sc-nav.on { background: var(--accent-soft); color: var(--accent); }
.sc-nav .badge { margin-left: auto; font-size: calc(11px * var(--a11y-text-scale, 1)); font-weight: 700; background: var(--accent); color: #fff; border-radius: 100px; padding: 1px 7px; }
.sc-spacer { flex: 1; }

/* main */
.sc-main { display: flex; flex-direction: column; min-width: 0; position: relative; }
.sc-head { padding: 15px 20px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; background: var(--surface); }
.sc-head .ti { font-family: var(--font-display); font-weight: 600; font-size: calc(16px * var(--a11y-text-scale, 1)); }
.sc-head .sub { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.sc-head .actions { margin-left: auto; display: flex; gap: 6px; }
.sc-iconbtn { width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text-2); display: grid; place-items: center; cursor: pointer; transition: color .15s, border-color .15s; }
.sc-iconbtn:hover { color: var(--text); border-color: var(--border-strong); }
.sc-iconbtn:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.sc-iconbtn[aria-expanded="true"] { color: var(--accent); border-color: var(--accent); }

/* ============================================================
   Menu „trzy kropki" (kebab) w naglowku czatu
   ============================================================ */
.sc-head-actions { margin-left: auto; position: relative; flex: none; }
.sc-menu { position: absolute; top: calc(100% + 8px); right: 0; z-index: 8; min-width: 230px; padding: 6px; list-style: none; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 13px; box-shadow: var(--shadow-lg); }
.sc-menu[hidden] { display: none; }
@media (prefers-reduced-motion: no-preference) { .sc-menu { animation: scMenuIn .14s ease; } }
@keyframes scMenuIn { from { transform: translateY(-6px); opacity: 0; } to { transform: none; opacity: 1; } }
.sc-menu-item { width: 100%; display: flex; align-items: center; gap: 11px; padding: 10px 12px; border: 0; border-radius: 9px; background: none; color: var(--text); font-family: 'Manrope', system-ui, sans-serif; font-size: calc(14px * var(--a11y-text-scale, 1)); font-weight: 600; text-align: left; cursor: pointer; transition: background .12s, color .12s; }
.sc-menu-item .ic { display: grid; place-items: center; color: var(--text-3); flex: none; transition: color .12s; }
.sc-menu-item:hover, .sc-menu-item:focus-visible { outline: none; background: var(--hover); }
.sc-menu-item:hover .ic, .sc-menu-item:focus-visible .ic { color: var(--accent); }
.sc-menu-item.sc-menu-accent { color: var(--accent); }
.sc-menu-item.sc-menu-accent .ic { color: var(--accent); }
.sc-menu-item.sc-menu-danger { color: #DC2626; }
.sc-menu-item.sc-menu-danger .ic { color: #DC2626; }
.sc-menu-item.sc-menu-danger:hover, .sc-menu-item.sc-menu-danger:focus-visible { background: color-mix(in oklab, #DC2626 12%, transparent); }
:root[data-theme="dark"] .sc-menu-item.sc-menu-danger, :root[data-theme="dim"] .sc-menu-item.sc-menu-danger { color: #F87171; }
:root[data-theme="dark"] .sc-menu-item.sc-menu-danger .ic, :root[data-theme="dim"] .sc-menu-item.sc-menu-danger .ic { color: #F87171; }

/* lista poprzednich rozmow (overlay) */
.sc-histlist { display: flex; flex-direction: column; gap: 8px; }
.sc-histitem { display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); color: var(--text); text-align: left; cursor: pointer; font-family: 'Manrope', system-ui, sans-serif; transition: border-color .15s; }
.sc-histitem:hover { border-color: var(--accent); }
.sc-histitem:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.sc-histitem .hi-date { font-size: calc(11.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.sc-histitem .hi-prev { font-size: calc(14px * var(--a11y-text-scale, 1)); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* toast (potwierdzenie akcji menu) */
.sc-toast { position: absolute; left: 50%; bottom: 18px; transform: translate(-50%, 12px); z-index: 9; max-width: calc(100% - 32px); padding: 10px 16px; border-radius: 100px; background: var(--text); color: var(--surface); font-size: calc(13px * var(--a11y-text-scale, 1)); font-weight: 600; box-shadow: var(--shadow-lg); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; }
.sc-toast.on { opacity: 1; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { .sc-toast { transition: opacity .2s; } }

.sc-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 20px; }

/* chat */
.sc-msgs { display: flex; flex-direction: column; gap: 12px; }
.sc-msg { max-width: 86%; padding: 11px 14px; border-radius: 15px; font-size: calc(14.5px * var(--a11y-text-scale, 1)); line-height: 1.5; white-space: pre-wrap; }
.sc-msg.user { margin-left: auto; background: var(--grad); color: #fff; border-bottom-right-radius: 5px; }
.sc-msg.bot { background: var(--surface-2); border: 1px solid var(--border); border-bottom-left-radius: 5px; }
.sc-msg.bot a { color: var(--accent); font-weight: 600; }
.sc-msg .imgthumb { display: block; max-width: 240px; border-radius: 10px; border: 1px solid var(--border-strong); margin-top: 4px; }
.sc-msg.sys { align-self: center; background: var(--fill-1); border: 1px dashed var(--border-strong); color: var(--text-3); font-size: calc(12.5px * var(--a11y-text-scale, 1)); padding: 9px 15px; border-radius: 16px; }
.sc-typing { display: inline-flex; gap: 4px; padding: 6px 2px; }
.sc-typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); animation: blink 1.2s infinite; }
.sc-typing span:nth-child(2) { animation-delay: .2s; }
.sc-typing span:nth-child(3) { animation-delay: .4s; }
.sc-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.sc-chip { padding: 8px 13px; border-radius: 100px; border: 1px solid var(--border-strong); background: var(--fill-1); color: var(--text); font-size: calc(13px * var(--a11y-text-scale, 1)); font-weight: 600; cursor: pointer; font-family: var(--font-body); transition: border-color .15s, background .15s; }
.sc-chip:hover { border-color: var(--accent); color: var(--accent); }

/* composer */
.sc-composer { border-top: 1px solid var(--border); padding: 12px; background: var(--surface); }
.sc-tools { display: flex; gap: 6px; margin-bottom: 9px; flex-wrap: wrap; }
.sc-tool { display: inline-flex; align-items: center; gap: 7px; padding: 7px 11px; border-radius: 9px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text-2); font-size: calc(12.5px * var(--a11y-text-scale, 1)); font-weight: 600; cursor: pointer; font-family: var(--font-body); transition: all .15s; }
.sc-tool:hover { border-color: var(--accent); color: var(--accent); }
.sc-tool svg { flex: none; }
.sc-inputrow { display: flex; gap: 10px; align-items: flex-end; }
.sc-inputrow textarea { flex: 1; resize: none; min-height: 44px; max-height: 120px; padding: 11px 14px; border-radius: 12px; border: 1px solid var(--border-strong); background: var(--bg); color: var(--text); font-family: inherit; font-size: calc(14.5px * var(--a11y-text-scale, 1)); line-height: 1.4; }
.sc-inputrow textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
/* iOS AUTO-ZOOM (KOLEJNOSC KRYTYCZNA): ta regula MUSI stac PO bazowej definicji
   .sc-inputrow textarea powyzej - przy rownej sile selektora wygrywa pozniejsza.
   Pierwsza proba (blok @media wyzej w pliku) byla MARTWA i Safari dalej zoomowal
   strone przy kazdym fokusie pola czatu (Adam, iPhone 2026-07-04). */
@media (max-width: 768px) {
  .sc-inputrow textarea { font-size: calc(16px * var(--a11y-text-scale, 1)); }
}
.sc-send { width: 44px; height: 44px; border-radius: 12px; background: var(--grad); border: 0; color: #fff; display: grid; place-items: center; cursor: pointer; flex: none; box-shadow: 0 8px 20px -8px var(--accent-glow); }
.sc-send:disabled { opacity: .5; cursor: default; box-shadow: none; }

/* ============================================================
   Wlasny rozwijany wybor (combobox) - temat zgloszenia (intake)
   Styl strony: ciemne/jasne tlo, akcent, wlasna strzalka. Dostepnosc w JS.
   ============================================================ */
.sc-cs-label { display: block; font-size: calc(13.5px * var(--a11y-text-scale, 1)); font-weight: 600; margin-bottom: 7px; color: var(--text); }
.sc-combo { position: relative; }
.sc-combo-btn { width: 100%; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--field-border); background: var(--bg); color: var(--text); font-family: inherit; font-size: calc(15px * var(--a11y-text-scale, 1)); text-align: left; cursor: pointer; transition: border-color .2s, box-shadow .2s; }
.sc-combo-btn:hover { border-color: var(--border-strong); }
.sc-combo-btn[aria-expanded="true"] { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.sc-combo-val { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-combo-arrow { display: grid; place-items: center; color: var(--text-3); flex: none; transition: transform .2s, color .2s; }
.sc-combo-btn[aria-expanded="true"] .sc-combo-arrow { transform: rotate(180deg); color: var(--accent); }
.sc-combo-list { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 20; margin: 0; padding: 6px; list-style: none; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 12px; box-shadow: var(--shadow-lg); max-height: 280px; overflow-y: auto; }
.sc-combo-list[hidden] { display: none; }
.sc-combo-list [role="option"] { padding: 10px 12px; border-radius: 8px; font-size: calc(14.5px * var(--a11y-text-scale, 1)); color: var(--text); cursor: pointer; line-height: 1.3; }
.sc-combo-list [role="option"].is-active { background: var(--hover); }
.sc-combo-list [role="option"][aria-selected="true"] { color: var(--accent); font-weight: 600; }
.sc-combo-list [role="option"][aria-selected="true"].is-active { background: var(--accent-soft); }

/* knowledge base */
.sc-search { position: relative; margin-bottom: 16px; }
.sc-search input { width: 100%; padding: 12px 14px 12px 42px; border-radius: 11px; border: 1px solid var(--border-strong); background: var(--bg); color: var(--text); font-size: calc(14.5px * var(--a11y-text-scale, 1)); font-family: inherit; }
.sc-search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.sc-search .si { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-3); display: grid; }
.sc-kbcat { font-size: calc(11px * var(--a11y-text-scale, 1)); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-2); margin: 18px 0 8px; }
.sc-kbcat:first-child { margin-top: 0; }
.sc-kb { border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); margin-bottom: 9px; overflow: hidden; }
.sc-kb summary { cursor: pointer; list-style: none; padding: 13px 15px; font-weight: 600; font-size: calc(14px * var(--a11y-text-scale, 1)); display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.sc-kb summary::-webkit-details-marker { display: none; }
.sc-kb[open] summary { color: var(--accent); }
.sc-kb .ans { padding: 0 15px 14px; font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.55; }
.sc-kb .ans .ask { margin-top: 10px; font-size: calc(12.5px * var(--a11y-text-scale, 1)); font-weight: 600; color: var(--accent); background: none; border: 0; padding: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }

/* kreator */
.sc-kre-q { font-family: var(--font-display); font-weight: 600; font-size: calc(18px * var(--a11y-text-scale, 1)); margin-bottom: 4px; }
.sc-kre-sub { font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-bottom: 18px; }
.sc-opts { display: grid; gap: 10px; }
.sc-opt { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text); font-size: calc(14.5px * var(--a11y-text-scale, 1)); font-weight: 600; cursor: pointer; text-align: left; font-family: var(--font-body); transition: border-color .15s, transform .12s; }
.sc-opt:hover { border-color: var(--accent); transform: translateX(3px); }
.sc-opt .ic { width: 34px; height: 34px; border-radius: 9px; background: var(--accent-soft); color: var(--accent-2); display: grid; place-items: center; flex: none; }
.sc-opt .arr { margin-left: auto; color: var(--text-3); }
.sc-kre-path { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-bottom: 16px; }
.sc-kre-path button { background: none; border: 0; color: var(--accent); cursor: pointer; font-weight: 600; padding: 0; font-size: calc(12.5px * var(--a11y-text-scale, 1)); }
.sc-kre-ans { border: 1px solid var(--border); border-radius: 14px; background: var(--surface-2); padding: 18px; }
.sc-kre-ans p { font-size: calc(14.5px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.6; margin: 0 0 14px; }
.sc-kre-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* tickets */
.sc-ticket { display: flex; align-items: center; gap: 14px; padding: 15px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); margin-bottom: 10px; cursor: pointer; transition: border-color .15s; }
.sc-ticket:hover { border-color: var(--border-strong); }
.sc-ticket .tk-main { min-width: 0; flex: 1; }
.sc-ticket .tk-id { font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--text-3); font-family: var(--font-display); }
.sc-ticket .tk-sub { font-weight: 600; font-size: calc(14.5px * var(--a11y-text-scale, 1)); margin: 2px 0; }
.sc-ticket .tk-meta { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.sc-status { font-size: calc(11.5px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 5px 11px; border-radius: 100px; white-space: nowrap; }
.sc-status.open { background: var(--accent-soft); color: var(--accent); }
.sc-status.prog { background: color-mix(in oklab, var(--warn) 16%, transparent); color: var(--warn); }
.sc-status.done { background: var(--success-soft); color: var(--success); }
.sc-divider { display: flex; align-items: center; gap: 12px; color: var(--text-3); font-size: calc(12.5px * var(--a11y-text-scale, 1)); margin: 20px 0; }
.sc-link { background: none; border: 0; color: var(--accent); font-weight: 600; cursor: pointer; padding: 0; font-family: var(--font-body); font-size: inherit; }
.sc-tkfilter { display: flex; gap: 10px; margin-bottom: 14px; }
.sc-tkfilter select { height: 38px; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--bg); color: var(--text); font-family: inherit; font-size: calc(14px * var(--a11y-text-scale, 1)); padding: 0 10px; }
.sc-empty { text-align: center; color: var(--text-3); padding: 36px 10px; display: grid; justify-items: center; gap: 12px; }
.sc-reg-h { font-family: var(--font-display); font-weight: 700; font-size: calc(14px * var(--a11y-text-scale, 1)); margin: 14px 0 8px; }
.sc-reg-h:first-of-type { margin-top: 4px; }
.sc-divider::before, .sc-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.sc-card { border: 1px solid var(--border); border-radius: 14px; background: var(--surface-2); padding: 18px; }
.sc-card h4 { font-size: calc(15px * var(--a11y-text-scale, 1)); margin: 0 0 4px; }
.sc-card p.note { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); margin: 0 0 14px; }

/* overlay (form / detail inside window) */
.sc-overlay { position: absolute; inset: 0; background: var(--surface); z-index: 6; display: flex; flex-direction: column; animation: scSlide .22s ease; }
@keyframes scSlide { from { transform: translateX(16px); opacity: 0; } to { transform: none; opacity: 1; } }
.sc-ovhead { padding: 15px 20px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; }
.sc-ovhead .ti { font-family: var(--font-display); font-weight: 600; font-size: calc(16px * var(--a11y-text-scale, 1)); }
.sc-ovhead .back { width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text-2); display: grid; place-items: center; cursor: pointer; }
.sc-ovbody { flex: 1; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; padding: 20px; }

/* annotate modal */
.an-modal { position: fixed; inset: 0; background: rgba(0,0,0,0.62); z-index: 2147483640; display: grid; place-items: center; padding: 20px; }
.an-card { background: var(--surface); border: 1px solid var(--border-strong); border-radius: 16px; width: min(940px, 95vw); max-height: 92vh; display: flex; flex-direction: column; overflow: hidden; box-shadow: var(--shadow-lg); }
.an-head { padding: 14px 18px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; }
.an-head .ti { font-family: var(--font-display); font-weight: 600; font-size: calc(16px * var(--a11y-text-scale, 1)); }
.an-toolbar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--border); background: var(--bg-2); flex-wrap: wrap; }
.an-tool { width: 36px; height: 36px; border-radius: 9px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); display: grid; place-items: center; cursor: pointer; }
.an-tool:hover { color: var(--text); border-color: var(--border-strong); }
.an-tool.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.an-sep { width: 1px; align-self: stretch; background: var(--border); margin: 2px 4px; }
.an-color { width: 26px; height: 26px; border-radius: 7px; border: 2px solid var(--border-strong); cursor: pointer; padding: 0; }
.an-color.on { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); }
.an-stage { flex: 1; overflow: auto; background: repeating-conic-gradient(var(--surface-2) 0% 25%, var(--bg-2) 0% 50%) 50% / 22px 22px; display: grid; place-items: center; padding: 18px; }
.an-stage canvas { max-width: 100%; box-shadow: var(--shadow); border-radius: 6px; cursor: crosshair; touch-action: none; }
.an-foot { padding: 12px 16px; border-top: 1px solid var(--border); display: flex; gap: 10px; justify-content: flex-end; align-items: center; }
.an-empty { text-align: center; color: var(--text-3); padding: 40px; }
.an-empty .row { display: flex; gap: 10px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }

/* intake (formularz startowy) + routing */
.sc-intake-hint { display: flex; gap: 11px; align-items: flex-start; padding: 13px 15px; border-radius: 12px; background: var(--accent-soft); border: 1px solid var(--accent-glow); margin-bottom: 18px; font-size: calc(13px * var(--a11y-text-scale, 1)); line-height: 1.5; color: var(--text-2); }
.sc-intake-hint .ic { width: 32px; height: 32px; border-radius: 10px; background: var(--grad); color: #fff; display: grid; place-items: center; flex: none; box-shadow: inset 0 1px 0 rgba(255,255,255,0.28), 0 5px 14px -6px var(--accent-glow); }
.sc-intake-hint .ic svg { width: 54%; height: 54%; }
.sc-intake-img { display: flex; align-items: center; gap: 11px; padding: 9px 11px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2); margin-bottom: 14px; }
.sc-intake-img img { width: 52px; height: 38px; object-fit: cover; border-radius: 7px; border: 1px solid var(--border-strong); flex: none; }
.sc-intake-img span { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-2); font-weight: 600; }
.sc-intake-img button { margin-left: auto; width: 26px; height: 26px; border-radius: 7px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text-3); cursor: pointer; }
.sc-intake-alt { display: flex; align-items: center; gap: 10px; justify-content: center; margin-top: 18px; font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); flex-wrap: wrap; }
.sc-intake-alt button { background: none; border: 0; color: var(--accent); font-weight: 600; cursor: pointer; font-size: calc(13px * var(--a11y-text-scale, 1)); padding: 0; font-family: var(--font-body); }
.sc-intake-alt .sep { opacity: .5; }
.sc-route { margin-top: 11px; border: 1px solid var(--accent-glow); border-radius: 12px; background: var(--surface); padding: 12px 13px; }
.sc-route .rh { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--accent); }
.sc-route .rh .ic { color: var(--accent); display: grid; }
.sc-route .rd { font-family: var(--font-display); font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); margin: 5px 0 4px; color: var(--text); }
.sc-route .rm { font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--text-3); line-height: 1.5; }
.sc-route .rm b { color: var(--text-2); }

/* ============================================================
   ESKALACJA "WARIANT A" - karta podsumowania + panel edycji w czacie
   Plynne przekazanie sprawy konsultantowi BEZ formularza ticketa.
   Karta dziedziczy ramke z .sc-route; ponizej tylko dodatki.
   ============================================================ */
/* dymek bota z karta/panelem eskalacji - szerszy, zeby zmiescic formularz */
.sc-msg.bot.is-wide { max-width: 100%; width: 100%; }
.sc-esc { display: block; }
/* karta podsumowania (podglad ulozony przez asystenta) */
.sc-esc-card .sc-esc-preview {
  margin-top: 8px;
  font-size: calc(13px * var(--a11y-text-scale, 1));
  line-height: 1.55;
  color: var(--text-2);
  white-space: normal;
}
.sc-esc-cardfoot { margin-top: 12px; }
.sc-esc-cardfoot .btn { width: 100%; }
/* potwierdzenie po wyslaniu (zielony akcent zamiast niebieskiego) */
.sc-route.sc-esc-sent { border-color: color-mix(in oklab, var(--success) 38%, transparent); }
.sc-route.sc-esc-sent .rh,
.sc-route.sc-esc-sent .rh .ic { color: var(--success); }

/* panel edycji (rozwijany pod karta) - dostepny, edytowalny */
.sc-esc-panel {
  margin-top: 11px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-2);
  padding: 14px;
}
.sc-esc-panel .field { margin-bottom: 14px; }
.sc-esc-panel .field:last-of-type { margin-bottom: 8px; }
.sc-esc-panel textarea { min-height: 140px; }
.sc-esc-hint {
  font-size: calc(12px * var(--a11y-text-scale, 1));
  line-height: 1.45;
  color: var(--text-3);
  margin: 0 0 8px;
}
.sc-esc-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.sc-esc-actions .btn { flex: 1 1 auto; }
/* przycisk wysylki zablokowany dopoki nie ma tokenu Turnstile */
.sc-esc-panel .btn[disabled] { opacity: .55; cursor: not-allowed; }

/* 360px: panel ma sie zmiescic bez przewijania w poziomie */
@media (max-width: 480px) {
  .sc-esc-actions { flex-direction: column; }
  .sc-esc-actions .btn { width: 100%; }
}

/* ============================================================
   APP MOCKUPS (accent-aware "screenshots")
   ============================================================ */
.mk { width: 100%; height: clamp(360px, 47vw, 560px); display: grid; grid-template-columns: 60px 1fr; background: var(--surface); color: var(--text); overflow: hidden; font-size: calc(12px * var(--a11y-text-scale, 1)); line-height: 1.35; }
.mk * { box-sizing: border-box; }
.mk-rail { background: var(--bg-2); border-right: 1px solid var(--border); display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 12px 0; }
.mk-rail .logo { width: 32px; height: 32px; border-radius: 9px; background: var(--grad); display: grid; place-items: center; color: #fff; font-family: var(--font-display); font-weight: 700; font-size: calc(12px * var(--a11y-text-scale, 1)); box-shadow: 0 6px 14px -6px var(--accent-glow); }
.mk-rail .ic { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; color: var(--text-3); }
.mk-rail .ic.on { background: var(--accent-soft); color: var(--accent); }
.mk-rail .sp { flex: 1; }
.mk-rail .av { width: 30px; height: 30px; border-radius: 50%; background: var(--grad); border: 0; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: calc(10px * var(--a11y-text-scale, 1)); color: #fff; }
.mk-main { display: flex; flex-direction: column; min-width: 0; }
.mk-main .mk-content { flex: 1; min-height: 0; }
.mk-main .mk-docbar { flex: none; }
.mk-top { height: 48px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; padding: 0 16px; flex: none; }
.mk-top .ttl { font-family: var(--font-display); font-weight: 600; font-size: calc(15px * var(--a11y-text-scale, 1)); }
.mk-top .sub { color: var(--text-3); font-size: calc(11px * var(--a11y-text-scale, 1)); }
.mk-search { margin-left: auto; width: clamp(120px, 22%, 220px); height: 30px; border-radius: 8px; background: var(--fill-1); border: 1px solid var(--border); display: flex; align-items: center; padding: 0 10px; color: var(--text-3); gap: 7px; font-size: calc(11px * var(--a11y-text-scale, 1)); }
.mk-btn { height: 30px; border-radius: 8px; padding: 0 13px; background: var(--grad); color: #fff; display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: calc(11.5px * var(--a11y-text-scale, 1)); box-shadow: 0 6px 14px -7px var(--accent-glow); white-space: nowrap; }
.mk-btn.ghost { background: var(--fill-1); color: var(--text-2); border: 1px solid var(--border); box-shadow: none; }
.mk-content { flex: 1; padding: 16px; overflow: hidden; min-height: 0; }

/* dashboard (układ jak mpFirma) */
.mk-dash { display: flex; flex-direction: column; gap: 10px; }
.mk-actions { display: flex; gap: 7px; }
.mk-actions .mk-btn { flex: 1; justify-content: center; height: 28px; font-size: calc(10.5px * var(--a11y-text-scale, 1)); padding: 0 8px; }
.mk-dash-cols { display: grid; grid-template-columns: 0.82fr 1.18fr; gap: 12px; flex: 1; min-height: 0; }
.mk-dash-left { display: flex; flex-direction: column; gap: 8px; min-height: 0; overflow: hidden; }
.mk-dash-right { display: flex; flex-direction: column; min-height: 0; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); padding: 12px; }

.mk-ai-card { border: 1px solid var(--accent-glow); border-radius: 11px; overflow: hidden; background: var(--surface-2); flex: none; }
.mk-ai-card .hd { background: var(--grad); color: #fff; padding: 8px 11px; display: flex; align-items: center; gap: 7px; font-weight: 700; font-size: calc(11.5px * var(--a11y-text-scale, 1)); white-space: nowrap; }
.mk-ai-card .hd .nm { margin-right: auto; white-space: nowrap; }
.mk-ai-card .hd .q { font-size: calc(9px * var(--a11y-text-scale, 1)); font-weight: 600; background: rgba(255,255,255,.22); width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; white-space: nowrap; flex: none; }
.mk-ai-card .bd { padding: 9px 11px; font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.45; }
.mk-ai-card .bd b { color: var(--text); }

.mk-kpi-list { display: flex; flex-direction: column; gap: 7px; min-height: 0; overflow: hidden; flex: 1; justify-content: space-between; }
.mk-krow { display: flex; align-items: center; gap: 9px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); padding: 8px 10px; flex: none; }
.mk-krow .info { min-width: 0; flex: 1; }
.mk-krow .info .l { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-krow .info .v { font-family: var(--font-display); font-weight: 700; font-size: calc(13px * var(--a11y-text-scale, 1)); letter-spacing: -0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-krow .info .ksub { font-size: calc(8.5px * var(--a11y-text-scale, 1)); color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.mk-krow .chg { font-size: calc(9px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 2px 7px; border-radius: 100px; white-space: nowrap; flex: none; }
.mk-krow .chg.up { color: var(--success); background: var(--success-soft); }
.mk-krow .chg.down { color: var(--warn); background: color-mix(in oklab, var(--warn) 15%, transparent); }
.mk-krow .csub { font-size: calc(8.5px * var(--a11y-text-scale, 1)); color: var(--text-3); white-space: nowrap; }
.mk-krow .circ { margin-left: auto; width: 30px; height: 30px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; flex: none; box-shadow: 0 5px 12px -6px var(--accent-glow); }

.mk-tabs { display: flex; gap: 13px; border-bottom: 1px solid var(--border); margin-bottom: 9px; }
.mk-tabs span { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--text-3); padding-bottom: 7px; white-space: nowrap; }
.mk-tabs span.on { color: var(--accent); border-bottom: 2px solid var(--accent); font-weight: 700; }
.mk-yoy-h { font-family: var(--font-display); font-weight: 600; font-size: calc(12px * var(--a11y-text-scale, 1)); }
.mk-yoy-sub { font-size: calc(9px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-bottom: 9px; }
.mk-yoy-kpis { display: flex; gap: 13px; margin-bottom: 9px; flex-wrap: wrap; }
.mk-yoy-kpis .k .n { font-family: var(--font-display); font-weight: 700; font-size: calc(12.5px * var(--a11y-text-scale, 1)); letter-spacing: -0.02em; }
.mk-yoy-kpis .k .s { font-size: calc(8.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.mk-grouped { display: flex; align-items: flex-end; gap: clamp(2px, 0.6vw, 6px); flex: 1; min-height: 70px; padding-top: 4px; }
.mk-grp { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 2px; height: 100%; }
.mk-grp .b { width: 46%; border-radius: 3px 3px 0 0; }
.mk-grp .b.y1 { background: var(--surface-3); }
.mk-grp .b.y2 { background: linear-gradient(var(--accent), var(--accent-2)); }
@media (prefers-reduced-motion: no-preference) {
  .mk-grp .b { transform-origin: bottom; animation: mkBarGrow .7s cubic-bezier(.22,1,.36,1) both; }
  .mk-grp:nth-child(1) .b { animation-delay: .04s; } .mk-grp:nth-child(2) .b { animation-delay: .10s; }
  .mk-grp:nth-child(3) .b { animation-delay: .16s; } .mk-grp:nth-child(4) .b { animation-delay: .22s; }
  .mk-grp:nth-child(5) .b { animation-delay: .28s; } .mk-grp:nth-child(6) .b { animation-delay: .34s; }
  .mk-grp:nth-child(7) .b { animation-delay: .40s; } .mk-grp:nth-child(8) .b { animation-delay: .46s; }
  .mk-grp:nth-child(9) .b { animation-delay: .52s; } .mk-grp:nth-child(10) .b { animation-delay: .58s; }
  .mk-grp:nth-child(11) .b { animation-delay: .64s; } .mk-grp:nth-child(12) .b { animation-delay: .70s; }
  .mk-donut svg circle { animation: mkDonut 1s ease both .2s; }
  .mk-aiava, .cta-ai-head .av, .sc-aiava { animation: mkPulse 3.2s ease-in-out infinite; }
}
@keyframes mkBarGrow { from { transform: scaleY(0); opacity: .4; } to { transform: scaleY(1); opacity: 1; } }
@keyframes mkDonut { from { opacity: 0; } to { opacity: 1; } }
@keyframes mkPulse { 0%,100% { box-shadow: inset 0 1px 0 rgba(255,255,255,.28), 0 6px 16px -6px var(--accent-glow); } 50% { box-shadow: inset 0 1px 0 rgba(255,255,255,.28), 0 8px 22px -4px var(--accent-glow); } }
html.a11y-no-motion .mk-grp .b, html.a11y-no-motion .mk-donut svg circle, html.a11y-no-motion .mk-aiava, html.a11y-no-motion .cta-ai-head .av, html.a11y-no-motion .sc-aiava { animation: none !important; }
/* chart z osią Y i siatką */
.mk-chart { flex: 1; display: grid; grid-template-columns: auto 1fr; grid-template-rows: 1fr auto; gap: 3px 7px; min-height: 80px; }
.mk-yaxis { grid-column: 1; grid-row: 1; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-end; font-size: calc(8px * var(--a11y-text-scale, 1)); color: var(--text-3); font-family: var(--font-display); }
.mk-plot { grid-column: 2; grid-row: 1; position: relative; min-width: 0; min-height: 0; }
.mk-gridlines { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; pointer-events: none; }
.mk-gridlines i { display: block; height: 1px; background: var(--line); }
.mk-gridlines i:last-child { background: var(--border-strong); }
.mk-grouped { position: absolute; inset: 0; display: flex; align-items: flex-end; gap: clamp(2px, 0.6vw, 6px); }
.mk-grp-x { grid-column: 2; grid-row: 2; display: flex; gap: clamp(2px, 0.6vw, 6px); }
.mk-grp-x span { flex: 1; text-align: center; font-size: calc(8px * var(--a11y-text-scale, 1)); color: var(--text-3); font-family: var(--font-display); }
.mk-legend2 { display: flex; gap: 14px; margin-top: 7px; }
.mk-legend2 .lg { display: flex; align-items: center; gap: 6px; font-size: calc(9.5px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.mk-legend2 .lg .d { width: 8px; height: 8px; border-radius: 2px; flex: none; }
.mk-dash-bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; flex: none; }
.mk-dpanel { border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); padding: 11px 13px; min-width: 0; }
.mk-dpanel .dp-h { font-family: var(--font-display); font-weight: 600; font-size: calc(12px * var(--a11y-text-scale, 1)); margin-bottom: 8px; }

/* dashboard akcje -> ekrany formularzy + wybór dokumentu */
.mk[data-mock="dashboard"] { position: relative; }
.mk-actions .mk-btn { cursor: pointer; }
.mk-back { width: 28px; height: 28px; border-radius: 8px; border: 1px solid var(--border); background: var(--fill-1); color: var(--text-2); display: grid; place-items: center; cursor: pointer; flex: none; }
.mk-back:hover { color: var(--text); border-color: var(--border-strong); }
.mk-form { padding: 14px; display: flex; flex-direction: column; gap: 11px; overflow: hidden; }
.mk-frow { display: grid; gap: 9px; }
.mk-field { min-width: 0; }
.mk-field label { font-size: calc(9px * var(--a11y-text-scale, 1)); color: var(--text-3); display: block; margin-bottom: 3px; }
.mk-input { height: 26px; border: 1px solid var(--border); border-radius: 7px; background: var(--bg); display: flex; align-items: center; gap: 6px; padding: 0 9px; font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--text-2); white-space: nowrap; overflow: hidden; }
.mk-input .ph { color: var(--text-3); }
.mk-input.sel::after { content: '▾'; margin-left: auto; color: var(--text-3); font-size: calc(9px * var(--a11y-text-scale, 1)); }
.mk-input .pill-act { margin-left: auto; background: var(--grad); color: #fff; font-size: calc(9px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 3px 8px; border-radius: 5px; flex: none; }
.mk-sec { border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2); padding: 12px; min-width: 0; }
.mk-sec-h { font-family: var(--font-display); font-weight: 600; font-size: calc(11px * var(--a11y-text-scale, 1)); margin-bottom: 9px; }
.mk-form-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mk-subtabs { display: flex; gap: 12px; border-bottom: 1px solid var(--border); margin-bottom: 9px; }
.mk-subtabs span { font-size: calc(9.5px * var(--a11y-text-scale, 1)); color: var(--text-3); padding-bottom: 6px; white-space: nowrap; }
.mk-subtabs span.on { color: var(--accent); border-bottom: 2px solid var(--accent); font-weight: 700; }
.mk-fbtns { display: flex; gap: 7px; margin-top: 8px; }
.mk-fbtns .b { font-size: calc(9px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 6px 10px; border-radius: 6px; background: var(--grad); color: #fff; }
.mk-fbtns .b.g { background: var(--fill-1); color: var(--text-2); border: 1px solid var(--border); }
.mk-fbtns .b.cy { background: #06b6d4; }
.mk-check { display: flex; align-items: center; gap: 8px; font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.mk-check .box { width: 14px; height: 14px; border: 1px solid var(--border-strong); border-radius: 4px; flex: none; }
.mk-entry { display: flex; gap: 14px; align-items: stretch; }
.mk-entry-side { width: 220px; flex: none; padding: 16px; border-radius: 11px; background: var(--surface-2); }
.mk-entry-side .es-ic { width: 48px; height: 48px; border-radius: 12px; color: var(--text-3); opacity: .45; display: grid; place-items: center; margin-bottom: 12px; }
.mk-entry-side .es-t { font-family: var(--font-display); font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); color: var(--text); }
.mk-entry-side .es-d { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 4px; line-height: 1.45; }
.mk-side-tabs { display: flex; flex-direction: column; gap: 3px; margin-top: 16px; }
.mk-side-tabs span { font-size: calc(12px * var(--a11y-text-scale, 1)); font-weight: 600; color: var(--text-2); padding: 11px 12px; border-radius: 8px; }
.mk-side-tabs span.on { background: var(--accent-soft); color: var(--accent); }
.mk-entry .mk-sec { border: 0; background: transparent; padding: 4px 0; }
.mk-editor { border: 1px solid var(--border-strong); border-radius: 8px; overflow: hidden; }
.mk-editor .me-bar { display: flex; align-items: center; gap: 10px; padding: 7px 10px; background: var(--surface-2); border-bottom: 1px solid var(--border); font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.mk-editor .me-bar .me-prev { margin-left: auto; background: #e0a615; color: #1f1500; font-weight: 700; padding: 3px 9px; border-radius: 5px; font-size: calc(10px * var(--a11y-text-scale, 1)); }
.mk-editor .me-area { height: 64px; background: var(--bg); }
.mk-note { margin-top: 10px; font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--accent); background: var(--accent-soft); border-radius: 8px; padding: 9px 12px; }
.mk-picker { position: absolute; inset: 0; background: rgba(0,0,0,0.45); z-index: 5; display: grid; place-items: center; padding: 16px; }
.mk-picker-card { background: var(--surface); border: 1px solid var(--border-strong); border-radius: 14px; width: 100%; max-width: 470px; box-shadow: var(--shadow-lg); overflow: hidden; }
.mk-picker-h { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid var(--border); font-family: var(--font-display); font-weight: 700; font-size: calc(13px * var(--a11y-text-scale, 1)); }
.mk-picker-h button { background: none; border: 0; color: var(--text-3); cursor: pointer; font-size: calc(13px * var(--a11y-text-scale, 1)); }
.mk-picker-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px; }
.mk-dtype { padding: 13px 8px; border-radius: 8px; background: var(--grad); color: #fff; font-size: calc(10.5px * var(--a11y-text-scale, 1)); font-weight: 700; text-align: center; cursor: pointer; box-shadow: 0 6px 14px -8px var(--accent-glow); }
.mk-dtype.alt { background: linear-gradient(135deg, #3b82f6, #2563eb); box-shadow: 0 6px 14px -8px rgba(37,99,235,0.5); }

/* faktura (sprzedaż) */
.mk-inv, .mk-con { display: flex; flex-direction: column; gap: 9px; min-height: 0; }
.mk-inv-top { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.mk-inv-3 { display: grid; grid-template-columns: 0.92fr 1.04fr 1.04fr; gap: 9px; }
.mk-ipanel .kl2 { font-size: calc(9px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 7px; }
.mk-2c { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 4px; }
.mk-ipanel .kstat { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--accent); font-weight: 600; margin-top: 2px; }
.mk-ptable { font-size: calc(10px * var(--a11y-text-scale, 1)); }
.mk-ptable .prow { display: grid; grid-template-columns: 2.4fr repeat(7, 1fr); gap: 6px; padding: 7px 0; border-bottom: 1px solid var(--border); color: var(--text-2); align-items: center; }
.mk-ptable .prow span:not(.c1) { text-align: right; }
.mk-ptable .prow.head { color: var(--text-3); font-weight: 700; font-size: calc(8px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.03em; }
.mk-ptable .c1 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-ptable .acc { color: var(--accent); font-weight: 600; }
.mk-ptable .amtc { font-family: var(--font-display); font-weight: 700; color: var(--text); }
.mk-sumwrap { display: flex; justify-content: flex-end; margin-top: 10px; }
.mk-sum { width: min(340px, 60%); font-size: calc(10px * var(--a11y-text-scale, 1)); }
.mk-sum .srow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 6px 8px; border-bottom: 1px solid var(--border); }
.mk-sum .srow span { text-align: right; color: var(--text-2); }
.mk-sum .srow.head span { color: var(--text-3); font-weight: 700; font-size: calc(8px * var(--a11y-text-scale, 1)); text-transform: uppercase; }
.mk-sum .srow.total { background: var(--surface-3); border-radius: 0 0 7px 7px; border-bottom: 0; font-family: var(--font-display); font-weight: 700; color: var(--text); }
.mk-docbar { display: flex; align-items: center; gap: 6px; padding: 9px 14px; border-top: 1px solid var(--border); background: var(--bg-2); flex-wrap: wrap; }
.mk-docbar .db { font-size: calc(9.5px * var(--a11y-text-scale, 1)); font-weight: 700; color: #fff; padding: 6px 11px; border-radius: 7px; white-space: nowrap; }
.mk-docbar .db.pink { background: linear-gradient(135deg,#a855f7,#ec4899); }
.mk-docbar .db.cyan { background: #06b6d4; }
.mk-docbar .db.gold { background: #e0a615; }
.mk-docbar .db.green { background: var(--success); }
.mk-docbar .db.grey { background: var(--surface-3); color: var(--text-2); }
.mk-ipanel { border: 1px solid var(--border); border-radius: 11px; background: var(--surface-2); padding: 13px 14px; min-width: 0; }
.mk-ipanel .ih { font-family: var(--font-display); font-weight: 700; font-size: calc(9.5px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-3); margin-bottom: 11px; }
.mk-ipanel .kv { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: calc(11px * var(--a11y-text-scale, 1)); padding: 6px 0; color: var(--text-3); }
.mk-ipanel .kv > span:first-child { white-space: nowrap; flex: none; }
.mk-ipanel .kv b { color: var(--text); font-weight: 600; flex: 1; min-width: 0; text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-ipanel .kv b.mk-badge { overflow: visible; flex: none; }
.mk-ipanel .kv.tight { justify-content: flex-start; gap: 8px; }
.mk-ipanel .kv.tight b { flex: 0 0 auto; text-align: left; }
.mk-ipanel .nm2 { font-weight: 600; font-size: calc(11.5px * var(--a11y-text-scale, 1)); }
.mk-ipanel .mut { font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 1px; }
.mk-itable { font-size: calc(10.5px * var(--a11y-text-scale, 1)); }
.mk-itable .row { display: grid; grid-template-columns: 1fr 32px 52px 44px 52px; gap: 6px; padding: 6px 0; border-bottom: 1px solid var(--border); color: var(--text-2); }
.mk-itable .row span:not(.c1) { text-align: right; }
.mk-itable .row.head { color: var(--text-3); font-weight: 700; font-size: calc(8.5px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.04em; }
.mk-itable .row.total { border-bottom: 0; font-weight: 700; color: var(--text); font-family: var(--font-display); }
.mk-itable .c1 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-ksefbar { display: flex; align-items: center; gap: 10px; border: 1px dashed var(--accent-glow); border-radius: 10px; padding: 8px 11px; background: var(--accent-soft); }
.mk-ksefbar .ks { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--accent); font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-ksefbar .mk-btn { margin-left: auto; height: 24px; font-size: calc(9.5px * var(--a11y-text-scale, 1)); padding: 0 9px; flex: none; }
.mk-ksefp .ksrow { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--border); }
.mk-ksefp .ksrow:last-child { border-bottom: 0; padding-bottom: 0; }
.mk-ksefp .ksrow .kbody { min-width: 0; flex: 1; }
.mk-ksefp .ksrow .kl { font-size: calc(9.5px * var(--a11y-text-scale, 1)); color: var(--text-3); display: block; }
.mk-ksefp .ksrow .kn { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text); font-family: var(--font-display); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; margin-top: 1px; }
.mk-ksefp .ksrow a { font-size: calc(10.5px * var(--a11y-text-scale, 1)); font-weight: 700; color: var(--accent); white-space: nowrap; flex: none; }

/* zamówienia (karty ZP) */
.mk-ord { display: flex; flex-direction: column; gap: 9px; min-height: 0; }
.mk-ord-filters { display: flex; align-items: center; gap: 7px; }
.mk-ocards { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; min-height: 0; overflow: hidden; align-content: start; flex: 1; }
.mk-ord-foot { margin-top: auto; display: flex; justify-content: space-between; gap: 10px; font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-3); padding-top: 8px; border-top: 1px solid var(--border); }
.mk-ord-foot b { color: var(--text-2); font-family: var(--font-display); }
.mk-ocard { border: 1px solid var(--border); border-top: 3px solid var(--success); border-radius: 11px; background: var(--surface); padding: 11px 12px; }
.mk-ocard.prog { border-top-color: var(--accent); }
.mk-ocard .oc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.mk-ocard .num { font-family: var(--font-display); font-weight: 700; font-size: calc(11.5px * var(--a11y-text-scale, 1)); }
.mk-ocard .oc-nm { font-weight: 600; font-size: calc(11px * var(--a11y-text-scale, 1)); margin: 8px 0 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-ocard .oc-nip { font-size: calc(9.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.mk-ocard .oc-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 9px; }
.mk-ocard .oc-amt { font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.mk-ocard .oc-amt b { font-family: var(--font-display); color: var(--text); }
.mk-badge.proc { color: var(--accent); background: var(--accent-soft); }

/* kontrahent (podgląd + CRM) */
.mk-cpanels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.mk-stars { display: flex; gap: 2px; color: #F5B301; }
.mk-stars svg { fill: currentColor; }
.mk-rfm { display: flex; gap: 4px; }
.mk-rfm i { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: calc(9px * var(--a11y-text-scale, 1)); font-weight: 700; color: #fff; font-style: normal; }
.mk-rfm i.g { background: var(--success); }
.mk-rfm i.b { background: var(--accent); }
.mk-rfm i.y { background: #F5B301; }
.mk-ctable { font-size: calc(10px * var(--a11y-text-scale, 1)); }
.mk-ctable .crow { display: grid; grid-template-columns: 1fr 0.8fr 1.05fr 0.75fr 0.7fr 0.8fr 1.35fr; gap: 6px; padding: 8px 0; border-bottom: 1px solid var(--border); align-items: center; color: var(--text-2); }
.mk-ctable .crow > span:nth-child(2), .mk-ctable .crow > span:nth-child(3) { text-align: center; }
.mk-ctable .crow > span:nth-child(4), .mk-ctable .crow > span:nth-child(5), .mk-ctable .crow > span:nth-child(6) { text-align: right; }
.mk-ctable .crow > span:nth-child(7) { text-align: right; }
.mk-ctable .crow.head { color: var(--text-3); font-weight: 700; font-size: calc(8px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.03em; }
.mk-ctable .crow .acc { color: var(--accent); font-family: var(--font-display); }
.mk-ctable .crow .amtc { font-family: var(--font-display); font-weight: 700; color: var(--text); }
.mk-ctable .mk-badge { padding: 2px 7px; font-size: calc(8.5px * var(--a11y-text-scale, 1)); }
.mk-ksefnote { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--accent); font-weight: 600; margin-top: 9px; }
.mk-zwin { display: flex; justify-content: flex-end; margin-bottom: -2px; }
.mk-zwin .zw { font-size: calc(9.5px * var(--a11y-text-scale, 1)); font-weight: 700; color: #1f1500; background: #e0a615; padding: 4px 11px; border-radius: 6px 6px 0 0; }
/* zdarzenia (timeline) */
.mk-events { display: flex; flex-direction: column; gap: 10px; padding-left: 6px; }
.mk-events .ev { position: relative; padding-left: 18px; }
.mk-events .ev::before { content: ''; position: absolute; left: 4px; top: 12px; bottom: -14px; width: 2px; background: var(--border-strong); }
.mk-events .ev:last-child::before { display: none; }
.mk-events .ev-dot { position: absolute; left: 0; top: 9px; width: 10px; height: 10px; border-radius: 50%; background: var(--surface); border: 2px solid #e0a615; }
.mk-events .ev-card { position: relative; background: var(--surface-3); border: 1px solid var(--border); border-radius: 9px; padding: 9px 12px; }
.mk-events .ev-meta { font-size: calc(9px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-bottom: 3px; }
.mk-events .ev-txt { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.45; }
.mk-events .ev-txt b { color: var(--text); }
.mk-events .ev-pub { position: absolute; top: 8px; right: 10px; font-size: calc(8.5px * var(--a11y-text-scale, 1)); font-weight: 700; color: #fff; background: #b91c1c; padding: 2px 7px; border-radius: 100px; }
.mk-con .mk-aiact { margin-top: 0; }
.mk-aiact .a { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* kpi */
.mk-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 14px; }
.mk-kpi { border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); padding: 13px 14px; }
.mk-kpi .lbl { color: var(--text-3); font-size: calc(10.5px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.06em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-kpi .val { font-family: var(--font-display); font-weight: 700; font-size: calc(clamp(16px, 2vw, 22px) * var(--a11y-text-scale, 1)); letter-spacing: -0.02em; margin-top: 4px; }
.mk-kpi .chg { display: inline-flex; align-items: center; gap: 4px; margin-top: 5px; font-size: calc(10.5px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 2px 7px; border-radius: 100px; white-space: nowrap; }
.mk-kpi .chg.up { color: var(--success); background: var(--success-soft); }
.mk-kpi .chg.acc { color: var(--accent); background: var(--accent-soft); }

/* panels grid */
.mk-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 12px; }
.mk-panel { border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); padding: 13px 14px; min-width: 0; }
.mk-panel .ph { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.mk-panel .ph .h { font-family: var(--font-display); font-weight: 600; font-size: calc(12.5px * var(--a11y-text-scale, 1)); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-panel .ph .t { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--text-3); border: 1px solid var(--border); border-radius: 100px; padding: 2px 8px; flex: none; }

/* charts */
.mk-area { width: 100%; height: clamp(96px, 13vw, 150px); display: block; }
.mk-bars { display: flex; align-items: flex-end; gap: clamp(4px, 1vw, 9px); height: clamp(96px, 13vw, 150px); padding-top: 6px; }
.mk-bars .b { flex: 1; border-radius: 5px 5px 0 0; background: linear-gradient(var(--accent), var(--accent-2)); opacity: .9; }
.mk-bars .b.muted { background: var(--surface-3); }
.mk-bars-x { display: flex; gap: clamp(4px, 1vw, 9px); margin-top: 6px; }
.mk-bars-x span { flex: 1; text-align: center; font-size: calc(9px * var(--a11y-text-scale, 1)); color: var(--text-3); font-family: var(--font-display); letter-spacing: 0.02em; }
.mk-donut { display: grid; place-items: center; position: relative; }
.mk-donut .ctr { position: absolute; text-align: center; }
.mk-donut .ctr .n { font-family: var(--font-display); font-weight: 700; font-size: calc(18px * var(--a11y-text-scale, 1)); }
.mk-donut .ctr .s { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.mk-legend { display: grid; gap: 6px; margin-top: 8px; }
.mk-legend .lg { display: flex; align-items: center; gap: 7px; font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.mk-legend .lg .d { width: 9px; height: 9px; border-radius: 3px; flex: none; }
.mk-legend .lg .v { margin-left: auto; font-weight: 700; color: var(--text); }

/* lists / tables */
.mk-list { display: grid; gap: 7px; margin-top: 2px; }
.mk-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); }
.mk-row .ava { width: 26px; height: 26px; border-radius: 7px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 700; font-size: calc(10px * var(--a11y-text-scale, 1)); flex: none; }
.mk-row .ava.circ { border-radius: 50%; background: var(--surface-3); color: var(--text-2); }
.mk-row .nm { font-weight: 600; font-size: calc(11.5px * var(--a11y-text-scale, 1)); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-row .meta { color: var(--text-3); font-size: calc(10.5px * var(--a11y-text-scale, 1)); }
.mk-row .amt { margin-left: auto; font-family: var(--font-display); font-weight: 700; font-size: calc(12px * var(--a11y-text-scale, 1)); white-space: nowrap; }
.mk-badge { font-size: calc(9.5px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 2px 7px; border-radius: 100px; white-space: nowrap; }
.mk-badge.ok { color: var(--success); background: var(--success-soft); }
.mk-badge.wait { color: var(--warn); background: color-mix(in oklab, var(--warn) 15%, transparent); }
.mk-badge.late { color: #ef4444; background: color-mix(in oklab, #ef4444 15%, transparent); }
.mk-badge.ksef { color: var(--accent); background: var(--accent-soft); }
.mk-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.mk-chip { font-size: calc(10px * var(--a11y-text-scale, 1)); font-weight: 600; padding: 4px 9px; border-radius: 100px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); }
.mk-chip.on { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

/* kanban */
.mk-kanban { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; height: 100%; }
.mk-col { background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 11px; display: flex; flex-direction: column; gap: 8px; min-height: 0; }
.mk-col .ch { display: flex; align-items: center; gap: 7px; font-weight: 700; font-size: calc(11px * var(--a11y-text-scale, 1)); }
.mk-col .ch .cnt { margin-left: auto; color: var(--text-3); font-weight: 700; }
.mk-col .ch .dot { width: 8px; height: 8px; border-radius: 50%; }
.mk-card { border: 1px solid var(--border); border-radius: 9px; background: var(--surface); padding: 9px 10px; }
.mk-card .id { font-family: var(--font-display); font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.mk-card .t { font-weight: 600; font-size: calc(11px * var(--a11y-text-scale, 1)); margin: 2px 0 6px; }
.mk-card .rowb { display: flex; align-items: center; gap: 6px; }
.mk-card .amt { margin-left: auto; font-weight: 700; font-size: calc(11px * var(--a11y-text-scale, 1)); }

/* ai panel */
.mk-ai { display: grid; grid-template-columns: 1fr 0.92fr; gap: 12px; height: 100%; }
.mk-aibubble { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 9px 11px; font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.mk-aibubble.me { background: var(--grad); color: #fff; border: 0; }
.mk-aihead { display: flex; align-items: center; gap: 9px; margin-bottom: 10px; }
.mk-aihead .av { width: 30px; height: 30px; border-radius: 9px; background: var(--grad); display: grid; place-items: center; color: #fff; }
.mk-aihead .nm { font-weight: 700; font-size: calc(12px * var(--a11y-text-scale, 1)); }
.mk-aihead .st { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--success); }
.mk-aiact { display: grid; gap: 6px; margin-top: 10px; }
.mk-aiact .a { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); font-size: calc(11px * var(--a11y-text-scale, 1)); font-weight: 600; }
.mk-aiact .a .ic { color: var(--accent); }

/* ============================================================
   REJESTRACJA (kreator 4 kroki)
   ============================================================ */
.reg-grid { display: grid; grid-template-columns: 0.8fr 1.1fr; gap: clamp(20px, 3vw, 40px); align-items: start; max-width: 1040px; margin-inline: auto; }
.reg-card { border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius); padding: clamp(22px, 3vw, 32px); }
.reg-side { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 90px; }
.reg-side h3 { font-size: calc(18px * var(--a11y-text-scale, 1)); margin-bottom: 16px; }
.reg-benefits { list-style: none; margin: 0; padding: 0; display: grid; gap: 13px; }
.reg-benefits li { display: flex; gap: 10px; font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.4; }
.reg-benefits li svg { color: var(--success); flex: none; margin-top: 2px; }
.reg-benefits b { color: var(--text); font-weight: 700; }
.reg-quote { border: 1px solid var(--border); background: var(--bg-2); border-radius: var(--radius); padding: 22px; position: relative; }
.reg-quote .q { font-family: var(--font-display); font-size: calc(42px * var(--a11y-text-scale, 1)); color: var(--accent); line-height: .6; opacity: .5; }
.reg-quote p { font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); font-style: italic; line-height: 1.55; margin: 6px 0 12px; }
.reg-quote .who { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); font-weight: 600; }

/* stepper */
.reg-stepper { display: flex; align-items: center; margin-bottom: 26px; }
.reg-step { display: flex; flex-direction: column; align-items: center; gap: 6px; flex: none; }
.reg-step .dot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: calc(14px * var(--a11y-text-scale, 1)); background: var(--surface-2); border: 1px solid var(--border-strong); color: var(--text-3); }
.reg-step .lbl { font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.reg-step.on .dot { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 4px 12px -4px var(--accent-glow); }
.reg-step.on .lbl { color: var(--accent); font-weight: 700; }
.reg-step.done .dot { background: var(--success); color: #fff; border-color: transparent; }
.reg-step.done .lbl { color: var(--text-2); }
.reg-bar { flex: 1; height: 2px; background: var(--border-strong); margin: 0 8px; align-self: flex-start; margin-top: 15px; }
.reg-bar.done { background: var(--success); }

.reg-h { font-size: calc(22px * var(--a11y-text-scale, 1)); margin-bottom: 18px; }
.reg-pane .field { margin-bottom: 15px; }
.reg-pane .field label i { color: var(--accent); font-style: normal; }
.reg-nip { display: flex; gap: 8px; }
.reg-nip input { flex: 1; }
.reg-hint { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 6px; }
.reg-note { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-3); text-align: center; margin-top: 12px; }
.reg-fetched { display: flex; align-items: flex-start; gap: 9px; font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--success); background: var(--success-soft); border: 1px solid color-mix(in oklab, var(--success) 30%, transparent); border-radius: 11px; padding: 11px 14px; margin-bottom: 16px; }
.reg-fetched span { min-width: 0; word-break: break-word; }
.reg-fetched svg { flex: none; }

/* plany */
.reg-plans { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.reg-plan { position: relative; text-align: left; border: 1.5px solid var(--border); background: var(--surface-2); border-radius: 14px; padding: 14px; cursor: pointer; font-family: var(--font-body); transition: border-color .15s, background .15s; }
.reg-plan:hover { border-color: var(--border-strong); }
.reg-plan.on { border-color: var(--accent); background: var(--accent-soft); }
.reg-plan .pp { position: absolute; top: -9px; left: 50%; transform: translateX(-50%); background: var(--grad); color: #fff; font-size: calc(10px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 3px 10px; border-radius: 100px; white-space: nowrap; }
.reg-plan .ck { position: absolute; top: 10px; right: 10px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; }
.reg-plan .nm { font-family: var(--font-display); font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); text-align: center; }
.reg-plan .pr { font-family: var(--font-display); font-weight: 700; font-size: calc(20px * var(--a11y-text-scale, 1)); color: var(--accent); text-align: center; margin: 2px 0 10px; }
.reg-plan .pr span { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-3); font-weight: 500; }
.reg-plan ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.reg-plan ul li { display: flex; gap: 6px; font-size: calc(11.5px * var(--a11y-text-scale, 1)); color: var(--text-2); }
.reg-plan ul li svg { color: var(--success); flex: none; margin-top: 2px; }

/* hasło siła */
.reg-pw { height: 5px; border-radius: 100px; background: var(--surface-3); margin-top: 8px; overflow: hidden; }
.reg-pw i { display: block; height: 100%; border-radius: 100px; transition: width .25s, background .25s; }
.reg-pw.s1 i { width: 33%; background: #ef4444; }
.reg-pw.s2 i { width: 66%; background: var(--warn); }
.reg-pw.s3 i { width: 100%; background: var(--success); }
.reg-pw-lbl { font-size: calc(12px * var(--a11y-text-scale, 1)); margin-top: 5px; color: var(--text-3); }

/* subdomena */
.reg-sub { display: flex; align-items: stretch; border: 1px solid var(--border-strong); border-radius: 10px; overflow: hidden; background: var(--bg); }
.reg-sub .pre, .reg-sub .suf { display: flex; align-items: center; padding: 0 12px; font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-3); background: var(--surface-2); white-space: nowrap; }
.reg-sub input { border: 0 !important; border-radius: 0 !important; box-shadow: none !important; text-align: center; flex: 1; min-width: 0; }

/* podsumowanie */
.reg-summary { border: 1px solid var(--border); background: var(--surface-2); border-radius: 14px; padding: 18px; margin: 18px 0; }
.reg-summary .sh { font-family: var(--font-display); font-weight: 700; font-size: calc(11px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-3); margin-bottom: 14px; }
.reg-summary .sg { display: grid; grid-template-columns: 1fr 1fr; gap: 13px 18px; }
.reg-summary .sg > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.reg-summary .sg span { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-3); }
.reg-summary .sg b { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text); font-weight: 600; }
.reg-check { display: flex; gap: 10px; align-items: flex-start; font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-2); margin-bottom: 12px; line-height: 1.5; }
.reg-check input { width: auto; margin-top: 3px; flex: none; }
.reg-check a { color: var(--accent); font-weight: 600; }

.reg-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 22px; }

/* rejestracja v2 */
.reg2-grid { display: grid; grid-template-columns: 1.4fr 0.75fr; gap: clamp(20px, 3vw, 36px); align-items: stretch; max-width: 1040px; margin-inline: auto; }.reg2-steps { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; font-size: calc(13.5px * var(--a11y-text-scale, 1)); }
.reg2-steps .st { display: inline-flex; align-items: center; gap: 9px; color: var(--text-3); font-weight: 600; white-space: nowrap; }
.reg2-steps .st .b { width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-family: var(--font-display); font-style: normal; font-weight: 700; font-size: calc(12px * var(--a11y-text-scale, 1)); line-height: 1; background: var(--surface-2); border: 1px solid var(--border-strong); color: var(--text-2); flex: none; }
.reg2-steps .st.on { color: var(--accent); }
.reg2-steps .st.on .b { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 4px 12px -4px var(--accent-glow); }
.reg2-steps .st.done { color: var(--success); }
.reg2-steps .st.done .b { background: var(--success); color: #fff; border-color: transparent; }
.reg2-steps .st .b i, .reg2-steps .st .b svg { display: block; }
.reg2-steps .ln { flex: 1; height: 2px; border-radius: 2px; background: var(--border-strong); overflow: hidden; position: relative; }
.reg2-steps .ln i { display: block; height: 100%; width: 0; background: var(--grad); transition: width .5s cubic-bezier(.22,1,.36,1); position: relative; z-index: 1; }
@media (prefers-reduced-motion: no-preference) {
  .reg2-steps .ln::after { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, var(--accent), transparent); background-size: 50% 100%; background-repeat: no-repeat; animation: lnSweep 1.8s linear infinite; opacity: .8; }
}
@keyframes lnSweep { 0% { background-position: -60% 0; } 100% { background-position: 160% 0; } }
html.a11y-no-motion .reg2-steps .ln::after { animation: none; display: none; }
.reg2-sec { font-family: var(--font-display); font-weight: 700; font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); text-transform: uppercase; letter-spacing: 0.05em; margin: 20px 0 12px; }
.reg2-plans { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.reg2-plan { position: relative; text-align: left; border: 1.5px solid var(--border); background: var(--surface-2); border-radius: 12px; padding: 13px 15px; cursor: pointer; font-family: var(--font-body); transition: border-color .15s, background .15s; }
.reg2-plan:hover { border-color: var(--border-strong); }
.reg2-plan.on { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent); }
.reg2-plan .ck { position: absolute; top: 11px; right: 12px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; }
.reg2-plan.on .nm { color: var(--accent); }
.reg2-plan .pp { position: absolute; top: -9px; right: 12px; background: var(--grad); color: #fff; font-size: calc(10px * var(--a11y-text-scale, 1)); font-weight: 700; padding: 3px 9px; border-radius: 100px; }
.reg2-plan .row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.reg2-plan .nm { font-family: var(--font-display); font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); }
.reg2-plan .pr { font-family: var(--font-display); font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); color: var(--accent); white-space: nowrap; }
.reg2-plan .pr i { font-size: calc(10px * var(--a11y-text-scale, 1)); color: var(--text-3); font-style: normal; font-weight: 500; }
.reg2-plan .d { font-size: calc(11.5px * var(--a11y-text-scale, 1)); color: var(--text-2); margin-top: 3px; }
.reg2-aside { align-self: stretch; }
.reg2-summary { height: 100%; }
.reg2-summary .sh { font-family: var(--font-display); font-weight: 700; font-size: calc(11px * var(--a11y-text-scale, 1)); text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-3); margin-bottom: 14px; }
.reg2-sumhead { display: flex; align-items: center; gap: 12px; padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid var(--border); }
.reg2-sumhead .av { width: 42px; height: 42px; border-radius: 12px; background: var(--grad); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); flex: none; box-shadow: inset 0 1px 0 rgba(255,255,255,.28); }
.reg2-sumhead .nm { font-family: var(--font-display); font-weight: 700; font-size: calc(15px * var(--a11y-text-scale, 1)); }
.reg2-sumhead .sub { font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 170px; }
.reg2-planbox { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--accent-soft); border: 1px solid var(--accent-glow); border-radius: 12px; padding: 12px 14px; margin-bottom: 16px; }
.reg2-planbox .l { font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-3); text-transform: uppercase; letter-spacing: 0.05em; }
.reg2-planbox .p { font-family: var(--font-display); font-weight: 700; font-size: calc(17px * var(--a11y-text-scale, 1)); color: var(--accent); }
.reg2-planbox .amt { font-family: var(--font-display); font-weight: 700; font-size: calc(17px * var(--a11y-text-scale, 1)); white-space: nowrap; }
.reg2-planbox .amt i { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-3); font-style: normal; font-weight: 500; }
.reg2-pickbox { border: 1px solid var(--accent-glow); border-radius: 12px; padding: 13px 14px; margin-bottom: 16px; background: var(--accent-soft); }
.reg2-pickbox .l { font-size: calc(10.5px * var(--a11y-text-scale, 1)); color: var(--text-3); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 8px; }
.reg2-pills { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.reg2-pill { border: 1px solid var(--border-strong); background: var(--surface); color: var(--text-2); border-radius: 8px; padding: 7px 6px; font-size: calc(12px * var(--a11y-text-scale, 1)); font-weight: 700; font-family: var(--font-body); cursor: pointer; transition: all .15s; }
.reg2-pill:hover { border-color: var(--accent); }
/* WCAG: wybrany przelacznik ma bialy napis - uzyj --btn-grad (czytelny >=4.5:1) */
.reg2-pill.on { background: var(--btn-grad); color: #fff; border-color: transparent; }
.reg2-pill .star { color: #f5b301; font-style: normal; font-size: calc(9px * var(--a11y-text-scale, 1)); margin-left: 4px; vertical-align: middle; }
.reg2-pill.on .star { color: #fff; }
.reg2-pickrow { display: flex; align-items: center; gap: 8px; margin-top: 11px; }
.reg2-pickrow .amt { font-family: var(--font-display); font-weight: 700; font-size: calc(18px * var(--a11y-text-scale, 1)); }
.reg2-pickrow .amt i { font-size: calc(11px * var(--a11y-text-scale, 1)); color: var(--text-3); font-style: normal; font-weight: 500; }
.reg2-pickrow .pp { margin-left: auto; font-size: calc(10px * var(--a11y-text-scale, 1)); font-weight: 700; color: #fff; background: var(--grad); padding: 3px 9px; border-radius: 100px; }
.reg2-pickhint { display: flex; gap: 7px; align-items: flex-start; font-size: calc(11.5px * var(--a11y-text-scale, 1)); color: var(--text-2); line-height: 1.45; margin-top: 9px; padding-top: 9px; border-top: 1px solid var(--accent-glow); }
.reg2-pickhint svg { color: var(--accent); flex: none; margin-top: 2px; }
.reg2-summary .sg { display: grid; gap: 0; }
.reg2-summary .sg > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; padding: 9px 0; border-bottom: 1px solid var(--border); }
.reg2-summary .sg > div:last-child { border-bottom: 0; }
.reg2-summary .sg span { font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--text-3); flex: none; }
.reg2-summary .sg b { font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: right; }
.reg2-perks { border-top: 1px solid var(--border); margin-top: 16px; padding-top: 14px; display: grid; gap: 9px; }
.reg2-perks div { display: flex; align-items: center; gap: 8px; font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: var(--text-2); font-weight: 600; }
.reg2-perks svg { color: var(--success); flex: none; }
@media (max-width: 880px) {
  .reg2-grid { grid-template-columns: 1fr; }
  .reg2-aside { position: static; order: -1; }
  .reg2-plans { grid-template-columns: 1fr; }
}

@media (max-width: 880px) {
  .reg-grid { grid-template-columns: 1fr; }
  .reg-side { position: static; order: 2; }
  .reg-plans { grid-template-columns: 1fr; }
  .reg-summary .sg { grid-template-columns: 1fr; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-burger { display: flex; }
  /* WCAG: ZAMKNIETE menu mobilne calkowicie znika z drzewa (display:none),
     wiec jego linki nie lapia klawisza Tab. OTWARTE (.nav.menu-open)
     pokazuje sie jako display:flex. Uzyta istniejaca klasa menu-open z JS. */
  .nav-mobile { display: none; }
  .nav.menu-open .nav-mobile { display: flex; }
  .heroB, .heroC, .ksef-grid, .assist-grid { grid-template-columns: 1fr; }
  /* minmax(0, 1fr): track NIE respektuje min-content sztywnej makiety (980px),
     dzieki czemu kolumna zwezi sie do szerokosci ekranu. Przy zwyklym 1fr
     (= minmax(auto,1fr)) auto = min-content = 980px rozdymalo kolumne, wiec
     wrap.clientWidth = 980, fit() liczyl skale 980/980 = 1 i makieta sie nie skalowala. */
  .heroA { grid-template-columns: minmax(0, 1fr); }
  .ksef-grid2 { grid-template-columns: 1fr; }
  .hero-visual { order: -1; }
  /* NIE obcinaj plywajacych kart (.float-card siedza na ujemnych offsetach top/bottom).
     Clip zostaje TYLKO na .app-window (zaokraglone rogi obrazu dashboardu).
     Rezerwa pionowa (margin) daje miejsce gornej i dolnej karcie, by sie miescily
     i nie kolidowaly z naglowkiem pod hero. */
  .heroA .hero-visual { overflow: visible; margin-top: 26px; margin-bottom: 30px; min-width: 0; max-width: 100%; }
  /* min-width:0 puszcza grid-track ponizej min-content makiety -> track = szerokosc
     ekranu, wrap (.mk-scaled) zweza sie, a fit() przeskaluje .mk-scaled-in (980px -> ekran).
     overflow:visible ZOSTAJE na .hero-visual (karty .float-card.tl/.br nieuciete);
     clip obrazu dashboardu jest na .app-window (overflow:hidden z bazowej reguly). */
  .heroA .hero-visual .app-window { width: 100%; min-width: 0; max-width: 100%; }
  .heroA .hero-visual .mk-scaled { min-width: 0; max-width: 100%; }
  /* GALERIA (#galeria): ten sam mechanizm co hero, inne selektory (.gal-stage,
     nie .heroA). Lancuch .gal-stage > .app-window > [data-gallery-stage] > .mk-scaled
     > .mk-scaled-in (sztywne width:980px) bez min-width:0 trzymal min-content 980px,
     wiec wrap.clientWidth = 980, fit() liczyl skale 980/980 = 1 -> makieta nieskalowana,
     app-ekran uciety z prawej. min-width:0 + max-width:100% na kazdym ogniwie puszcza
     bloki ponizej 980px do szerokosci ekranu; .mk-scaled = ekran, fit() przeskaluje
     CALY .mk-scaled-in (dziala per zakladka: dashboard/sales/orders/contractors, bo
     fit() przelicza po kazdym przerysowaniu). overflow:hidden na .app-window (baza)
     przycina zaokraglona ramka. Scoped do .gal-stage - hero nietkniety. Desktop bez
     zmian (poza tym media query; .gal-stage max-width:1000px i fit dzialaja). */
  .gal-stage { min-width: 0; max-width: 100%; }
  .gal-stage .app-window { width: 100%; min-width: 0; max-width: 100%; }
  .gal-stage [data-gallery-stage] { min-width: 0; max-width: 100%; }
  .gal-stage .mk-scaled { min-width: 0; max-width: 100%; }
  .heroB .countdown, .heroC .chat { order: 2; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .card.feature-hero, .card.span-3, .card.span-2, .card.span-4 { grid-column: span 2; grid-row: auto; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .tgrid, .tri-grid { grid-template-columns: 1fr; }
  .price-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer .brand-col { grid-column: 1 / -1; }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .post-card.feat { flex-direction: column; }
  .post-card.feat .thumb, .post-card.feat image-slot { width: 100%; min-height: 220px; }
  .contact-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .ksef-panel { position: static; }
  .ksef-track { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .mk-inv-3 { grid-template-columns: 1fr; }
  .ksef-track::before { display: none; }
  .cta-ai-body { grid-template-columns: 1fr; }
  .cta-ai-note { justify-content: flex-start; }
}
@media (max-width: 560px) {
  .bento, .stats, .price-grid, .cap-list { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
  .module { grid-template-columns: 1fr; }
  .module .mhead, .module .mfeats, .module-cta { grid-column: 1; }
  .module .mfeats { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .card.feature-hero, .card.span-3, .card.span-2, .card.span-4 { grid-column: span 1; }
  .hero .lead { max-width: none; }
  .cd-grid { grid-template-columns: repeat(4, 1fr); }
  .nav-cta .btn-link { display: none; }
  .microtrust { gap: 20px; }
}
@media (max-width: 600px) {
  /* Tabele w artykulach: przewijalny blok w bok, bez ucinania tresci.
     Bez white-space:nowrap - dlugie opisy zawijaja sie zamiast znikac;
     min-width wymusza suwak poziomy dopiero gdy tabela jest szersza niz ekran. */
  .prose table { display: block; overflow-x: auto; max-width: 100%; min-width: 0; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }
  .prose table thead, .prose table tbody { display: table; width: 100%; min-width: 480px; }
  .prose table tr { width: 100%; }
  .prose th, .prose td { white-space: normal; word-break: break-word; overflow-wrap: anywhere; }
  .hero-cta { width: 100%; }
  .hero-cta .btn { flex: 1 1 auto; justify-content: center; }
  .ph-stats { gap: 22px; }
  .final .hero-cta, .cta-ai-actions { width: 100%; }
  .cta-ai-actions .btn, .final .hero-cta .btn { width: 100%; }
  .reg-actions { flex-wrap: wrap; }
  .reg-actions .btn { flex: 1 1 auto; justify-content: center; }
  .gal-tabs { overflow-x: auto; flex-wrap: nowrap; justify-content: flex-start; -webkit-overflow-scrolling: touch; }
  .gal-tabs button { flex: none; }
  .sc-msg { max-width: 96%; }
  .reg2-pills { grid-template-columns: 1fr 1fr; }
  /* Etykieta hero (lewy gorny rog makiety) nie moze wystawac za lewa krawedz ekranu */
  .float-card.tl { left: 4px; }
  .float-card.br { right: 4px; }
}

/* Telefon w poziomie (niski ekran): kompaktowy hero, zeby kluczowa tresc
   i etykiety miescily sie bez duzego scrolla. Pion/tablet/desktop nietkniete. */
@media (orientation: landscape) and (max-height: 500px) {
  .hero { padding-top: 16px; padding-bottom: 16px; }
  .heroA, .heroB, .heroC { gap: 24px; }
  .hero-visual .mk { height: clamp(240px, 38vh, 320px); }
  .app-window image-slot { height: auto; }
  .heroA .hero-visual .app-window { width: min(520px, 56vw); }
  /* Mniejsza makieta i wylaczona animacja unoszenia, by nie wypychala tresci */
  .hero-visual { transform: scale(0.86); transform-origin: top center; }
  .float-card { animation: none; padding: 9px 12px; }
  .float-card.tl { top: -10px; }
  .float-card.br { bottom: -10px; }
}

.no-floats .float-card { display: none; }

/* ============================================================
   AUTH (logowanie)
   ============================================================ */
.auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 40px 20px; }
.auth-wrap { width: 100%; max-width: 440px; display: flex; flex-direction: column; align-items: center; gap: 22px; }
.auth-logo { font-size: calc(24px * var(--a11y-text-scale, 1)); }
.auth-logo .mark { width: 40px; height: 40px; font-size: calc(18px * var(--a11y-text-scale, 1)); border-radius: 11px; }
.auth-logo-sub { font-family: var(--font-body); font-weight: 500; font-size: calc(13px * var(--a11y-text-scale, 1)); color: var(--text-3); align-self: flex-end; margin-bottom: 4px; }
.auth-card { width: 100%; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: clamp(26px, 4vw, 38px); }
.auth-h { font-size: calc(clamp(22px, 3vw, 28px) * var(--a11y-text-scale, 1)); text-align: center; margin-bottom: 8px; }
.auth-h .accent { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.auth-sub { font-size: calc(14px * var(--a11y-text-scale, 1)); color: var(--text-2); text-align: center; line-height: 1.55; margin-bottom: 22px; }
.auth-sub b { color: var(--text); }
.auth-input { position: relative; }
/* WCAG: ramki pol logowania/rejestracji - --field-border zapewnia >=3:1 */
.auth-input input, .auth-input select { width: 100%; height: 48px; padding: 0 44px 0 15px; border-radius: 12px; border: 1px solid var(--field-border); background: var(--bg); color: var(--text); font-family: inherit; font-size: calc(15px * var(--a11y-text-scale, 1)); transition: border-color .2s, box-shadow .2s; }
.auth-input input:focus, .auth-input select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.auth-input .ic { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--text-3); display: grid; pointer-events: none; }
.auth-foot { text-align: center; font-size: calc(13.5px * var(--a11y-text-scale, 1)); color: var(--text-3); margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--border); }
.auth-foot a { color: var(--accent); font-weight: 600; }
.auth-copy { font-size: calc(12px * var(--a11y-text-scale, 1)); color: var(--text-3); text-align: center; }

/* auth split-screen */
.auth2 { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; }
.auth2-brand { position: relative; overflow: hidden; background: linear-gradient(150deg, var(--accent), var(--accent-2)); color: #fff; display: flex; align-items: center; padding: clamp(32px, 5vw, 72px); order: 2; }
.auth2-brand::before { content: ''; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,0.07) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.07) 1px, transparent 1px); background-size: 48px 48px; mask-image: radial-gradient(ellipse 80% 70% at 30% 30%, #000, transparent 75%); }
.auth2-brand-in { position: relative; max-width: 440px; }
.auth2-logo { color: #fff; font-size: calc(24px * var(--a11y-text-scale, 1)); margin-bottom: clamp(24px, 5vw, 48px); }
.auth2-logo .mark { background: rgba(255,255,255,0.18); box-shadow: none; }
.auth2-logo .mp { color: #fff; }
.auth2-brand h2 { font-size: calc(clamp(24px, 2.6vw, 34px) * var(--a11y-text-scale, 1)); line-height: 1.2; margin-bottom: 28px; color: #fff; }
.auth2-benefits { list-style: none; margin: 0 0 32px; padding: 0; display: grid; gap: 14px; }
.auth2-benefits li { display: flex; gap: 11px; align-items: flex-start; font-size: calc(15px * var(--a11y-text-scale, 1)); color: rgba(255,255,255,0.92); line-height: 1.4; }
.auth2-benefits .ck { width: 24px; height: 24px; border-radius: 50%; background: rgba(255,255,255,0.2); display: grid; place-items: center; flex: none; }
.auth2-quote { border-top: 1px solid rgba(255,255,255,0.22); padding-top: 22px; }
.auth2-quote p { font-size: calc(14.5px * var(--a11y-text-scale, 1)); font-style: italic; color: rgba(255,255,255,0.92); line-height: 1.55; margin: 0 0 14px; }
.auth2-quote .who { display: flex; align-items: center; gap: 11px; }
.auth2-quote .who .av { width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,0.2); display: grid; place-items: center; font-weight: 700; font-size: calc(13px * var(--a11y-text-scale, 1)); flex: none; }
.auth2-quote .who .nm { font-weight: 700; font-size: calc(14px * var(--a11y-text-scale, 1)); }
.auth2-quote .who .rl { font-size: calc(12.5px * var(--a11y-text-scale, 1)); color: rgba(255,255,255,0.8); }
.auth2-main { position: relative; background: var(--bg); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: clamp(28px, 5vw, 56px); order: 1; }
.auth2-top { position: absolute; top: 20px; right: 24px; left: 24px; display: flex; align-items: center; justify-content: space-between; flex-direction: row-reverse; }
.auth2-card { width: 100%; max-width: 380px; }
@media (max-width: 860px) {
  .auth2 { grid-template-columns: 1fr; }
  .auth2-brand { display: none; }
  .auth2-top { position: static; justify-content: flex-end; margin-bottom: 20px; }
}

/* scroll-reveal (motion.js) */
@media (prefers-reduced-motion: no-preference) {
  [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .9s cubic-bezier(.22,1,.36,1) var(--reveal-delay,0ms), transform .9s cubic-bezier(.22,1,.36,1) var(--reveal-delay,0ms); will-change: opacity, transform; }
  [data-reveal].in { opacity: 1; transform: none; }
  .quote.in .stars svg { animation: starPop .4s var(--ease,cubic-bezier(.22,1,.36,1)) both; }
  .quote.in .stars svg:nth-child(1){animation-delay:.05s} .quote.in .stars svg:nth-child(2){animation-delay:.12s} .quote.in .stars svg:nth-child(3){animation-delay:.19s} .quote.in .stars svg:nth-child(4){animation-delay:.26s} .quote.in .stars svg:nth-child(5){animation-delay:.33s}
}
@keyframes starPop { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: scale(1); } }
html.a11y-no-motion [data-reveal] { opacity: 1 !important; transform: none !important; }

/* support console responsive */
@media (max-width: 760px) {
  /* BEZ stalej wysokosci .sc na mobile: stary `height: min(640px, 80dvh)` ucinal wysoki
     formularz B2B i to wlasnie przez niego nastepna sekcja (promo "Testuj za darmo")
     nachodzila na pola formularza. Wysokosc okna trzyma teraz min-height na .sc-main
     (czat/baza wypelniaja okno i przewijaja tresc w srodku, formularz rosnie do tresci),
     wiec .sc plynie do zawartosci. */
  .sc { grid-template-columns: 1fr; height: auto; }
  .sc-rail { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; overflow: visible; border-right: 0; border-bottom: 1px solid var(--border); padding: 12px; }
  .sc-brandrow { display: flex; grid-column: 1 / -1; padding: 2px 4px 10px; margin-bottom: 2px; border-bottom: 1px solid var(--border); }
  .sc-nav { width: 100%; white-space: nowrap; padding: 10px 12px; font-size: calc(13.5px * var(--a11y-text-scale, 1)); }
  .sc-nav .lbl { display: inline; }
  .sc-spacer { display: none; }
  .sc-msg { max-width: 92%; }
  .kontakt-hero.page-hero { padding: 26px 0 12px; }
  .kontakt-hero .wrap { max-width: none; }
  .kontakt-hero .ph-sub { font-size: calc(15px * var(--a11y-text-scale, 1)); }
  .kontakt-hero h1 { margin-bottom: 12px; }
}

/* reduced motion - uzytkownik prosi o mniej ruchu */
@media (prefers-reduced-motion: reduce) {
  /* plynne przewijanie wylaczone */
  html { scroll-behavior: auto; }
  /* animacja kart plywajacych + kropek "pisze..." wyciszona */
  .float-card, .typing span { animation: none !important; }
}

/* menu „trzy kropki" na waskich ekranach (np. 360px) - nie wychodzi poza okno */
@media (max-width: 420px) {
  .sc-menu { min-width: 0; width: max-content; max-width: calc(100vw - 32px); right: 0; }
  .sc-menu-item { font-size: calc(13.5px * var(--a11y-text-scale, 1)); padding: 11px 12px; }
}

/* ============================================================
   GLOBALNY RESET RUCHU (WCAG 2.2 - 2.3.3 Animation from Interactions)
   Gdy system uzytkownika zglasza "ogranicz ruch", wyciszamy KAZDA
   animacje i przejscie na calej stronie. Blok jest celowo ostatni i
   uniwersalny (*) z !important, zeby pokryc takze style inline w <style>
   poszczegolnych podstron. Lokalne bloki reduce powyzej zostaja - ten je
   tylko domyka na wypadek elementow, ktorych nie wymieniono z nazwy.
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
