
/* Układ: hero (nav w 5 kolumnach + wielki napis) → film mapowany scrollem (4 rozdziały, sticky) → curated work (schody 3D, login) → about → contact. */
:root {
  --bg: #FFFFFF;
  --ink: #0A0A0A;
  --line: #E4E4E4;
  --muted: #6B6B6B;
  --black: #0A0A0A; --purple: #4B1A8C; --yellow: #FFC400; --pink: #FF3D9A;
  --lime: #D8F020; --blue: #3FC8F0; --orange: #FF7A1A;
  --stair-bg: #DADADA;
  --font: 'Clash Display Variable', 'Helvetica Neue', Arial, sans-serif;
  --gutter: 5vw;
  --pill-h: 46px;
  --menu-h: 64px;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; color: var(--ink); font-family: var(--font); }
html { background: var(--stair-bg); overflow-x: clip; }
body { background: radial-gradient(120% 90% at 35% 25%, #ECECEC 0%, var(--stair-bg) 55%, #BDBDBD 100%) fixed; min-height: 100vh; }
body { overflow-x: clip; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; }

/* ---------- nagłówek ---------- */
.top { position: fixed; top: env(safe-area-inset-top, 0px); left: 0; right: 0; z-index: 46; padding: 34px var(--gutter) 0; pointer-events: none; color: #0A0A0A; transition: color .3s; }
body.on-dark .top, body.on-dark .top .menu-btn, body.on-dark .top .logo { color: #F2F2F2; }
body.menu-open .top, body.menu-open .top .menu-btn, body.menu-open .top .logo { color: #0A0A0A !important; }
body.menu-open .top .n-name, body.menu-open .top .marker { opacity: 1 !important; }
.nav { display: flex; justify-content: space-between; align-items: center; font-size: clamp(18px, 2.75vw, 56px); font-weight: 400; letter-spacing: .01em; line-height: 1; }
.nav > * { pointer-events: auto; }
.n-name { display: inline-block; justify-self: start; white-space: nowrap; position: relative; padding-bottom: .16em; }
.n-name .ch { display: inline-block; will-change: transform, opacity; }
.n-contact { justify-self: end !important; }
.n-link { display: inline-block; will-change: transform, opacity; transition: opacity .2s; position: relative; padding-bottom: .16em; justify-self: start; }
.n-link:hover { opacity: .5; }

.logo { position: absolute; left: var(--gutter); top: 24px; height: clamp(44px, 4.6vw, 88px); aspect-ratio: 976 / 478; max-width: 100%; color: inherit; pointer-events: none; }
.logo svg { position: relative; height: 100%; width: 100%; display: block; overflow: visible; }
#lgRing { fill: currentColor; }
#lgTM { transform-box: fill-box; transform-origin: center; }

.marker { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 47; pointer-events: none; overflow: visible; }
.marker path { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }

.menu-btn { position: absolute; right: var(--gutter); top: 26px; height: var(--menu-h); padding: 0; border-radius: 0; border: 0; background: none; color: inherit; font-size: clamp(18px, 2.75vw, 56px); font-weight: 400; letter-spacing: .01em; cursor: pointer; display: flex; align-items: center; gap: 14px; pointer-events: none; opacity: 0; top: 34px; height: auto; line-height: 1; padding-bottom: .16em; }
.menu-btn .bars { width: 26px; height: 12px; position: relative; }
.menu-btn .bars::before, .menu-btn .bars::after { content: ""; position: absolute; left: 0; right: 0; height: 2.5px; background: currentColor; border-radius: 2px; transition: transform .3s cubic-bezier(.34,1.56,.64,1), top .3s; }
.menu-btn .bars::before { top: 0; } .menu-btn .bars::after { top: 9.5px; }
body.menu-open .menu-btn .bars::before { top: 5px; transform: rotate(45deg); }
body.menu-open .menu-btn .bars::after { top: 5px; transform: rotate(-45deg); }

/* ---------- menu: ogromne kafelki ---------- */
.menu-ov { position: fixed; inset: 0; z-index: 35; background: rgba(255,255,255,.78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); opacity: 0; transition: opacity .3s; display: flex; flex-direction: column; align-items: flex-end; justify-content: center; padding: 120px var(--gutter) 60px; gap: 0; }
.menu-ov[hidden] { display: none !important; }
body.menu-open .menu-ov { opacity: 1; }
.big { display: block; font-size: clamp(44px, 8.4vw, 168px); font-weight: 800; letter-spacing: -.035em; line-height: 1; padding: .14em .42em .18em; border-radius: 999px; white-space: nowrap; border: 0; cursor: pointer; transform: translateY(60px) rotate(-8deg) scale(.4); opacity: 0; transition: transform .55s cubic-bezier(.34,1.56,.64,1), opacity .25s; }
body.menu-open .big { transform: none; opacity: 1; }
body.menu-open .big:nth-child(2) { transition-delay: .06s; } body.menu-open .big:nth-child(3) { transition-delay: .12s; } body.menu-open .big:nth-child(4) { transition-delay: .18s; }
.big:hover { transform: rotate(-3deg) scale(1.03); }
.big.c1 { background: var(--yellow); color: var(--ink); }
.big.c2 { background: var(--purple); color: #fff; }
.big.c3 { background: var(--pink); color: #fff; }
.big.c4 { background: var(--black); color: #fff; }
.big small { font-size: .28em; font-weight: 600; letter-spacing: .02em; vertical-align: .9em; margin-left: .3em; opacity: .7; }

/* ---------- hero ---------- */
.hero { height: 100vh; min-height: 520px; position: relative; }
/* Rysunek zostaje pod filmem (z-index:25), przycięty do swojego płótna. */
.hero canvas.ink { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 24; pointer-events: none; clip-path: inset(0); }
html.drawing, html.drawing * { cursor: crosshair !important; user-select: none !important; }
.headline { position: fixed; left: var(--gutter); bottom: 9vh; z-index: 30; transition: color .4s; margin: 0; font-weight: 800; font-size: clamp(48px, 8.2vw, 170px); line-height: .98; letter-spacing: -.035em; transform-origin: left bottom; will-change: transform, opacity; text-wrap: balance; max-width: 12ch; pointer-events: none; }
.headline .hl { display: block; }
.headline .hlB { position: absolute; left: 0; bottom: 0; width: 100%; }
.headline .w { display: inline-block; overflow: hidden; vertical-align: top; padding: .06em .12em .2em; margin: -.06em -.12em -.2em; }
.headline .w > span { display: inline-block; will-change: transform; }
.headline .w > span { transition: transform .85s cubic-bezier(.76,0,.24,1); }
.headline .hlA .w:nth-child(2) > span, .headline .hlB .w:nth-child(2) > span { transition-delay: .06s; }
.headline .hlA .w:nth-child(3) > span, .headline .hlB .w:nth-child(3) > span { transition-delay: .12s; }
.headline .hlA .w:nth-child(4) > span { transition-delay: .18s; }
.headline .hlB .w > span { transform: translateY(150%) rotate(8deg); }
.headline.swap .hlA .w > span { transform: translateY(-150%) rotate(-8deg); }
.headline.swap .hlB .w > span { transform: none; transition-delay: calc(.25s + var(--dd, 0s)); }
.headline.swap .hlB .w:nth-child(2) > span { --dd: .07s; } .headline.swap .hlB .w:nth-child(3) > span { --dd: .14s; }


/* ---------- wskazówka scrolla ---------- */
.cue { position: fixed; left: 50%; bottom: 2.4vh; z-index: 31; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 12px; height: 44px; padding: 0 8px 0 20px; background: none; border: 1px solid rgba(10,10,10,.22); border-radius: 999px; cursor: pointer; color: var(--ink); font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; opacity: .8; transition: opacity .4s, transform .4s, background .25s, color .25s; }
.cue:hover { opacity: 1; background: var(--ink); color: #fff; }
.cue .ar { width: 30px; height: 30px; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; overflow: hidden; transition: background .25s, color .25s; }
.cue:hover .ar { background: #fff; color: var(--ink); }
.cue .ar svg { width: 14px; height: 14px; animation: cueDrop 1.4s ease-in-out infinite; }
@keyframes cueDrop { 0%, 100% { transform: translateY(-2px); } 50% { transform: translateY(3px); } }
.cue.gone { opacity: 0; transform: translateX(-50%) translateY(14px); pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .cue .ar svg { animation: none; } }
.topfade { position: fixed; top: 0; left: 0; right: 0; height: 104px; z-index: 44; pointer-events: none; transition: opacity .3s; background: linear-gradient(180deg, rgba(226,226,226,.95) 0, rgba(226,226,226,.85) 62px, rgba(226,226,226,0) 104px); }
/* sporadyczny glitch RGB na górnej krawędzi */
#cglitch { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 43; pointer-events: none; mix-blend-mode: difference; }
#glitch { position: fixed; top: 0; left: 0; width: 100%; height: 150px; z-index: 45; pointer-events: none; mix-blend-mode: difference; }
body.rgb .top { animation: rgbSplit .26s steps(2) 1; }
@keyframes rgbSplit { 0% { text-shadow: 4px 0 #ff0040, -4px 0 #00e5ff; filter: drop-shadow(4px 0 #ff0040) drop-shadow(-4px 0 #00e5ff); transform: translateX(-3px); } 50% { text-shadow: -6px 0 #ff0040, 6px 0 #00ff6a; filter: drop-shadow(-5px 0 #ff0040) drop-shadow(5px 0 #2a5bff); transform: translateX(4px); } 100% { text-shadow: none; filter: none; transform: none; } }

/* glitch RGB na hover wybranych przycisków */
.big:hover, .contact .row a:hover, .cmail:hover, .pill.dark:hover, .cue:hover, .n-link:hover, .menu-btn:hover { animation: btnGlitch .38s steps(1) 1; }
@keyframes btnGlitch {
  0%   { text-shadow: 3px 0 #ff0040, -3px 0 #00e5ff; }
  25%  { text-shadow: -4px 0 #ff0040, 4px 0 #00ff6a; }
  50%  { text-shadow: 2px 0 #2a5bff, -2px 0 #ff00d4; }
  75%  { text-shadow: -3px 0 #ff0040, 3px 0 #00e5ff; }
  100% { text-shadow: none; }
}
@media (prefers-reduced-motion: reduce) { .big:hover, .contact .row a:hover, .cmail:hover, .pill.dark:hover, .cue:hover, .n-link:hover, .menu-btn:hover { animation: none; } }

/* film: tylko licznik klatek na środku, bez logo, minimalne menu */
.chap .tag, .chap .num, .chap h2, .timeline { display: none !important; }
.fcount { left: 50% !important; right: auto !important; top: 52px !important; transform: translateX(-50%); font-size: 12px !important; letter-spacing: .18em !important; opacity: .85; }
body.on-film .n-name, body.on-film .logo, body.on-film .marker { opacity: 0 !important; pointer-events: none !important; transition: opacity .3s; }
.logo, .marker, .n-name { transition: opacity .3s; }
body.on-film #menuTxt { opacity: 0; width: 0; overflow: hidden; display: inline-block; }
#menuTxt { transition: opacity .3s; white-space: nowrap; }
body.on-film .menu-btn { gap: 0; }
body.on-film .menu-btn .bars { width: 30px; }

html.glitching { filter: url(#rgbG); }
html.lglitch:not(.glitching) { filter: url(#locG); }
.gq { position: fixed; left: 0; top: 0; z-index: 43; pointer-events: none; will-change: transform; display: none; }

/* ---------- newsletter ---------- */
.news-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 5vw; align-items: start; }
.news-lead { margin: 0 0 28px; font-size: clamp(22px, 2vw, 34px); font-weight: 500; letter-spacing: -.02em; line-height: 1.2; max-width: 26ch; }
.topics { list-style: none; margin: 0 0 28px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.topics li { height: 44px; line-height: 44px; padding: 0 18px; border-radius: 999px; background: #0B0612; color: var(--gc); font-weight: 600; font-size: 17px; text-shadow: 0 0 10px color-mix(in srgb, var(--gc) 45%, transparent); border: 1px solid color-mix(in srgb, var(--gc) 45%, transparent); }
.topics li:nth-child(3n) { border-radius: 4px; } .topics li:nth-child(4n) { border-radius: 12px; }
.promise { margin: 0; font-size: 16px; line-height: 1.5; color: #3a3a3a; max-width: 44ch; }
.nbox { background: #0B0612; color: #F2F2F2; border-radius: 999px; padding: 0; overflow: hidden; max-width: 420px; transition: max-width .8s cubic-bezier(.76,0,.24,1), border-radius .8s cubic-bezier(.76,0,.24,1), box-shadow .8s; box-shadow: 0 0 0 1px rgba(201,139,255,.35); }
.nbox-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; height: 64px; padding: 0 28px; }
.nbox-title { font-weight: 700; font-size: 19px; }
.nbox-meta { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: #c98bff; }
.nbox-body { display: grid; gap: 16px; padding: 0 28px; max-height: 0; opacity: 0; transition: max-height .9s cubic-bezier(.76,0,.24,1), opacity .5s .2s, padding .8s; }
.nbox.open { max-width: 640px; border-radius: 28px; box-shadow: 0 0 0 1px rgba(201,139,255,.45), 0 30px 80px rgba(75,26,140,.25); }
.nbox.open .nbox-body { max-height: 720px; opacity: 1; padding: 4px 28px 28px; }
.nf { display: grid; gap: 6px; font-size: 13px; font-weight: 600; letter-spacing: .04em; color: rgba(242,242,242,.7); }
.nf i { font-style: normal; font-weight: 400; opacity: .7; }
.nf input { height: 54px; border-radius: 12px; border: 1px solid rgba(255,255,255,.18); background: rgba(255,255,255,.05); color: #fff; padding: 0 18px; font: inherit; font-size: 17px; font-weight: 500; letter-spacing: 0; }
.nf input::placeholder { color: rgba(255,255,255,.35); }
.nf input:focus { outline: none; border-color: #c98bff; box-shadow: 0 0 0 3px rgba(201,139,255,.25); }
.chk { display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: start; font-size: 14px; line-height: 1.45; color: rgba(242,242,242,.82); cursor: pointer; position: relative; }
.chk input { position: absolute; opacity: 0; width: 22px; height: 22px; margin: 0; cursor: pointer; }
.chk .box { width: 22px; height: 22px; border-radius: 6px; border: 1.5px solid rgba(255,255,255,.4); display: grid; place-items: center; transition: background .2s, border-color .2s; }
.chk .box::after { content: ""; width: 10px; height: 6px; border-left: 2px solid #0B0612; border-bottom: 2px solid #0B0612; transform: rotate(-45deg) translate(1px, -1px) scale(0); transition: transform .2s cubic-bezier(.34,1.56,.64,1); }
.chk input:checked + .box { background: #c98bff; border-color: #c98bff; }
.chk input:checked + .box::after { transform: rotate(-45deg) translate(1px, -1px) scale(1); }
.chk input:focus-visible + .box { outline: 2px solid #c98bff; outline-offset: 2px; }
.chk i { font-style: normal; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #c98bff; margin-left: 4px; }
.nsend { height: 56px; border-radius: 999px; border: 0; background: #F2F2F2; color: #0B0612; font: inherit; font-size: 18px; font-weight: 700; cursor: pointer; margin-top: 4px; transition: background .25s, color .25s; }
.nsend:hover { background: #c98bff; color: #0B0612; animation: btnGlitch .38s steps(1) 1; }
.nnote { margin: 0; min-height: 20px; font-size: 14px; color: #4dff88; }
.nnote.err { color: #ff6e9a; }
@media (max-width: 760px) { .news-grid { grid-template-columns: minmax(0, 1fr); } .nbox, .nbox.open { max-width: 100%; } }

/* ---------- cookies (dyskretnie) ---------- */
.cookie { position: fixed; right: 16px; bottom: 16px; z-index: 55; display: flex; align-items: center; gap: 12px; max-width: min(380px, calc(100vw - 32px)); padding: 10px 10px 10px 16px; border-radius: 999px; background: rgba(255,255,255,.82); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: #2a2a2a; font-size: 12.5px; line-height: 1.35; box-shadow: 0 6px 24px rgba(0,0,0,.08); opacity: 0; transform: translateY(10px); transition: opacity .5s, transform .5s; }
.cookie.show { opacity: 1; transform: none; }
.cookie[hidden] { display: none !important; }
.cookie button { flex: none; height: 30px; padding: 0 14px; border-radius: 999px; border: 0; background: #0A0A0A; color: #fff; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }

/* ---------- about: wejście ---------- */
#about .portrait { transform-origin: 50% 60%; }
#about.pre .portrait { opacity: 0; }
#about.in .portrait { opacity: 1; }
#about .portrait { position: relative; }
#about .portrait.glX::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(180deg, rgba(0,0,0,.18) 0 2px, transparent 2px 4px); mix-blend-mode: multiply; pointer-events: none; }
#about .portrait img { filter: saturate(.9); }
#about .portrait canvas.px8 { position: absolute; inset: 0; width: 100%; height: 100%; display: block; image-rendering: pixelated; }
#about .portrait.pxing img { opacity: 0; }
#about .portrait.pxing { background: transparent; overflow: visible; }
#about.done .portrait img { filter: saturate(.9); }
#about .bio .w { display: inline-block; overflow: visible; vertical-align: top; padding: .04em .06em .14em; margin: -.04em -.06em -.14em; }
#about .bio .w > i { display: inline-block; font-style: normal; }
#about.in .bio .w > i { transition: transform 1.2s cubic-bezier(.19,1,.22,1), opacity .9s ease, filter 1s ease; transition-delay: var(--d); }
#about.pre .bio .w > i { transform: translateY(70%); opacity: 0; filter: blur(10px); }
#about.in .bio .w > i { transform: none; opacity: 1; }
#about.in .bio p:not(.lead), #about.in .bio .lbl { transition: transform 1.2s cubic-bezier(.19,1,.22,1), opacity 1s ease, filter 1s ease; transition-delay: var(--d, 0s); }
#about.in .bio .bio-head .lbl { transition-delay: .1s; }
#about.pre .bio p:not(.lead), #about.pre .bio .lbl { opacity: 0; transform: translateY(24px); filter: blur(8px); }
@media (prefers-reduced-motion: reduce) { #about.pre .portrait, #about.pre .bio .w > i, #about.pre .bio > p, #about.pre .bio .lbl { opacity: 1; transform: none; } #about .portrait img { filter: none; } }
/* ---------- film mapowany scrollem ---------- */
body.on-film .top, body.on-film .top .menu-btn, body.on-film .top .logo { mix-blend-mode: normal; color: #0A0A0A; }
.film { position: relative; z-index: 25; height: 700vh; margin-top: -100vh; pointer-events: none; }
.film .screen { pointer-events: auto; }
.track { position: absolute; inset: 0; will-change: transform; }
.stage { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.screen { position: absolute; inset: 0; overflow: hidden; background: var(--ink); isolation: isolate; will-change: clip-path; clip-path: circle(0px at 50% 50%); }
.stage video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.chap { position: absolute; left: 0; top: 0; width: 100%; height: 100%; display: flex; flex-direction: column; justify-content: flex-start; padding: 190px var(--gutter) 0; }
.chap .tag { position: absolute; top: 130px; left: var(--gutter); font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; display: flex; gap: 10px; align-items: center; }
.chap .tag b { height: 30px; line-height: 30px; padding: 0 14px; border-radius: 999px; background: currentColor; }
.chap .tag b span { color: var(--chip-txt); }
.chap .num { font-size: clamp(16px, 1.4vw, 24px); font-weight: 600; font-variant-numeric: tabular-nums; margin-bottom: 14px; }
.chap h2 { margin: 0; font-size: clamp(34px, 4.4vw, 84px); font-weight: 800; letter-spacing: -.045em; line-height: .9; max-width: 11ch; text-wrap: balance; }
.ch1 { background: var(--yellow); color: var(--ink); --chip-txt: var(--yellow); }
.ch2 { background: var(--purple); color: #fff; --chip-txt: var(--purple); }
.ch3 { background: #CFE7F4; color: var(--ink); --chip-txt: #CFE7F4; }
.ch4 { background: var(--pink); color: #fff; --chip-txt: var(--pink); }
.timeline { position: absolute; left: 58%; right: var(--gutter); bottom: 9vh; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; z-index: 2; color: var(--hud, #0A0A0A); transition: color .3s; }
.timeline div { min-width: 0; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; display: flex; flex-direction: column; gap: 8px; }
.timeline i { display: block; height: 3px; background: color-mix(in srgb, currentColor 25%, transparent); border-radius: 3px; overflow: hidden; }
.timeline i::after { content: ""; display: block; height: 100%; width: calc(var(--f, 0) * 100%); background: currentColor; }
.fcount { position: absolute; right: var(--gutter); top: 134px; z-index: 2; font-size: 13px; font-weight: 600; letter-spacing: .08em; font-variant-numeric: tabular-nums; color: var(--hud, #0A0A0A); transition: color .3s; }

/* ---------- curated work: wieża 3D (kamera od dołu) ---------- */
.stairs { position: relative; z-index: 10; height: calc(100vh + 560px); margin-top: -100vh; }
.st-stage { position: sticky; top: 0; height: 100vh; min-height: 640px; overflow: visible; }
.st-scene { position: absolute; inset: 0; perspective: var(--persp, 1000px); perspective-origin: var(--po, 70% 120%); }
.st-world { position: absolute; left: var(--wx, 52%); top: 70%; width: 0; height: 0; transform-style: preserve-3d; }
.step { position: absolute; left: 0; top: 0; transform-style: preserve-3d; cursor: pointer; visibility: hidden; }
.step .f { position: absolute; left: 0; top: 0; height: 100%; background: #0D0D0D; color: #F4F4F4; font-family: 'Clash Display Variable', Impact, 'Arial Narrow', sans-serif; font-size: calc(var(--h) * .86); line-height: var(--h); text-transform: uppercase; letter-spacing: .005em; padding: 0 calc(var(--h) * .16); white-space: nowrap; transition: color .2s; }
.step .f span { display: inline-block; transform: skewX(-6deg); }
.step .vis { position: absolute; inset: 0; transform-style: preserve-3d; pointer-events: none; will-change: transform; }
.step .hit { position: absolute; inset: 0; }   /* stały obszar najechania – blok wysuwa się, ale nie ucieka spod kursora */
.step .f .arr { position: absolute; right: calc(var(--h) * .26); top: 50%; width: calc(var(--h) * .5); height: calc(var(--h) * .5); transform: translateY(-50%); display: block; transition: transform .35s cubic-bezier(.34,1.56,.64,1); }
.step:hover .f .arr { transform: translate(calc(var(--h) * .12), -50%); }
.step.o .f .arr { color: #F4F4F4; }
.step.o .f { color: transparent; -webkit-text-stroke: max(2px, calc(var(--h) * .035)) #F4F4F4; }
.step .bt { position: absolute; left: 0; bottom: 0; width: 100%; height: var(--d); transform-origin: bottom; transform: rotateX(90deg); background: linear-gradient(90deg, var(--c1), var(--c2)); }
.step .t { position: absolute; left: 0; top: 0; width: 100%; height: var(--d); transform-origin: top; transform: rotateX(-90deg); background: linear-gradient(90deg, var(--c1), var(--c2)); }
.step .r { position: absolute; right: 0; top: 0; width: var(--d); height: 100%; transform-origin: right; transform: rotateY(-90deg); background: linear-gradient(180deg, var(--c1), var(--c2)); }
.step .l { position: absolute; left: 0; top: 0; width: var(--d); height: 100%; transform-origin: left; transform: rotateY(90deg); background: #0D0D0D; }
.step:hover .f, .step:focus-visible .f { color: var(--yellow); }
.step.o:hover .f, .step.o:focus-visible .f { -webkit-text-stroke-color: var(--yellow); }
.step:focus-visible { outline: none; }
.st-head { position: absolute; left: var(--gutter); top: clamp(150px, 19vh, 230px); z-index: 2; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.st-head h2 { margin: 0; font-size: clamp(36px, 4.4vw, 84px); font-weight: 800; letter-spacing: -.04em; line-height: .92; }
.st-foot.glout { animation: ftOut .52s steps(1, end) forwards; }
.st-foot.glin { animation: ftIn .52s steps(1, end) forwards; }
@keyframes ftOut {
  0%   { opacity: 1; transform: none; clip-path: inset(0); filter: none; }
  10%  { transform: translateX(-9px) skewX(-8deg); clip-path: inset(0 0 52% 0); filter: drop-shadow(5px 0 #ff2e6e) drop-shadow(-5px 0 #2ef0ff); }
  20%  { transform: translateX(14px); clip-path: inset(38% 0 0 0); filter: drop-shadow(-8px 0 #ff2e6e) drop-shadow(8px 0 #4dff88); }
  30%  { opacity: 1; transform: translateX(-4px); clip-path: inset(10% 0 30% 0); filter: drop-shadow(10px 0 #c98bff) drop-shadow(-6px 0 #2ef0ff); }
  40%  { opacity: 0; }
  50%  { opacity: 1; transform: translateX(22px) scaleY(.6); clip-path: inset(60% 0 8% 0); filter: drop-shadow(-12px 0 #ff2e6e) drop-shadow(12px 0 #2ef0ff); }
  62%  { opacity: .8; transform: translateX(-30px) scaleX(1.15); clip-path: inset(20% 0 66% 0); filter: drop-shadow(14px 0 #4dff88); }
  75%  { opacity: 0; }
  84%  { opacity: .6; transform: translateX(40px); clip-path: inset(48% 0 46% 0); filter: drop-shadow(-16px 0 #ff2e6e) drop-shadow(16px 0 #2ef0ff); }
  100% { opacity: 0; transform: translateX(40px); clip-path: inset(50% 0 50% 0); }
}
@keyframes ftIn {
  0%   { opacity: 0; clip-path: inset(50% 0 50% 0); }
  12%  { opacity: .7; transform: translateX(30px); clip-path: inset(46% 0 44% 0); filter: drop-shadow(-14px 0 #ff2e6e) drop-shadow(14px 0 #2ef0ff); }
  24%  { opacity: 0; }
  36%  { opacity: 1; transform: translateX(-18px) scaleX(1.1); clip-path: inset(18% 0 40% 0); filter: drop-shadow(10px 0 #4dff88) drop-shadow(-8px 0 #c98bff); }
  50%  { transform: translateX(10px); clip-path: inset(0 0 55% 0); filter: drop-shadow(-6px 0 #ff2e6e) drop-shadow(6px 0 #2ef0ff); }
  62%  { transform: translateX(-6px) skewX(6deg); clip-path: inset(40% 0 0 0); filter: drop-shadow(4px 0 #ff2e6e); }
  76%  { transform: translateX(3px); clip-path: inset(0); filter: drop-shadow(-2px 0 #2ef0ff); }
  88%  { transform: none; filter: drop-shadow(2px 0 #ff2e6e); }
  100% { opacity: 1; transform: none; clip-path: inset(0); filter: none; }
}
@media (prefers-reduced-motion: reduce) { .st-foot.glout { animation: none; opacity: 0; } .st-foot.glin { animation: none; opacity: 1; } }
.st-foot { position: absolute; left: var(--gutter); bottom: 5vh; z-index: 2; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.st-hint { height: 44px; line-height: 44px; padding: 0 20px; border-radius: 999px; background: rgba(255,255,255,.75); font-size: 15px; font-weight: 600; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.st-vers { position: absolute; right: var(--gutter); bottom: 5vh; z-index: 2; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.st-vers .lbl { color: var(--ink); }
.st-vers .row { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; max-width: 360px; }
.st-vers button { width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255,255,255,.8); font-size: 15px; font-weight: 700; cursor: pointer; font-variant-numeric: tabular-nums; }
.st-vers button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.st-vers button:hover { background: var(--yellow); color: var(--ink); }
.st-tip { position: absolute; z-index: 3; left: 0; top: 0; pointer-events: none; height: 40px; line-height: 40px; padding: 0 18px; border-radius: 999px; background: var(--ink); color: #fff; font-size: 15px; font-weight: 600; white-space: nowrap; opacity: 0; transform: translate(-50%, -150%) scale(.6); transition: opacity .2s, transform .25s cubic-bezier(.34,1.56,.64,1); }
.st-tip.on { opacity: 1; transform: translate(-50%, -150%) scale(1); }

/* ---------- klienci: spokojna migająca ściana ---------- */
#clients.clients { position: relative; z-index: 10; height: calc(100vh + 520px); margin-top: -32vh; }
.cl-stage { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.cl-head { position: absolute; left: var(--gutter); top: clamp(150px, 19vh, 230px); margin: 0; z-index: 2; }
.wall { position: absolute; inset: 0; }
.wt { position: absolute; left: 0; top: 0; will-change: transform; font-family: var(--font); font-weight: 600; font-size: clamp(22px, 2.9vw, 48px); letter-spacing: -.02em; line-height: 1; padding: .38em .9em .42em; border-radius: 999px; white-space: nowrap; user-select: none; color: rgba(10,10,10,.26); border: 1.5px solid rgba(10,10,10,.14); background: transparent; transition: color 1.4s ease, border-color 1.4s ease, background-color 1.4s ease; }
.wt.on { color: var(--ink); border-color: rgba(10,10,10,.85); background: rgba(255,255,255,.45); }
.wt:hover { color: var(--ink); border-color: var(--ink); transition-duration: .25s; }
@media (prefers-reduced-motion: reduce) { .wt { transition: none; } }

/* ---------- wspólne ---------- */
.sec { position: relative; z-index: 10; padding: clamp(150px, 19vh, 230px) var(--gutter) 16vh; min-height: 100vh; }
.sec-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 56px; }
.sec-head { flex-direction: column; align-items: flex-start; gap: 8px; }
.sec-head .lbl { margin-bottom: 8px; }
.sec-head h2 { margin: 0; font-size: clamp(36px, 4.4vw, 84px); font-weight: 800; letter-spacing: -.04em; line-height: .92; }
.lbl { font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.pill { height: 56px; line-height: 56px; padding: 0 30px; border-radius: 999px; border: 0; font-size: 20px; font-weight: 600; cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; gap: 12px; }
.pill.dark { background: var(--black); color: #fff; }
.pill.dark:hover { background: var(--pink); }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.card { min-width: 0; position: relative; aspect-ratio: 4 / 3; max-width: 100%; border-radius: 28px; overflow: hidden; border: 0; padding: 0; cursor: pointer; text-align: left; background: var(--c); }
.card::before { content: ""; position: absolute; inset: -20%; background: radial-gradient(circle at 30% 30%, rgba(255,255,255,.55), transparent 40%), radial-gradient(circle at 75% 70%, rgba(0,0,0,.25), transparent 45%); filter: blur(30px); transition: transform .6s; }
.card:hover::before { transform: scale(1.15) rotate(8deg); }
.card .meta { position: absolute; left: 22px; right: 22px; bottom: 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px; color: var(--t); font-weight: 600; font-size: 17px; }
.card .lock { width: 52px; height: 52px; border-radius: 50%; background: var(--black); color: #fff; display: grid; place-items: center; flex: none; transition: transform .35s cubic-bezier(.34,1.56,.64,1); }
.card:hover .lock { transform: scale(1.12) rotate(-12deg); }
.card .nda { position: absolute; top: 18px; left: 18px; height: 30px; line-height: 30px; padding: 0 14px; border-radius: 999px; background: rgba(255,255,255,.85); color: var(--ink); font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }

/* ---------- about ---------- */
.bio-head { display: flex; flex-direction: column; gap: 8px; margin-bottom: .6em; }
.bio-head h2 { margin: 0; font-size: clamp(36px, 4.4vw, 84px); font-weight: 800; letter-spacing: -.04em; line-height: .92; color: var(--ink); }
.about-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 5vw; align-items: start; }
.portrait { margin: 0; border-radius: 28px; overflow: hidden; aspect-ratio: 4 / 5; max-width: 100%; background: #CFCFCF; }
.portrait img { width: 100%; height: 100%; object-fit: cover; display: block; filter: saturate(.9); }
.bio { min-width: 0; display: flex; flex-direction: column; gap: 1.1em; font-size: clamp(17px, 1.3vw, 21px); line-height: 1.5; color: #2A2A2A; max-width: 40em; }
.bio p { margin: 0; }
.bio .sign { font-weight: 700; color: var(--ink); font-size: 1.15em; margin-top: .4em; }
.about-grid p.lead { margin: 0 0 .3em; font-size: clamp(24px, 2.4vw, 44px); font-weight: 500; letter-spacing: -.02em; line-height: 1.14; color: var(--ink); max-width: 26ch; }

/* ---------- contact ---------- */
.contact { position: relative; z-index: 10; background: var(--ink); color: #F2F2F2; padding: clamp(130px, 16vh, 200px) var(--gutter) 4vh; min-height: 100vh; display: flex; flex-direction: column; justify-content: space-between; gap: 4vh; }
.contact .lbl { color: rgba(255,255,255,.5); }
.contact h2 { margin: 0; font-size: clamp(52px, min(8.5vw, 12vh), 190px); font-weight: 800; letter-spacing: -.05em; line-height: .88; }
.contact .head { display: flex; flex-direction: column; gap: 14px; }
.cmid { display: flex; flex-direction: column; gap: 22px; align-items: flex-start; }
.cmail { font-size: clamp(22px, 2.3vw, 38px); font-weight: 600; letter-spacing: -.03em; color: #fff; border-bottom: 3px solid currentColor; padding-bottom: 4px; transition: color .25s; }
.cmail:hover { color: var(--yellow); }
.cphone { font-size: clamp(18px, 1.6vw, 26px); font-weight: 500; color: rgba(255,255,255,.75); font-variant-numeric: tabular-nums; letter-spacing: .01em; margin-top: -8px; }
.cphone:hover { color: #fff; }
.cmail span { display: inline-block; transition: transform .3s cubic-bezier(.34,1.56,.64,1); }
.cmail:hover span { transform: translate(6px, -6px); }
.contact .row { display: flex; flex-wrap: wrap; gap: 10px; }
.contact .row a { height: 52px; line-height: 50px; padding: 0 26px; border-radius: 999px; font-size: 18px; font-weight: 600; border: 1.5px solid rgba(255,255,255,.35); color: #fff; transition: background .25s, color .25s, border-color .25s; }
.contact .row a:hover { background: #fff; color: var(--ink); border-color: #fff; }
.todo { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--lime); }
.cbottom { display: flex; flex-direction: column; gap: 18px; }
.biglogo { position: absolute; right: var(--gutter); bottom: calc(4vh + 44px); width: 24vw; height: 22vh; display: block; color: #F2F2F2; pointer-events: none; }
@media (max-width: 760px) { .biglogo { position: static; width: 60%; height: 14vh; } }
.foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 14px; color: rgba(255,255,255,.55); }
.foot a:hover { color: #fff; }

/* ---------- area of expertise: pasma z kanałami sygnału ---------- */
.xlist { border-top: 1px solid rgba(10,10,10,.22); }
.xrow { display: grid; grid-template-columns: 90px minmax(0, 1fr) minmax(0, 1.5fr); gap: 3vw; align-items: center; padding: 26px 0; border-bottom: 1px solid rgba(10,10,10,.22); cursor: default; }
.xrow .xn { font-size: 13px; font-weight: 600; letter-spacing: .1em; color: var(--muted); font-variant-numeric: tabular-nums; }
.xrow h3 { margin: 0; font-size: clamp(40px, 5.2vw, 100px); font-weight: 800; letter-spacing: -.045em; line-height: .9; transition: transform .5s cubic-bezier(.34,1.56,.64,1), color .3s; }
.xrow .xc { display: flex; flex-wrap: wrap; gap: 8px; }
.xrow .xc span { height: 42px; line-height: 40px; padding: 0 16px; border: 1px solid rgba(10,10,10,.18); font-size: 16px; font-weight: 600; color: #3a3a3a; white-space: nowrap; transition: background .3s, color .3s, border-color .3s, box-shadow .3s; }
.xrow .xc span:nth-child(3n+1) { border-radius: 999px; } .xrow .xc span:nth-child(3n+2) { border-radius: 4px; } .xrow .xc span:nth-child(3n) { border-radius: 12px; }
.xrow:hover h3, .xrow.on h3 { transform: translateX(14px); }
.xrow:hover .xc span, .xrow.on .xc span { background: #0B0612; color: var(--gc); border-color: color-mix(in srgb, var(--gc) 50%, transparent); box-shadow: 0 0 14px color-mix(in srgb, var(--gc) 25%, transparent); }
@media (max-width: 760px) { .xrow { grid-template-columns: minmax(0, 1fr); gap: 12px; } }

/* Instagram / LinkedIn: po najechaniu napis wyjeżdża w górę, a od dołu wjeżdża wezwanie */
.swap { display: inline-grid; overflow: hidden; vertical-align: top; }
.swap > span { grid-area: 1 / 1; text-align: center; transition: transform .45s cubic-bezier(.34,1.56,.64,1); }
.swap .sb { transform: translateY(110%); }
.swap:hover .sa, .swap:focus-visible .sa { transform: translateY(-110%); }
.swap:hover .sb, .swap:focus-visible .sb { transform: none; }

/* ---------- tablica ---------- */
html.drawmode .seg { background: rgba(255,255,255,.42) !important; color: #0A0A0A !important; border: 1.5px solid #0A0A0A !important; text-shadow: none !important; box-shadow: none !important; -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
html.erasing.drawing, html.erasing.drawing * { cursor: cell !important; }
.inkbar { position: fixed; left: 50%; bottom: calc(2.4vh + 60px); z-index: 32; display: flex; gap: 6px; align-items: center; padding: 6px; border-radius: 999px; background: rgba(255,255,255,.62); border: 1px solid rgba(10,10,10,.14); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 14px 40px rgba(0,0,0,.08); transform: translate(-50%, 24px) scale(.9); opacity: 0; pointer-events: none; transition: opacity .3s, transform .45s cubic-bezier(.34,1.56,.64,1); }
.inkbar.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.inkbar.show.away { opacity: 0; transform: translate(-50%, 24px) scale(.9); pointer-events: none; }
.inkbar button { height: 40px; min-width: 40px; padding: 0 12px; border-radius: 999px; border: 0; background: transparent; color: var(--ink); font: 600 14px var(--font); cursor: pointer; display: inline-grid; place-items: center; grid-auto-flow: column; gap: 8px; }
.inkbar button:hover { background: rgba(10,10,10,.07); }
.inkbar button.on { background: var(--ink); color: #fff; }
.inkbar .send { background: var(--ink); color: #fff; padding: 0 18px; }
.inkbar .send:hover { background: var(--purple); }
.fn-prev { width: 100%; max-height: 190px; object-fit: contain; border-radius: 16px; background: #fff; border: 1px solid var(--line); }
.dialog textarea { border-radius: 22px; border: 1.5px solid var(--line); padding: 14px 20px; font: inherit; font-size: 16px; background: #FAFAFA; color: var(--ink); resize: vertical; min-height: 84px; }
.dialog textarea:focus { outline: none; border-color: var(--ink); background: #fff; }
#fabNote.ok [data-send] { background: #1f9d55; }
.inbox-btn { position: fixed; left: 16px; bottom: 16px; z-index: 55; height: 38px; padding: 0 16px; border-radius: 999px; border: 0; background: var(--ink); color: #fff; font: 600 13px var(--font); cursor: pointer; }
.dialog.inbox { width: min(860px, 100%); max-height: 86vh; overflow: auto; }
.ib-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.ib-list figure { margin: 0; background: #fff; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); }
.ib-list img { width: 100%; display: block; }
.ib-list figcaption { padding: 10px 12px; display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.ib-list figcaption span { white-space: pre-wrap; }
@media (max-width: 640px) { .inkbar .send { padding: 0 12px; } }
/* ---------- login ---------- */
.modal { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 16px; background: rgba(10,10,10,.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; transition: opacity .25s; }
.modal[hidden] { display: none !important; }
.modal.on { opacity: 1; }
.dialog { width: min(460px, 100%); background: var(--bg); color: var(--ink); border-radius: 32px; padding: 34px 32px 30px; position: relative; transform: translateY(30px) scale(.92) rotate(-2deg); transition: transform .45s cubic-bezier(.34,1.56,.64,1); display: flex; flex-direction: column; gap: 18px; }
.modal.on .dialog { transform: none; }
.dialog h3 { margin: 0; font-size: 40px; font-weight: 800; letter-spacing: -.035em; line-height: 1; }
.dialog p { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.45; }
.dialog .x { position: absolute; top: 18px; right: 18px; width: 46px; height: 46px; border-radius: 50%; border: 0; background: #F1F1F1; cursor: pointer; font-size: 22px; line-height: 1; }
.dialog .x:hover { background: var(--yellow); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 13px; font-weight: 600; letter-spacing: .04em; }
.field input { height: 54px; border-radius: 999px; border: 1.5px solid var(--line); padding: 0 22px; font: inherit; font-size: 17px; background: #FAFAFA; color: var(--ink); }
.field input:focus { outline: none; border-color: var(--ink); background: #fff; }
.dialog .pill { width: 100%; justify-content: center; }
.dialog .note { font-size: 14px; color: var(--purple); font-weight: 600; min-height: 20px; }
.dialog .alt { font-size: 15px; text-align: center; }
.dialog .alt a { text-decoration: underline; text-underline-offset: 3px; }
.mock { align-self: flex-start; height: 28px; line-height: 28px; padding: 0 12px; border-radius: 999px; background: var(--lime); font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }


.modal.bad .dialog { animation: lgShake .42s cubic-bezier(.36,.07,.19,.97); }
.modal.bad .field input { border-color: #ED1C24; }
@keyframes lgShake { 10%,90% { transform: translateX(-2px); } 20%,80% { transform: translateX(5px); } 30%,50%,70% { transform: translateX(-10px) skewX(-2deg); } 40%,60% { transform: translateX(10px) skewX(2deg); } }
.modal.ok #lgBtn { background: #1f9d55; }
.dialog .note { color: #ED1C24; }
/* ---------- kafelki węża ---------- */
#snake { position: fixed; inset: 0; z-index: 40; pointer-events: none; overflow: hidden; transition: opacity .35s; }
#snake.off { opacity: 0; }
.seg { position: absolute; left: 0; top: 0; height: var(--pill-h); line-height: var(--pill-h); padding: 0 18px; border-radius: 3px; font-family: var(--font); font-size: 18px; font-weight: 600; letter-spacing: -.005em; white-space: nowrap; background: #0B0612; color: var(--gc); border: 1px solid color-mix(in srgb, var(--gc) 45%, transparent); text-shadow: 0 0 10px color-mix(in srgb, var(--gc) 45%, transparent); box-shadow: 0 0 18px color-mix(in srgb, var(--gc) 30%, transparent); animation: life 1.5s linear forwards; will-change: transform, opacity; }
.seg.measure { visibility: hidden; animation: none; }
.seg.sh-pill { border-radius: 999px; } .seg.sh-round { border-radius: 12px; } .seg.sh-rect { border-radius: 0; }
.seg.sh-cut { border-radius: 0; clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px); }
.seg.sh-tag { border-radius: 0; clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%); padding-right: 26px; }
.seg.sh-leaf { border-radius: 18px 0 18px 0; }
@keyframes life {
  0%   { transform: translate(var(--x), var(--y)) translate(-50%, -50%) scale(0); opacity: 1; }
  12%  { transform: translate(var(--x), var(--y)) translate(-50%, -50%) scale(1.06); }
  18%  { transform: translate(var(--x), var(--y)) translate(-50%, -50%) scale(1); }
  70%  { transform: translate(var(--x), var(--y)) translate(-50%, -50%) scale(1); opacity: 1; }
  100% { transform: translate(var(--x), var(--y)) translate(-50%, -50%) scale(.82); opacity: 0; }
}

@media (max-width: 760px) {
  :root { --pill-h: 38px; --menu-h: 52px; }
  .seg { font-size: 15px; padding: 0 16px; }
  .nav { gap: 0 12px; font-size: 18px; padding-right: 0; }
  .nav .n-link { display: none; }
  .menu-btn { font-size: 18px; padding: 0 22px; }
  .about-grid { grid-template-columns: minmax(0, 1fr); }
  .chap .tag, .fcount { top: 100px; }
  .timeline div span { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .seg { animation: none; transform: translate(var(--x), var(--y)) translate(-50%, -50%); }
}
