/* Koncept Q — miks: hero z pikseli (A), oferta (B), proces w warstwach (I), font Plus Jakarta Sans */

:root {
  --font-display: "Plus Jakarta Sans", ui-sans-serif, system-ui, sans-serif;
  --font-body: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --font-label: "Plus Jakarta Sans", ui-sans-serif, system-ui, sans-serif;
}
.concept-q { letter-spacing: -0.01em; }
.concept-q main { z-index: auto; }
.pn { margin-left: -0.075em; }

/* etykiety i drobne napisy w Jakarta zamiast monospace — kod na makietach zostaje w monospace */
.concept-q .eyebrow, .concept-q .svc-label, .concept-q .price small, .concept-q .rail button span,
.concept-q .step-num, .concept-q .nav-phone, .concept-q .portal-num, .concept-q .portal-price, .concept-q .cta-phone small {
  font-family: var(--font-label); font-weight: 700; letter-spacing: 0.12em;
}
.concept-q .nav-phone { letter-spacing: 0.02em; font-weight: 600; }
.concept-q .h1, .concept-q .h2, .concept-q .h3 { font-weight: 800; }
.concept-q .h2 { letter-spacing: -0.05em; }
.concept-q .h3 { font-weight: 700; letter-spacing: -0.03em; }
.concept-q .price strong { font-weight: 800; letter-spacing: -0.045em; }
.concept-q .lw-text strong, .concept-q .la-head strong, .concept-q .la-num { font-weight: 800; letter-spacing: -0.045em; }
.concept-q .logo { font-weight: 800; letter-spacing: -0.04em; }
.concept-q .btn { font-weight: 700; }

/* ---------- piksele ---------- */
.px { position: fixed; left: 0; top: 0; z-index: 2; pointer-events: none; }
.no-px .px { display: none; }
.concept-q .nav { z-index: 60; }

/* ---------- hero ---------- */
.hero-q { position: relative; min-height: 100vh; min-height: 100svh; display: grid; align-items: center; padding: calc(var(--nav-h) + 40px) 0 110px; }
.hero-q::before { content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: radial-gradient(50% 55% at 74% 50%, rgba(79, 123, 255, 0.1), transparent 70%), radial-gradient(40% 50% at 20% 80%, rgba(46, 240, 160, 0.05), transparent 70%);
  /* poświaty gasną przed dolną krawędzią, żeby między hero a ofertą nie było widać cięcia */
  -webkit-mask-image: linear-gradient(#000 50%, transparent 97%); mask-image: linear-gradient(#000 50%, transparent 97%); }
.hero-q-in { position: relative; z-index: 3; display: grid; gap: 26px; justify-items: start; }
.hero-title { margin: -0.1em 0 -0.14em; padding: 0.1em 0 0.14em; max-width: 11ch; font-family: var(--font-display); font-size: clamp(50px, 7.6vw, 118px); font-weight: 800; line-height: 0.95; letter-spacing: -0.06em; text-wrap: balance; }
.hero-q .lead { max-width: 46ch; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 4px; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 8px 26px; margin-top: 10px; font-size: 14px; color: var(--dim); }
.hero-facts li { display: flex; align-items: center; gap: 8px; }
.hero-facts li::before { content: ""; width: 6px; height: 6px; background: var(--dim); }
.hero-facts li:nth-child(1)::before { background: var(--blue); } .hero-facts li:nth-child(2)::before { background: var(--green); } .hero-facts li:nth-child(3)::before { background: var(--red); }
.hero-facts b { color: var(--text); font-weight: 700; }
.hero-hint { position: absolute; z-index: 3; right: var(--gutter); bottom: 34px; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--dim); }
.hero-hint i { width: 7px; height: 7px; background: var(--green); box-shadow: 0 0 0 4px rgba(46, 240, 160, 0.15); animation: blink 1.6s steps(2, start) infinite; }
@keyframes blink { 50% { opacity: 0.25; } }
.hero-scroll { position: absolute; z-index: 3; left: 50%; bottom: 26px; translate: -50% 0; display: grid; justify-items: center; gap: 10px; font-size: 12.5px; font-weight: 600; letter-spacing: 0.04em; color: var(--muted); }
.hero-scroll i { width: 1px; height: 38px; background: linear-gradient(var(--text), transparent); transform-origin: top; animation: drip 2.2s ease-in-out infinite; }
@keyframes drip { 0% { transform: scaleY(0); } 55% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }
.m-touch { display: none; } .touch .m-touch { display: inline; } .touch .m-mouse { display: none; }
.js .q-in { opacity: 0; transform: translateY(22px); transition: opacity 1.1s var(--ease), transform 1.3s var(--ease); transition-delay: var(--d, 0s); }
.ready .q-in { opacity: 1; transform: none; }
.hero-scroll.q-in { transform: none; }

/* oferta: tła światów leżą pod warstwą pikseli, treść (scena, opisy) nad nią */
/* dłuższa scena: najpierw okno składa się z pikseli, na końcu plakat rozsypuje się — oba etapy na przypiętej scenie */
.concept-q .worlds { height: 560vh; }
.concept-q .worlds-bg { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.concept-q .worlds-sticky { z-index: 3; margin-top: -100vh; margin-top: -100svh; }
.concept-q .crop { filter: opacity(var(--px-out, 1)); }

/* ---------- proces: cztery warstwy (z konceptu I) ---------- */
.layers { position: relative; height: 260vh; }
.layers-sticky { position: sticky; top: 0; height: 100vh; height: 100svh; display: flex; align-items: center; overflow: hidden; }
.layers-sticky::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(45% 55% at 70% 50%, rgba(79, 123, 255, 0.08), transparent 70%); }
.layers-grid { position: relative; display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: 40px; align-items: center; }
.layers-copy { display: grid; gap: 26px; justify-items: start; }
.layers-copy .h2 { font-size: clamp(34px, 4vw, 58px); }
.lsteps { display: grid; gap: 6px; width: 100%; }
.lsteps li { display: grid; grid-template-columns: 44px 1fr; gap: 6px; padding: 14px 16px; border-radius: 16px; border: 1px solid transparent; opacity: 0.4; transition: opacity 0.5s, background-color 0.5s, border-color 0.5s; }
.lsteps li > span { font-size: 13px; font-weight: 800; color: var(--c); padding-top: 3px; }
.lsteps b { font-size: 19px; font-weight: 800; letter-spacing: -0.03em; }
.lsteps p { margin-top: 4px; font-size: 15px; color: var(--muted); }
.lsteps li.on { opacity: 1; background: rgba(255, 255, 255, 0.035); border-color: var(--line); }
.layers-stage { position: relative; height: min(70vh, 640px); perspective: 2200px; display: grid; place-items: center; }
.stack { --p: 0; position: relative; width: min(560px, 44vw); aspect-ratio: 1280 / 800; transform-style: preserve-3d; transform: rotateX(calc(52deg * var(--p) + 4deg)) rotateZ(calc(-32deg * var(--p))) translateY(calc(var(--p) * 40px)); }
.ly { position: absolute; inset: 0; transform-style: preserve-3d; transform: translateZ(calc(var(--i) * (var(--p) * var(--sp, 95px) + 0.6px))); }
.ly-in { --k: 0.4; position: absolute; inset: 0; overflow: hidden; border-radius: 10px; background: #f5efe6; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12), 0 30px 60px -30px rgba(0, 0, 0, 0.8); transition: box-shadow 0.5s; }
.ly-m { position: absolute; left: 0; top: 0; transform: scale(var(--k)); transform-origin: 0 0; }
.ly:nth-child(1) .ly-in { background: #061a2c; }
.ly-code .ly-in { background: rgba(9, 12, 20, 0.95); padding: 6% 7%; }
.ly-code pre { margin: 0; font: 400 clamp(8px, 0.95vw, 13.5px)/1.65 var(--font-mono); color: #c9d1d9; white-space: pre; }
.ly-code .k { color: #ff7ab8; } .ly-code .a { color: #6ee7ff; } .ly-code .s { color: #a5e075; } .ly-code .p { color: #c3a6ff; } .ly-code .n { color: #ffcf70; } .ly-code .c { color: #ff9e64; }
/* kod jest „szybą” widoczną dopiero po rozsunięciu; górna warstwa (gotowa strona) zawsze pełna, żeby nic nie prześwitywało */
.ly-code .ly-in { opacity: calc(var(--p) * 2.2); }
.live { position: absolute; right: 4%; top: 5%; display: inline-flex; align-items: center; gap: 7px; padding: 5px 10px; border-radius: 999px; background: #fff; color: #15803d; font: 700 11px var(--font-body); box-shadow: 0 6px 16px -6px rgba(0, 0, 0, 0.4); }
.live i { width: 7px; height: 7px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.25); }
.ly-tag { position: absolute; left: -14px; top: 50%; translate: -100% -50%; font-size: 12px; font-weight: 800; letter-spacing: 0.06em; color: var(--c); white-space: nowrap; opacity: var(--p); }
.ly-tag::after { content: ""; display: inline-block; width: 26px; height: 2px; margin-left: 8px; vertical-align: middle; background: var(--c); }
.stack[data-step="0"] .ly:nth-child(1) .ly-in, .stack[data-step="1"] .ly:nth-child(2) .ly-in,
.stack[data-step="2"] .ly:nth-child(3) .ly-in, .stack[data-step="3"] .ly:nth-child(4) .ly-in { box-shadow: 0 0 0 2px var(--c), 0 30px 70px -20px var(--c); }

@media (max-width: 860px) {
  .hero-q { align-items: end; padding-top: calc(var(--nav-h) + 38vh); padding-bottom: 90px; }
  .hero-title { font-size: clamp(42px, 12vw, 64px); }
  .hero-ctas .btn { flex: 1 1 auto; }
  /* fakty: trzy kolumny w jednym rzędzie — wartość na górze, podpis pod nią */
  .hero-facts { display: grid; grid-template-columns: repeat(3, auto); justify-content: space-between; gap: 0 12px; width: 100%; margin-top: 2px; }
  .hero-facts li { display: grid; grid-template-columns: auto auto; justify-content: start; align-items: center; gap: 5px 7px; }
  .hero-facts li span { grid-column: 1 / -1; font-size: 12.5px; line-height: 1.35; }
  .hero-facts b { font-size: 15.5px; letter-spacing: -0.02em; }
  .hero-hint { left: var(--gutter); right: auto; bottom: 30px; }
  .hero-scroll { display: none; }
  .layers { height: 240vh; }
  .layers-sticky { align-items: flex-start; padding-top: 74px; }
  .layers-grid { grid-template-columns: 1fr; gap: 10px; }
  .layers-copy { gap: 14px; }
  .layers-copy .h2 { font-size: 30px; }
  .lsteps li { padding: 8px 10px; }
  .lsteps li:not(.on) p { display: none; }
  .layers-stage { order: -1; height: 34vh; margin-top: 10px; }
  /* na telefonie warstwy rozsuwają się mniej, a cały stos schodzi w dół, żeby górna warstwa nie chowała się pod menu */
  .stack { --sp: 52px; width: min(280px, 62vw); translate: 0 calc(var(--p) * 48px); }
  /* zakładki usług na dole sceny: pod kciukiem, a okno zaczyna się tuż pod menu */
  .concept-q .worlds { height: 520vh; }
  .concept-q .worlds-grid { padding-top: calc(var(--nav-h) + 14px); padding-bottom: calc(74px + env(safe-area-inset-bottom, 0px)); }
  .concept-q .rail { top: auto; bottom: calc(14px + env(safe-area-inset-bottom, 0px)); }
  .ly-tag { font-size: 10px; left: -8px; }
  .ly-tag::after { width: 12px; margin-left: 5px; }
}
@media (prefers-reduced-motion: reduce) {
  .js .q-in { opacity: 1; transform: none; transition: none; }
  .hero-hint i, .hero-scroll i { animation: none; }
}

/* =========================================================
   Warstwa pikseli dla całej strony (q-px.js)
   ========================================================= */
/* piksele: nad tłem sekcji, pod treścią (oferta jest cała pod pikselami) */
.concept-q .section > .wrap, .concept-q .layers-sticky { position: relative; z-index: 3; }
.concept-q .layers-sticky { position: sticky; }
.concept-q .footer { z-index: auto; }
.concept-q .footer > .wrap { position: relative; z-index: 3; }

/* elementy budowane z pikseli są niewidoczne, dopóki piksele ich nie złożą */
.js .px-hide { clip-path: polygon(0 0, 0 0, 0 0); }
.no-px .px-hide { clip-path: none !important; }

/* teksty odsłaniane przez piksele: maska jedzie od lewej; zapas na akcenty i ogonki liter */
.js [data-sweep] { -webkit-mask-image: linear-gradient(transparent, transparent); mask-image: linear-gradient(transparent, transparent); }
.no-px [data-sweep] { -webkit-mask-image: none !important; mask-image: none !important; }
.concept-q .h2[data-sweep] { padding-block: 0.12em; margin-block: -0.12em; }

/* skok do dalekiej sekcji: kafelki w kolorze tła na chwilę zakrywają ekran (pod menu); q.js */
.jump-veil { position: fixed; inset: 0; z-index: 55; width: 100%; height: 100%; pointer-events: none; visibility: hidden; }
.concept-q [tabindex="-1"]:focus { outline: none; }

/* karty „Dlaczego warto” są pełne, żeby piksele w tle chowały się pod nimi */
.concept-q .why-card { background: #0f0f13; }
/* „Dlaczego warto” na komputerze (klasę .is-pin daje q-px.js, gdy sekcja mieści się w oknie):
   sekcja przypina się jak proces, a nagłówek i karty składają się w rytmie przewijania */
.concept-q .why.is-pin { height: 240vh; padding: 0; }
.concept-q .why.is-pin > .wrap { position: sticky; top: 0; height: 100vh; height: 100svh; display: flex; flex-direction: column; justify-content: center; padding-top: var(--nav-h); }

/* ikony pixel-art w kartach */
.why-ico.has-pix svg { display: none; }
.pix-ico { image-rendering: pixelated; }
.concept-q .why-ico { display: grid; place-items: center; }

/* logo z pikseli w stopce */
.foot-px { height: 210px; margin-top: -10px; }
@media (max-width: 860px) { .foot-px { height: 150px; } }

/* słowa przewodnie w nagłówkach */
.g { background: linear-gradient(92deg, #86a4ff, #46e3b4); -webkit-background-clip: text; background-clip: text; color: transparent; }
.g-rgb { background: linear-gradient(92deg, #7c9dff 0%, #45e4b3 100%); -webkit-background-clip: text; background-clip: text; }
/* kropka na końcu hasła to czerwony „piksel” — trzeci kolor bez brudnego przejścia w gradiencie */
.g-rgb .pn:last-child { color: var(--red); }
.g-b { background: linear-gradient(92deg, #a9c0ff, #4f7bff); -webkit-background-clip: text; background-clip: text; }
.g-g { background: linear-gradient(92deg, #9dffd8, #2ef0a0); -webkit-background-clip: text; background-clip: text; }
.g-r { background: linear-gradient(92deg, #ffb39c, #ff4a3d); -webkit-background-clip: text; background-clip: text; }
