/* ============================================================================
   Strona firmy nFlow (#52). Hero z wariantu B „Ciemny kinowy” (#51), sekcje
   pod nim z wariantu D „Pokaz” (2026-10-26). Cały układ to czysty CSS (działa
   bez JS i przy reduced-motion); landing.js dokłada tylko ruch w hero.
   Kolory marki z tokens.css (--brand-*); tu tylko pochodne tej strony, na
   body.landing-page, z wariantem ciemnym pod html[data-theme="dark"].
   ============================================================================ */

body.landing-page {
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI Variable Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    --hdr-h: 64px;
    --gut: clamp(16px, 4vw, 56px);
    --maxw: 1240px;

    --bg: #f3f6fa;
    --bg-raise: var(--brand-surface);
    --ink: var(--brand-ink);
    --muted: #56637a;          /* ciemniejszy od --brand-muted: AA na #f3f6fa */
    --faint: #5f6b80;          /* AA na jasnych kartach (#6b778c dawał 4.44:1) */
    --line: var(--brand-line);
    --accent: var(--brand-blue-600);
    --accent-2: var(--brand-navy-800);
    --glow: var(--brand-glow-deep-rgb);
    --card-bg: linear-gradient(160deg, #ffffff 0%, #f6f9fd 60%, #eef3fa 100%);
    --card-edge: rgba(11, 55, 116, 0.10);
    --shadow-lg: 0 30px 80px -30px rgba(var(--brand-navy-950-rgb), 0.28), 0 2px 6px rgba(var(--brand-navy-950-rgb), 0.05);
    --island-r: 28px;
    --island-m: 10px;
}

html[data-theme="dark"] body.landing-page {
    --bg: #030a17;
    --bg-raise: var(--brand-surface);
    --muted: var(--brand-muted);
    --faint: #7f8ea8;
    --line: #1b2c47;
    --accent: var(--brand-blue-400);
    --accent-2: var(--brand-blue-300);
    --glow: var(--brand-glow-rgb);
    --card-bg: radial-gradient(90% 120% at 100% 0%, rgba(var(--brand-glow-deep-rgb), 0.30) 0%, rgba(var(--brand-glow-deep-rgb), 0) 55%), linear-gradient(170deg, #0b1d3a 0%, #071329 55%, #050e1f 100%);
    --card-edge: rgba(140, 180, 235, 0.14);
    --shadow-lg: 0 40px 100px -30px rgba(0, 0, 0, 0.8);
    --island-r: 0px;
    --island-m: 0px;
}

/* Ciemna wyspa (hero, „Jak pracujemy”, stopka) i nagłówek nad nią: zawsze
   ciemna paleta, niezależnie od motywu. */
.island,
.hdr.on-dark,
html[data-theme="dark"] .hdr {
    --ink: var(--brand-island-ink);
    --muted: var(--brand-island-muted);
    --faint: var(--brand-island-faint);
    --line: var(--brand-island-line);
    --accent: var(--brand-blue-400);
    --accent-2: var(--brand-blue-300);
    --glow: var(--brand-glow-rgb);
}

/* ---------- Baza ---------- */
.landing-page *, .landing-page *::before, .landing-page *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-rendering: optimizeLegibility; }
body.landing-page {
    margin: 0;
    font-family: var(--font);
    font-size: 17px;
    line-height: 1.55;
    background: var(--bg);
    color: var(--ink);
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}
.landing-page h1, .landing-page h2, .landing-page h3, .landing-page p,
.landing-page ul, .landing-page ol, .landing-page figure, .landing-page blockquote { margin: 0; }
.landing-page ul, .landing-page ol { padding: 0; list-style: none; }
.landing-page a { color: inherit; }
.landing-page button, .landing-page input, .landing-page select, .landing-page textarea { font: inherit; color: inherit; }
.landing-page svg { display: block; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.wrap { width: 100%; max-width: calc(var(--maxw) + 2 * var(--gut)); margin: 0 auto; padding: 0 var(--gut); }
.landing-page section[id] { scroll-margin-top: var(--hdr-h); }

.landing-page a:focus-visible,
.landing-page button:focus-visible,
.landing-page input:focus-visible,
.landing-page select:focus-visible,
.landing-page textarea:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 8px;
}

.sec-title {
    font-size: clamp(32px, 4.6vw, 64px); line-height: 1.04; letter-spacing: -.035em; font-weight: 700;
    margin-top: 16px; text-wrap: balance;
}

/* Przyciski */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    min-height: 48px; padding: 0 24px; border-radius: 999px; font-weight: 600; font-size: 16px;
    text-decoration: none; border: 1px solid transparent; cursor: pointer; white-space: nowrap;
    transition: background-color .2s, border-color .2s, color .2s, box-shadow .2s;
}
/* .landing-page: wygrywa z `.landing-page a { color: inherit }` (przycisk to <a>). */
.landing-page .btn-primary {
    background: linear-gradient(180deg, #7ab0ee 0%, var(--brand-blue-400) 100%); color: #04122a;
    box-shadow: 0 0 0 1px rgba(var(--brand-glow-soft-rgb), .35), 0 10px 40px -8px rgba(var(--brand-glow-rgb), .75);
}
.btn-primary:hover { background: linear-gradient(180deg, var(--brand-blue-300) 0%, #6aa6ea 100%); }
.btn-primary::after { content: "→" / ""; font-weight: 500; }
.btn-ghost { background: rgba(255, 255, 255, .04); color: var(--ink); border-color: rgba(var(--glow), .35); }
.btn-ghost:hover { border-color: rgba(var(--glow), .7); background: rgba(var(--glow), .08); }
.btn-sm { min-height: 38px; padding: 0 16px; font-size: 14px; }

/* Logo K6 (templates/public/_k6.html) */
.k6 { width: 100%; height: 100%; overflow: visible; }
.k6 .k6-ring { stroke: #a9b3c2; }
.island .k6 .k6-ring, .hdr.on-dark .k6 .k6-ring, html[data-theme="dark"] .k6 .k6-ring { stroke: rgba(var(--brand-mist-rgb), .55); }

/* ---------- Nagłówek ---------- */
.hdr { position: fixed; top: 0; left: 0; right: 0; z-index: 60; height: var(--hdr-h); color: var(--ink); }
.hdr::before {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background: rgba(243, 246, 250, .74); backdrop-filter: saturate(1.6) blur(18px); -webkit-backdrop-filter: saturate(1.6) blur(18px);
    border-bottom: 1px solid rgba(21, 35, 58, .08); transition: background-color .3s, border-color .3s;
}
.hdr.on-dark::before, html[data-theme="dark"] .hdr::before { background: rgba(var(--brand-night-rgb), .55); border-bottom-color: rgba(140, 175, 230, .10); }
.hdr-in { height: 100%; display: flex; align-items: center; gap: 24px; max-width: none; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 20px; letter-spacing: -.02em; flex: none; margin-right: auto; }
.brand-mark { width: 28px; height: 28px; color: var(--accent); }
.hdr-actions { display: flex; align-items: center; gap: 12px; flex: none; }

/* Przełącznik PL/EN (partials/_language_switcher.html) w pigułce */
.landing-page .lang-switcher { padding: 3px; border-radius: 999px; border: 1px solid var(--line); gap: 2px; }
.landing-page .lang-switcher button {
    border: 0; min-width: 36px; min-height: 30px; height: 30px; padding: 0 8px; border-radius: 999px;
    background: none; font-size: 13px; color: var(--muted);
}
.landing-page .lang-switcher button[aria-pressed="true"] { background: rgba(var(--glow), .16); color: var(--ink); }
.landing-page .lang-switcher button:hover { color: var(--ink); }
.landing-page .lang-switcher button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

@media (max-width: 1100px) {
    .hdr-in { gap: 8px; }
    .hdr-actions { gap: 8px; }
}
@media (max-width: 420px) {
    .brand { font-size: 18px; gap: 8px; }
    .brand-mark { width: 24px; height: 24px; }
    .hdr-actions .btn-sm { padding: 0 12px; font-size: 13px; min-height: 36px; }
    .landing-page .lang-switcher button { min-width: 30px; padding: 0 6px; }
}

/* ---------- Wyspy ---------- */
.island { position: relative; color: var(--ink); }
.island-in { position: relative; margin: 0 var(--island-m); border-radius: var(--island-r); background: var(--brand-island-bg); overflow: hidden; overflow: clip; isolation: isolate; }
/* Hero sięga krawędzi okna od góry i z boków: zaokrąglony tylko dół. Wcześniej
   (#51) spod półprzezroczystego nagłówka prześwitywały jasne rogi wyspy. */
.hero .island-in { margin: 0; border-radius: 0 0 var(--island-r) var(--island-r); }

/* ---------- Hero ---------- */
.hero .island-in { min-height: 100vh; min-height: 100svh; display: grid; place-items: center; padding: calc(var(--hdr-h) + 40px) var(--gut) 96px; }
.hero-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero-bg .layer, .hero-bg .plx { position: absolute; inset: 0; }
.l-main { opacity: .95; }
.hero-bg svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.glow { position: absolute; border-radius: 50%; }
.glow.g1 { width: 70vmax; height: 70vmax; left: 50%; top: 50%; margin: -35vmax 0 0 -35vmax; background: radial-gradient(closest-side, rgba(var(--brand-glow-deep-rgb), .42), rgba(var(--brand-glow-deep-rgb), 0)); }
.glow.g2 { width: 50vmax; height: 50vmax; right: -18vmax; bottom: -28vmax; background: radial-gradient(closest-side, rgba(var(--brand-glow-rgb), .20), rgba(var(--brand-glow-rgb), 0)); }
.glow.g3 { width: 40vmax; height: 40vmax; left: -16vmax; top: -18vmax; background: radial-gradient(closest-side, rgba(11, 55, 116, .55), rgba(11, 55, 116, 0)); }
/* Winieta nad logo: przygasza środek K6 za hasłem, okrąg i sześciokąt zostają jasne. */
.hero-vignette { position: absolute; inset: 0; background: radial-gradient(46% 34% at 50% 50%, rgba(var(--brand-night-rgb), .6) 0%, rgba(var(--brand-night-rgb), .3) 60%, rgba(var(--brand-night-rgb), 0) 100%); }
.stars circle { fill: var(--brand-blue-100); }
.noise line { stroke: rgb(var(--brand-glow-rgb)); stroke-opacity: .22; stroke-width: 1; }
/* Światło za kursorem (landing.js: noiseField) - tylko desktop z ruchem. */
.cursor-light { position: absolute; left: 0; top: 0; width: 560px; height: 560px; margin: -280px 0 0 -280px; border-radius: 50%; background: radial-gradient(closest-side, rgba(var(--brand-glow-rgb), .16), rgba(var(--brand-glow-rgb), .05) 55%, rgba(var(--brand-glow-rgb), 0)); opacity: 0; transition: opacity .8s ease; }
.cursor-light.on { opacity: 1; }
.noise circle { fill: #6fa6e8; }
.noise .halo { fill: rgba(var(--brand-glow-rgb), .18); }
.main-net .me { stroke: #7ab0ee; stroke-width: 1.4; stroke-linecap: butt; stroke-dasharray: 1; opacity: .8; }
.main-net .mn-core { fill: var(--brand-blue-100); }
.main-net .mn-halo { fill: rgba(var(--brand-glow-rgb), .22); stroke: rgba(var(--brand-glow-soft-rgb), .5); stroke-width: 1; }
.main-net .mring { stroke: rgba(var(--brand-mist-rgb), .6); stroke-width: 1.4; fill: none; stroke-dasharray: 1; }
/* Siatka wokół złożonego logo (landing.js: netExt): bliższy pierścień jaśniejszy. */
.main-net .net-ext line { stroke: #7ab0ee; stroke-width: 1.2; }
.main-net .ne-in { opacity: .4; }
.main-net .ne-out { opacity: .2; }
.main-net .nx-halo { fill: rgba(var(--brand-glow-rgb), .16); stroke: rgba(var(--brand-glow-soft-rgb), .4); stroke-width: 1; }
.main-net .nx-core { fill: var(--brand-blue-100); }
/* Przepływ po logo (landing.js dokłada .mf na krawędziach i .mring-flow na
   okręgu po złożeniu K6): impulsy światła - „flow” w nFlow. Tylko z ruchem. */
.main-net .mf, .main-net .mring-flow { fill: none; opacity: 0; }
.main-net .mf { stroke: #e3efff; stroke-width: 2.6; stroke-linecap: butt; stroke-dasharray: .12 2.88; stroke-dashoffset: .12; }
.main-net .mring-flow { stroke: #cfe3ff; stroke-width: 2.4; stroke-dasharray: .05 .95; }
@media (prefers-reduced-motion: no-preference) {
    .main-net.flowing .mf { opacity: .95; animation: flow var(--d, 5s) linear var(--dl, 0s) infinite; }
    .main-net.flowing .mring-flow { opacity: .8; transition: opacity 1.2s; animation: ringflow 16s linear infinite; }
}
@keyframes flow { 0% { stroke-dashoffset: .12; } 38%, 100% { stroke-dashoffset: -1; } }
@keyframes ringflow { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: no-preference) {
    .pulse { animation: pulse 3.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
}
@keyframes pulse { 0%, 100% { transform: scale(.7); opacity: .35; } 50% { transform: scale(1.25); opacity: 1; } }

.hero-content { position: relative; text-align: center; max-width: 1200px; }
.hero-title {
    font-size: clamp(38px, 6.4vw, 104px); line-height: 1.0; letter-spacing: -.045em; font-weight: 700;
    text-wrap: balance;
}
.hero-title .l1, .hero-title .l2 { display: block; }
.hero-title .l1 { color: #f2f6fc; }
.hero-title .l2 {
    background: linear-gradient(95deg, var(--brand-blue-100) 0%, var(--brand-blue-300) 45%, var(--brand-blue-400) 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent; padding-bottom: .08em;
}
.hero-rest { margin-top: 28px; }
.hero-sub { font-size: clamp(17px, 1.45vw, 21px); line-height: 1.55; color: #b4c1d6; max-width: 660px; margin: 0 auto; text-wrap: pretty; }
.hero-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 36px; }
.scroll-cue {
    position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 10px;
    font-size: 12px; letter-spacing: .2em; text-transform: uppercase; color: #9fb0c9; text-decoration: none;
}
.scroll-cue i { width: 1px; height: 44px; background: linear-gradient(rgba(var(--brand-glow-soft-rgb), .9), rgba(var(--brand-glow-soft-rgb), 0)); position: relative; overflow: hidden; }
@media (prefers-reduced-motion: no-preference) {
    .scroll-cue i::after { content: ""; position: absolute; left: 0; top: -40%; width: 1px; height: 40%; background: #fff; animation: cue 2s ease-in-out infinite; }
}
@keyframes cue { to { transform: translateY(350%); } }

/* Menu sekcji (od 2026-10-26) i logowanie w nagłówku; na wąskich ekranach
   zostają tylko PL/EN, Logowanie i Kontakt (bez menu rozwijanego, bez JS). */
.hdr-nav { display: flex; gap: 26px; margin-right: 8px; font-size: 14px; }
.hdr-nav a, .hdr-login { color: var(--muted); text-decoration: none; font-weight: 500; }
.hdr-nav a:hover, .hdr-login:hover { color: var(--ink); }
.hdr-login { font-size: 14px; }
@media (max-width: 900px) { .hdr-nav { display: none; } }
@media (max-width: 420px) { .hdr-actions .btn-sm { display: none; } }

/* =====================================================================
   SEKCJE POD HERO - wariant D „Pokaz” (2026-10-26)
   Pasy jasne (.band) i ciemne (.band-dark.island) na przemian. Ciemne
   biorą paletę wyspy (.island), więc nagłówek nad nimi też ciemnieje.
   ===================================================================== */
body.landing-page {
    --ok: #17794a; --ok-bg: #e7f6ee;
    --warn: #a35f00; --warn-bg: #fdf1dc;
    --grey: #4f5b6d; --grey-bg: #eaeef4;
    --sheet-bg: #ffffff;
    --sheet-soft: #f1f4f8;
    --sheet-line: #e0e5ec;
    --shot-shadow: 0 50px 120px -50px rgba(3, 10, 23, .75);
}
html[data-theme="dark"] body.landing-page {
    --ok: #7fd6a6; --ok-bg: #0f2e1f;
    --warn: #f2c066; --warn-bg: #33250b;
    --grey: #a9b5c8; --grey-bg: #1a263a;
    --sheet-bg: #0b1730;
    --sheet-soft: #0f1f38;
    --sheet-line: #22344f;
    --shot-shadow: 0 50px 120px -40px rgba(0, 0, 0, .9);
}
/* Na ciemnym pasie pigułki i tabele mają kolory nocne niezależnie od motywu. */
.band-dark {
    --ok: #7fd6a6; --ok-bg: rgba(79, 209, 139, .14);
    --warn: #f2c066; --warn-bg: rgba(242, 192, 102, .14);
    --grey: var(--brand-island-muted); --grey-bg: rgba(143, 189, 242, .10);
}

/* Sekcja = „slajd”: na desktopie cała (nagłówek, lead, obraz) mieści się
   w jednym ekranie pod nagłówkiem strony - mniejsze odstępy pionowe w vh,
   nagłówki do 52 px, ekrany aplikacji ograniczone wysokością okna. */
.band { position: relative; padding: clamp(40px, 7vh, 88px) 0; }
.band-first { padding-top: clamp(40px, 7vh, 80px); }
.band-dark { background: var(--brand-island-bg); color: var(--ink); }
html[data-theme="dark"] .band-dark { background: linear-gradient(180deg, #0a1a33 0%, #071329 100%); }
.band-sm { padding: clamp(36px, 6vh, 72px) 0; }

.head { display: grid; gap: 14px; max-width: 1040px; margin-bottom: clamp(20px, 3.5vh, 40px); }
.head .sec-title { margin-top: 0; }
.band .sec-title { font-size: clamp(30px, 3.5vw, 52px); }
.lead { font-size: clamp(17px, 1.35vw, 20px); line-height: 1.45; color: var(--muted); max-width: 46em; text-wrap: pretty; }
.band-sm .sec-title { font-size: clamp(28px, 3vw, 44px); }
.band-sm .lead { font-size: clamp(16px, 1.25vw, 18px); }

/* Jasna „kartka” z makietą (rejestr procedur, mapa procesów). */
.sheet-card {
    background: var(--sheet-bg); border: 1px solid var(--card-edge); border-radius: 18px;
    padding: clamp(14px, 2vw, 24px); box-shadow: var(--shadow-lg); min-width: 0;
}

/* Prawdziwy ekran aplikacji (tools/landing_media.py). Duży ekran sekcji
   (Procesy, Nat) ma szerokość wynikającą z wysokości okna: proporcje 16:10,
   wysokość najwyżej okno minus nagłówek strony, nagłówek sekcji i odstępy. */
.screen { margin: 0; border-radius: 16px; overflow: hidden; background: #081427; border: 1px solid rgba(140, 175, 230, .18); box-shadow: var(--shot-shadow); }
.screen img { display: block; width: 100%; height: auto; }
@media (min-width: 900px) and (min-height: 600px) {
    .band.slide { height: calc(100vh - var(--hdr-h)); display: flex; flex-direction: column; }
    .band.slide > .wrap { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
    .band.slide .media { flex: 1 1 auto; min-height: 0; display: flex; justify-content: center; }
    .band.slide .media > .screen { height: 100%; aspect-ratio: 16 / 10; max-width: 100%; }
    .band.slide .media > .screen img { height: 100%; object-fit: contain; }
    .band.slide .shots-tabs { display: grid; grid-template-rows: auto minmax(0, 1fr); justify-items: center; width: 100%; }
    .band.slide .shots-tabs .shot { height: 100%; aspect-ratio: 16 / 10; max-width: 100%; }
    .band.slide .shots-tabs .shot img { height: 100%; object-fit: contain; }
}
/* Procesy i Nat na szerokim ekranie: tekst z lewej, zrzut z prawej - obraz
   jest wtedy większy niż pod dwuliniowym nagłówkiem i leadem. */
/* Sekcje z dużym ekranem mają szerszy kontener (do 1680 px): tekst wąską
   kolumną (ok. 28%), ekran resztą szerokości (runda 3). */
.band.slide > .wrap, .band.demo > .wrap { max-width: calc(1680px + 2 * var(--gut)); }
@media (min-width: 1100px) and (min-height: 600px) {
    .band.slide.duo > .wrap { flex-direction: row; align-items: center; column-gap: clamp(28px, 3vw, 56px); }
    .band.slide.duo .head { flex: 0 0 28%; margin: 0; }
    .band.slide.duo .media { align-self: stretch; align-items: center; }
    /* Szerokość z wysokości okna (16:10): na niskim, szerokim ekranie zrzut się nie ucina. */
    .band.slide.duo .media > .screen { height: auto; width: min(100%, calc((100vh - var(--hdr-h) - 2 * clamp(40px, 7vh, 88px)) * 1.6)); }
    .band.slide.duo .media > .screen img { height: auto; }
    .band.slide.duo .sec-title { font-size: clamp(28px, 2.5vw, 42px); }
    .band.slide.duo .shots-tabs { flex: 0 1 auto; align-self: center; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto; width: min(100%, calc((100vh - var(--hdr-h) - 2 * clamp(36px, 6vh, 72px) - 56px) * 1.6)); }
    .band.slide.duo .shots-tabs .shot { height: auto; width: 100%; }
    .band.slide.duo .shots-tabs .shot img { height: auto; }
}

/* ---------- Jak pracujemy: trzy kroki i duży ekran z klipami ---------- */
/* landing.js (.demo.is-live) odtwarza klipy po kolei i ustawia --p (0-1)
   na aktywnym kroku: pasek nad krokiem wypełnia się jak postęp. Bez JS:
   wszystkie kroki pełne, ekran pokazuje kadr startowy kroku 1. */
.journey { display: grid; gap: 16px; }
.jstep { --p: 0; position: relative; display: grid; gap: 6px; align-content: start; padding: 16px 0 0 20px; min-width: 0; transition: opacity .4s ease; }
.jstep::after { content: ""; position: absolute; top: -5px; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--line); box-shadow: 0 0 0 4px var(--bg); transition: background-color .3s; }
.jstep.is-on::after, .demo:not(.is-live) .jstep::after { background: var(--accent); }
.jbar { position: absolute; top: 0; left: 0; right: 0; height: 2px; background: var(--line); overflow: hidden; }
.jbar i { display: block; height: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(var(--p)); }
.demo:not(.is-live) .jbar i { transform: scaleX(1); }
.demo.is-live .jstep { cursor: pointer; opacity: .5; }
.demo.is-live .jstep:hover, .demo.is-live .jstep:focus-visible { opacity: .8; }
.demo.is-live .jstep.is-on { opacity: 1; }
.jstep:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 6px; }
.jno { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.jstep h3 { font-size: clamp(18px, 1.4vw, 21px); letter-spacing: -.02em; line-height: 1.15; }
.jstep p { color: var(--muted); font-size: 14.5px; line-height: 1.5; }
.demo .head { margin-bottom: clamp(16px, 3vh, 28px); }
.demo-stage { display: grid; margin-top: 28px; }
.demo-item { grid-area: 1 / 1; display: grid; aspect-ratio: 16 / 10; width: 100%; }
.demo-item:not(.is-on) { visibility: hidden; opacity: 0; }
.demo-clip { grid-area: 1 / 1; display: block; width: 100%; height: 100%; object-fit: cover; background: #081427; }
.demo-clip:not(.is-on) { visibility: hidden; opacity: 0; }
.demo.is-live .demo-item, .demo.is-live .demo-clip { transition: opacity .7s ease, visibility .7s; }
@media (min-width: 1100px) and (min-height: 600px) {
    .band.demo { height: calc(100vh - var(--hdr-h)); display: flex; flex-direction: column; }
    .band.demo > .wrap { flex: 1 1 auto; min-height: 0; display: flex; align-items: center; column-gap: clamp(28px, 3vw, 56px); }
    .demo-text { flex: 0 0 30%; min-width: 0; }
    .demo .sec-title { font-size: clamp(28px, 2.5vw, 42px); }
    .demo-stage { flex: 1 1 auto; min-width: 0; margin: 0; align-self: stretch; align-content: center; }
    .demo-item { width: min(100%, calc((100vh - var(--hdr-h) - 2 * clamp(40px, 7vh, 80px)) * 1.6)); justify-self: center; }
}
@media (prefers-reduced-motion: reduce) {
    .jstep, .jstep::after, .demo.is-live .demo-item, .demo.is-live .demo-clip { transition: none; }
}

/* Przełącznik zrzutów w sekcji Projekty (landing.js): obrazy na sobie, widoczny .is-on. Bez JS
   (i do jego startu) drugi obraz jest schowany, kropki ukryte atrybutem. */
.shots { display: grid; }
.shots .shot { grid-area: 1 / 1; }
.shots-tabs .shot { grid-area: 2 / 1; }
.shots-tabs .shot-dots { grid-row: 1; flex-wrap: wrap; margin: 0 0 14px; }
.shots .shot:not(.is-on) { visibility: hidden; opacity: 0; }
.shots.is-live .shot { transition: opacity .6s ease, visibility .6s; }
.shot-dots { display: flex; justify-content: center; gap: 8px; margin-top: 12px; }
.shot-dots[hidden] { display: none; }
.shot-dot {
    border: 1px solid var(--line); background: var(--sheet-bg); color: var(--muted); border-radius: 999px;
    padding: 4px 12px; font-size: 13px; font-weight: 600; cursor: pointer;
}
.shot-dot[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.band-dark .shot-dot { background: rgba(143, 189, 242, .06); }
.band-dark .shot-dot[aria-pressed="true"] { background: var(--brand-blue-300); border-color: var(--brand-blue-300); color: #04122a; }
.shot-dot:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .shots.is-live .shot { transition: none; } }

/* ---------- Repozytorium procedur (makieta) ---------- */
.repo { display: grid; grid-template-columns: minmax(150px, 190px) minmax(0, 1fr); border: 1px solid var(--sheet-line); border-radius: 14px; overflow: hidden; }
.repo-tree { background: var(--sheet-soft); padding: 10px; display: grid; gap: 2px; align-content: start; font-size: 13px; border-right: 1px solid var(--sheet-line); }
.repo-tree .lbl { padding: 2px 8px 8px; }
.repo-tree span:not(.lbl) { display: flex; justify-content: space-between; gap: 8px; padding: 5px 10px; border-radius: 8px; color: var(--muted); }
.repo-tree span.on { background: var(--sheet-bg); color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
.repo-tree i { font-style: normal; color: var(--faint); font-size: 11px; font-variant-numeric: tabular-nums; }
.repo-list { padding: 6px 18px; min-width: 0; }
.repo-top { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 8px 0 6px; border-bottom: 1px solid var(--sheet-line); font-size: 12px; color: var(--faint); }
.chip-btn { font-size: 12px; font-weight: 550; padding: 4px 10px; border-radius: 8px; border: 1px solid var(--sheet-line); color: var(--ink); background: var(--sheet-bg); }
.repo-top .sp { margin-left: auto; }
.prow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 16px; padding: 9px 0; border-bottom: 1px solid var(--sheet-line); align-items: center; }
.prow:last-child { border-bottom: 0; }
.prow .pt { font-weight: 600; font-size: 15px; }
.prow .ps { font-size: 13px; color: var(--faint); grid-column: 1; }
.prow .pill { grid-row: 1 / span 2; grid-column: 2; justify-self: end; }
.ack { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); }
.bar { flex: 1; height: 6px; border-radius: 99px; background: var(--grey-bg); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--ok); border-radius: 99px; }
.bar .w86 { width: 86%; }
.bar .w100 { width: 100%; }

/* ---------- Korzyści: sześć sytuacji (problem -> rozwiązanie) ---------- */
/* Każda karta ma dwie strony: problem (ikona przypadku w kolorze ostrzegawczym,
   przygaszone tło) i rozwiązanie z nFlow (zielony ptaszek, tytuł, opis). Bez JS
   widać samo rozwiązanie (pełna treść). landing.js: .flip-ready pokazuje
   problemy, a po wjeździe sekcji karty odwracają się kolejno (.is-flipped);
   kliknięcie lub dotknięcie odwraca kartę z powrotem. Przy reduced-motion
   (.flip-soft) strony tylko się przenikają, bez obrotu. */
.sits { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; perspective: 1600px; }
.sit { min-width: 0; }
.sit-inner { position: relative; display: grid; height: 100%; transform-style: preserve-3d; transition: transform .9s cubic-bezier(.2, .75, .2, 1); }
.sit-face {
    grid-area: 1 / 1; background: var(--sheet-bg); border: 1px solid var(--card-edge); border-radius: 18px; padding: 22px;
    display: grid; grid-template-columns: 40px minmax(0, 1fr); column-gap: 14px; row-gap: 6px; align-content: start;
    backface-visibility: hidden; -webkit-backface-visibility: hidden; transition: border-color .25s ease, box-shadow .25s ease;
}
.sit-problem { display: none; background: var(--sheet-soft); align-content: center; }
.sit-ico { grid-row: span 2; width: 34px; height: 34px; color: var(--accent); }
.sit-ico-warn { color: var(--warn); }
.sit-ico-ok { color: var(--ok); }
.sit-title { font-size: 20px; font-weight: 700; letter-spacing: -.015em; line-height: 1.2; align-self: center; color: var(--muted); }
.sit h3 { font-size: 19px; letter-spacing: -.015em; line-height: 1.2; align-self: center; }
.sit p:not(.sit-title) { color: var(--muted); font-size: 15px; line-height: 1.5; }
.sits.flip-ready .sit { cursor: pointer; }
.sits.flip-ready .sit-problem { display: grid; }
.sits.flip-ready .sit-solution { transform: rotateY(180deg); }
.sits.flip-ready .sit.is-flipped .sit-inner { transform: rotateY(180deg); }
.sits.flip-ready .sit:hover .sit-face, .sits.flip-ready .sit:focus-visible .sit-face { border-color: var(--accent); box-shadow: 0 18px 40px -24px rgba(var(--glow), .55); }
.sit:focus-visible { outline: none; }
.sits.flip-soft .sit-inner, .sits.flip-soft .sit.is-flipped .sit-inner { transform: none; transition: none; }
.sits.flip-soft .sit-solution { transform: none; opacity: 0; transition: opacity .6s ease; }
.sits.flip-soft .sit-problem { transition: opacity .6s ease; }
.sits.flip-soft .sit.is-flipped .sit-solution { opacity: 1; }
.sits.flip-soft .sit.is-flipped .sit-problem { opacity: 0; }

/* ---------- Poza tym: siatka kafelków ---------- */
/* landing.js: .reveal-ready chowa kafelki, .is-in po wjeździe sekcji (40%)
   uruchamia wejście: kafelki zbierają się z rozproszenia w siatkę falą po
   przekątnej (5 kolumn: --d = (kolumna + wiersz) x 90 ms), ikony się rysują
   (pathLength=1), po zebraniu krótki rozbłysk krawędzi. Wejście animacją
   z wypełnieniem „backwards”, więc potem działa zwykły hover. Reduced-motion
   (.reveal-soft): samo przenikanie. */
.fgrid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
.ftile {
    --d: 0s; --sx: 0px; --sy: 0px; --sr: 0deg;
    background: rgba(143, 189, 242, .05); border: 1px solid var(--line); border-radius: 16px; padding: 18px;
    display: grid; gap: 6px; align-content: start; transition: transform .25s ease, border-color .25s ease, background-color .25s ease;
}
.ftile:hover { transform: translateY(-5px); border-color: var(--brand-blue-300); background: rgba(143, 189, 242, .09); }
.ftile-ico { width: 30px; height: 30px; color: var(--brand-blue-300); margin-bottom: 4px; transition: transform .3s ease; }
.ftile:hover .ftile-ico { transform: scale(1.18) rotate(-8deg); }
.ftile h3 { font-size: 16px; letter-spacing: -.01em; }
.ftile p { font-size: 14px; color: var(--muted); }
.fgrid.reveal-ready .ftile { opacity: 0; }
.fgrid.reveal-ready .ftile-ico * { stroke-dasharray: 1; stroke-dashoffset: 1; }
.fgrid.is-in .ftile { opacity: 1; animation: ftile-in .9s cubic-bezier(.2, .8, .2, 1) var(--d) backwards, ftile-glow 1.3s ease calc(var(--d) + .7s) backwards; }
.fgrid.is-in .ftile-ico * { stroke-dashoffset: 0; transition: stroke-dashoffset 1.2s ease calc(var(--d) + .35s); }
.fgrid.reveal-soft.is-in .ftile { animation: none; transition: opacity .7s ease var(--d); }
.fgrid.reveal-soft.reveal-ready .ftile-ico * { stroke-dashoffset: 0; }
@keyframes ftile-in {
    from { opacity: 0; transform: translate(var(--sx), var(--sy)) scale(.8) rotate(var(--sr)); }
    to { opacity: 1; transform: none; }
}
@keyframes ftile-glow {
    0%, 100% { border-color: var(--line); box-shadow: none; }
    35% { border-color: var(--brand-blue-300); box-shadow: 0 0 0 1px rgba(var(--brand-glow-soft-rgb), .4), 0 0 30px -4px rgba(var(--brand-glow-rgb), .75); }
}
.ftile:nth-child(1) { --sx: -70px; --sy: -50px; --sr: -8deg; }
.ftile:nth-child(2) { --d: .09s; --sx: -20px; --sy: -80px; --sr: 5deg; }
.ftile:nth-child(3) { --d: .18s; --sx: 10px; --sy: -70px; --sr: -4deg; }
.ftile:nth-child(4) { --d: .27s; --sx: 40px; --sy: -60px; --sr: 7deg; }
.ftile:nth-child(5) { --d: .36s; --sx: 80px; --sy: -40px; --sr: -6deg; }
.ftile:nth-child(6) { --d: .09s; --sx: -80px; --sy: 50px; --sr: 6deg; }
.ftile:nth-child(7) { --d: .18s; --sx: -30px; --sy: 80px; --sr: -5deg; }
.ftile:nth-child(8) { --d: .27s; --sx: 20px; --sy: 70px; --sr: 4deg; }
.ftile:nth-child(9) { --d: .36s; --sx: 50px; --sy: 60px; --sr: -7deg; }
.ftile:nth-child(10) { --d: .45s; --sx: 90px; --sy: 40px; --sr: 8deg; }
@media (prefers-reduced-motion: reduce) {
    .sit-face, .ftile, .ftile-ico { transition: none; }
    .ftile:hover { transform: none; }
    .ftile:hover .ftile-ico { transform: none; }
}

/* ---------- Responsywność sekcji ---------- */
@media (max-width: 1100px) {
    .fgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
    .sits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .sits { grid-template-columns: minmax(0, 1fr); }
    .fgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .repo { grid-template-columns: minmax(0, 1fr); }
    .repo-tree { border-right: 0; border-bottom: 1px solid var(--sheet-line); grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .repo-tree .lbl { grid-column: 1 / -1; }
    .repo-top .sp { margin-left: 0; width: 100%; }
    .screen { border-radius: 10px; }
}

/* ---------- Opinie ---------- */
.q-list { display: grid; gap: 24px; margin-top: 40px; }
.q-list figure { padding: 32px; border-radius: 24px; background: var(--bg-raise); border: 1px solid var(--card-edge); box-shadow: var(--shadow-lg); position: relative; }
.q-list blockquote p { font-size: clamp(20px, 2vw, 26px); line-height: 1.4; letter-spacing: -.015em; font-weight: 500; }
.q-list blockquote p::before { content: "\201C"; display: block; font-size: 64px; line-height: .8; color: var(--accent); text-shadow: 0 0 24px rgba(var(--glow), .6); }
.q-list figcaption { margin-top: 18px; color: var(--muted); font-size: 15px; }
@media (min-width: 768px) { .q-list { grid-template-columns: 1fr 1fr; } }

/* ---------- Kontakt (templates/public/_contact_section.html) ---------- */
/* Jedna kolumna (runda 4): nagłówek i lead wyśrodkowane, formularz pod nimi (do 780 px). */
.contact-in { display: grid; gap: 12px; justify-items: center; text-align: center; }
.contact .sec-title { margin-top: 0; }
.contact .lead { max-width: 34em; }
.contact .form { width: 100%; max-width: 780px; margin-top: 6px; text-align: left; }
.band.contact { padding: clamp(32px, 5vh, 64px) 0; }
.contact .sec-title { font-size: clamp(28px, 3vw, 44px); }
.contact .fld textarea { min-height: 68px; }
.more { color: var(--accent); font-weight: 600; text-decoration: none; }
.more::after { content: " ›"; }
.more:hover { text-decoration: underline; }
.contact-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px 24px; margin-top: 6px; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }
.fld-check label { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; font-size: 14px; line-height: 1.45; }
.fld-check input[type="checkbox"] { width: 18px; height: 18px; min-height: 0; margin: 2px 0 0; flex: none; accent-color: var(--accent); }
.fld-check a { color: var(--accent); }
/* Przycisk główny na jasnym tle (poza wyspą) */
html:not([data-theme="dark"]) .contact .btn-primary {
    background: linear-gradient(180deg, #1d66bd 0%, var(--brand-blue-600) 100%); color: #fff;
    box-shadow: 0 10px 30px -10px rgba(var(--brand-glow-deep-rgb), .6);
}
.form { display: grid; gap: 10px 14px; padding: clamp(16px, 2vw, 24px); border-radius: 24px; background: var(--bg-raise); border: 1px solid var(--card-edge); box-shadow: var(--shadow-lg); }
.fld { display: grid; gap: 6px; min-width: 0; }
.fld label { font-size: 14px; font-weight: 600; }
.fld input, .fld select, .fld textarea {
    width: 100%; min-height: 44px; padding: 9px 12px; border-radius: 12px; border: 1px solid #b9c4d3; background: var(--bg);
    font-size: 16px; color: var(--ink);
}
html[data-theme="dark"] .fld input, html[data-theme="dark"] .fld select, html[data-theme="dark"] .fld textarea { background: #061022; border-color: #2e4466; }
.fld textarea { resize: vertical; min-height: 84px; }
.fld [aria-invalid="true"] { border-color: var(--brand-danger-text); }
.fld .errorlist, .contact-errors .errorlist { margin: 0; padding: 0; list-style: none; color: var(--brand-danger-text); font-size: 14px; font-weight: 600; }
.fld .helptext { color: var(--muted); font-size: 13px; }
.contact-status, .contact-errors { padding: 12px 16px; border-radius: 12px; font-size: 15px; font-weight: 600; }
.contact-status { background: var(--brand-success-bg); border: 1px solid var(--brand-success-border); color: var(--brand-success-text); }
.contact-errors { background: var(--brand-danger-bg); border: 1px solid var(--brand-danger-border); }
.contact-hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.privacy { font-size: 13px; color: var(--muted); line-height: 1.5; }

@media (min-width: 768px) {
    .form { grid-template-columns: 1fr 1fr; }
    .form .full { grid-column: 1 / -1; }
}



/* ---------- Stopka ---------- */
.ftr { padding-bottom: var(--island-m); }
.ftr .island-in { padding: 56px var(--gut) 40px; }
.ftr-grid { display: grid; gap: 28px; max-width: var(--maxw); margin: 0 auto; }
.ftr-brand { display: flex; align-items: center; gap: 16px; }
.ftr-k6 { width: 48px; height: 48px; color: var(--brand-blue-400); flex: none; }
.ftr-name { font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
.ftr-tag { color: var(--muted); font-style: italic; font-size: 15px; }
.ftr-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.ftr-links a { color: var(--muted); text-decoration: none; font-weight: 500; }
.ftr-links a:hover { color: var(--ink); }
.ftr-copy { color: var(--muted); font-size: 14px; }
.ftr-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding-top: 24px; border-top: 1px solid var(--line); }
@media (min-width: 768px) {
    .ftr-grid { grid-template-columns: 1fr auto; align-items: center; }
    .ftr-bottom { grid-column: 1 / -1; }
}
