/* ==========================================================================
   Magik ReSorek – style główne
   Język wizualny: plakat / naklejka (grube ciemne obrysy, twardy cień) + sprężyna.
   ========================================================================== */

/* ---------- Czcionki (hostowane lokalnie) ---------- */
@font-face {
	font-family: "Boldonse";
	src: url("../fonts/boldonse.woff") format("woff");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "Bricolage Grotesque";
	src: url("../fonts/bricolage-400.woff") format("woff");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}
@font-face {
	font-family: "Bricolage Grotesque";
	src: url("../fonts/bricolage-700.woff") format("woff");
	font-weight: 700;
	font-style: normal;
	font-display: swap;
}

/* ---------- Zmienne ---------- */
:root {
	--blue: #2b23d8;
	--blue-deep: #1a13a3;
	--ink: #14112b;
	--paper: #f4f2ff;
	--white: #ffffff;
	--sun: #ffc92e;
	--pink: #ff4f87;

	--font-display: "Boldonse", "Arial Black", system-ui, sans-serif;
	--font-body: "Bricolage Grotesque", system-ui, -apple-system, "Segoe UI", sans-serif;

	--header-h: 72px;
	--wrap: 1180px;
	--gutter: clamp(1rem, 4vw, 2rem);

	/* Sprężyna: lekkie przestrzelenie i ustabilizowanie. */
	--spring: cubic-bezier(0.34, 1.56, 0.64, 1);

	/* Maski sprężyny (kolor nadaje background elementu). */
	--coil-h: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 34' preserveAspectRatio='none'%3E%3Cellipse cx='10' cy='17' rx='11' ry='7.5' transform='rotate(-26 10 17)' fill='none' stroke='%23000' stroke-width='3.2'/%3E%3C/svg%3E");
	--coil-v: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 34 20' preserveAspectRatio='none'%3E%3Cellipse cx='17' cy='10' rx='14' ry='8' transform='rotate(-8 17 10)' fill='none' stroke='%23000' stroke-width='3.2'/%3E%3C/svg%3E");
}

@supports (transition-timing-function: linear(0, 1)) {
	:root {
		--spring: linear(0, 0.009, 0.035 2.1%, 0.141, 0.281 6.7%, 0.723 12.9%, 0.938 16.7%, 1.017, 1.077, 1.121, 1.149 24.3%, 1.159, 1.163, 1.161, 1.154 29.9%, 1.129 32.8%, 1.051 39.6%, 1.017 43.1%, 0.991, 0.977 51%, 0.974 53.8%, 0.975 57.1%, 0.997 69.8%, 1.003 76.9%, 1);
	}
}

/* ---------- Baza ---------- */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	/* Tło „za” stroną (przy odbiciu przewijania na iPhonie): ciemne jak nagłówek i stopka,
	   dzięki temu nad menu i pod stopką nie widać jasnego pustego pola. */
	background: var(--ink);
	overscroll-behavior-y: none;
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: calc(var(--header-h) + 12px);
}

body {
	margin: 0;
	min-height: 100vh;
	min-height: 100dvh;
	background: var(--ink);
	color: var(--ink);
	font-family: var(--font-body);
	font-size: 1.0625rem;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

body.nav-open {
	overflow: hidden;
}

img,
svg {
	max-width: 100%;
	height: auto;
}

a {
	color: inherit;
}

:focus-visible {
	outline: 3px solid var(--focus, var(--pink));
	outline-offset: 3px;
}

::selection {
	background: var(--pink);
	color: var(--white);
}

.skip-link {
	position: fixed;
	left: 1rem;
	top: -5rem;
	z-index: 100;
	padding: 0.7rem 1rem;
	background: var(--sun);
	border: 3px solid var(--ink);
	border-radius: 10px;
	font-weight: 700;
	transition: top 0.2s;
}
.skip-link:focus {
	top: 1rem;
}

.wrap {
	width: min(100% - var(--gutter) * 2, var(--wrap));
	margin-inline: auto;
}
.wrap--narrow {
	width: min(100% - var(--gutter) * 2, 760px);
}

.icon {
	width: 1.25em;
	height: 1.25em;
	flex: none;
}

/* ---------- Przyciski ---------- */
.btn {
	--bg: var(--sun);
	--fg: var(--ink);
	--sh: var(--ink);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.6em;
	padding: 0.8em 1.35em;
	border: 3px solid var(--ink);
	border-radius: 14px;
	background: var(--bg);
	color: var(--fg);
	font: 700 1.05rem/1.15 var(--font-body);
	text-decoration: none;
	box-shadow: 4px 4px 0 var(--sh);
	cursor: pointer;
	transition: transform 0.35s var(--spring), box-shadow 0.35s var(--spring);
}
.btn:hover {
	transform: translate(-2px, -2px);
	box-shadow: 6px 6px 0 var(--sh);
}
.btn:active {
	transform: translate(3px, 3px);
	box-shadow: 1px 1px 0 var(--sh);
}
.btn svg {
	width: 1.15em;
	height: 1.15em;
	flex: none;
}
.btn--sun {
	--bg: var(--sun);
}
.btn--paper {
	--bg: var(--paper);
}
.btn--ink {
	--bg: var(--ink);
	--fg: var(--white);
	--sh: var(--pink);
}
.btn--sm {
	padding: 0.55em 1em;
	font-size: 0.98rem;
	box-shadow: 3px 3px 0 var(--sh);
}

/* ---------- Nagłówek ---------- */
.site-header {
	position: fixed;
	inset: 0 0 auto 0;
	z-index: 50;
	background: var(--blue);
	transition: background-color 0.3s, box-shadow 0.3s;
}
.admin-bar .site-header {
	top: 32px;
}
@media (max-width: 782px) {
	.admin-bar .site-header {
		top: 46px;
	}
}
.site-header.is-scrolled,
body:not(.home) .site-header,
body.nav-open .site-header {
	background: var(--ink);
}
.site-header.is-scrolled {
	box-shadow: 0 3px 0 var(--pink);
}

.site-header__bar {
	display: flex;
	align-items: center;
	gap: 1rem;
	height: var(--header-h);
	width: min(100% - var(--gutter) * 2, var(--wrap));
	margin-inline: auto;
}

.brand {
	position: relative;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	gap: 0.7rem;
	color: var(--white);
	text-decoration: none;
}
.brand__logo {
	display: block;
	width: auto;
	height: 46px;
}
.brand__mark {
	display: grid;
	place-items: center;
	width: 38px;
	height: 46px;
	color: var(--sun);
	transform-origin: 50% 100%;
	transition: transform 0.6s var(--spring);
}
.brand:hover .brand__mark {
	transform: scaleY(1.18) rotate(-4deg);
}
.brand__spring {
	width: 100%;
	height: 100%;
}
.brand__text {
	display: grid;
	line-height: 1;
}
.brand__small {
	font-weight: 700;
	font-size: 0.9rem;
	opacity: 0.85;
}
.brand__big {
	font-family: var(--font-display);
	font-size: 1.45rem;
	line-height: 1.25;
}

/* Menu (kotwice) */
.nav {
	display: flex;
	align-items: center;
	gap: 1.75rem;
	margin-left: auto;
}
.nav__list {
	display: flex;
	gap: 1.6rem;
	margin: 0;
	padding: 0;
	list-style: none;
}
.nav__list a {
	position: relative;
	display: inline-block;
	padding: 0.4rem 0;
	color: var(--white);
	font-weight: 700;
	text-decoration: none;
}
.nav__list a::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: -4px;
	height: 12px;
	background: var(--pink);
	-webkit-mask: var(--coil-h) repeat-x center / 10px 12px;
	mask: var(--coil-h) repeat-x center / 10px 12px;
	transform: scaleX(0);
	transform-origin: left center;
	transition: transform 0.5s var(--spring);
}
.nav__list a:hover::after,
.nav__list a:focus-visible::after,
.nav__list a[aria-current="true"]::after {
	transform: scaleX(1);
}

.header-call,
.nav-toggle {
	display: none;
}

@media (max-width: 959px) {
	.header-call {
		position: relative;
		z-index: 2;
		display: grid;
		place-items: center;
		width: 46px;
		height: 46px;
		margin-left: auto;
		border: 3px solid var(--ink);
		border-radius: 50%;
		background: var(--sun);
		color: var(--ink);
		box-shadow: 3px 3px 0 var(--ink);
	}
	.nav-toggle {
		position: relative;
		z-index: 2;
		display: grid;
		place-items: center;
		width: 46px;
		height: 46px;
		padding: 0;
		border: 3px solid var(--paper);
		border-radius: 12px;
		background: transparent;
		color: var(--paper);
		cursor: pointer;
	}
	.nav-toggle__lines {
		position: relative;
		width: 22px;
		height: 16px;
	}
	.nav-toggle__lines span {
		position: absolute;
		left: 0;
		width: 100%;
		height: 3px;
		border-radius: 2px;
		background: currentColor;
		transition: transform 0.4s var(--spring), opacity 0.2s, top 0.3s;
	}
	.nav-toggle__lines span:nth-child(1) {
		top: 0;
	}
	.nav-toggle__lines span:nth-child(2) {
		top: 6.5px;
	}
	.nav-toggle__lines span:nth-child(3) {
		top: 13px;
	}
	.nav-open .nav-toggle__lines span:nth-child(1) {
		top: 6.5px;
		transform: rotate(45deg);
	}
	.nav-open .nav-toggle__lines span:nth-child(2) {
		opacity: 0;
	}
	.nav-open .nav-toggle__lines span:nth-child(3) {
		top: 6.5px;
		transform: rotate(-45deg);
	}

	.nav {
		position: fixed;
		inset: 0;
		z-index: 1;
		flex-direction: column;
		align-items: flex-start;
		justify-content: center;
		gap: 2rem;
		padding: calc(var(--header-h) + 1.5rem) var(--gutter) 2rem;
		background: var(--blue);
		visibility: hidden;
		opacity: 0;
		transform: translateY(-1.5rem);
		transition: opacity 0.3s, transform 0.5s var(--spring), visibility 0s 0.5s;
	}
	.nav-open .nav {
		visibility: visible;
		opacity: 1;
		transform: none;
		transition: opacity 0.3s, transform 0.5s var(--spring), visibility 0s;
	}
	.nav__list {
		flex-direction: column;
		gap: 0.4rem;
	}
	.nav__list a {
		font-family: var(--font-display);
		font-size: clamp(1.7rem, 7.5vw, 2.4rem);
		line-height: 1.3;
	}
	.nav__phone {
		align-self: stretch;
		justify-content: center;
	}
}

@media (min-width: 960px) {
	.nav__phone {
		white-space: nowrap;
	}
}

/* ---------- Hero ---------- */
.hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	padding: calc(var(--header-h) + clamp(2rem, 6vw, 4.5rem)) 0 clamp(4.5rem, 8vw, 7rem);
	background: var(--blue);
	color: var(--white);
	--focus: var(--sun);
}
.hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background-image: radial-gradient(rgba(255, 255, 255, 0.16) 1.6px, transparent 1.8px);
	background-size: 24px 24px;
	-webkit-mask-image: radial-gradient(ellipse at 15% 100%, #000, transparent 65%);
	mask-image: radial-gradient(ellipse at 15% 100%, #000, transparent 65%);
}
.hero__spot {
	position: absolute;
	top: 6%;
	right: -8%;
	z-index: -1;
	width: min(70vw, 760px);
	aspect-ratio: 1;
	border-radius: 50%;
	background: radial-gradient(closest-side, rgba(255, 255, 255, 0.24), rgba(255, 255, 255, 0));
	pointer-events: none;
}
.hero__star {
	position: absolute;
	z-index: -1;
	display: block;
	pointer-events: none;
	animation: twinkle 4.5s ease-in-out infinite;
}
.hero__star svg {
	display: block;
	width: 100%;
	height: 100%;
}
.hero__star--1 {
	top: 22%;
	left: 46%;
	width: 26px;
	color: var(--sun);
}
.hero__star--2 {
	bottom: 14%;
	left: 6%;
	width: 18px;
	color: var(--pink);
	animation-delay: -1.5s;
}
.hero__star--3 {
	top: 14%;
	right: 8%;
	width: 34px;
	color: var(--paper);
	opacity: 0.8;
	animation-delay: -3s;
}
@keyframes twinkle {
	0%,
	100% {
		transform: scale(0.7) rotate(0deg);
	}
	50% {
		transform: scale(1.1) rotate(25deg);
	}
}

.hero__grid {
	display: grid;
	grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.6fr);
	gap: clamp(2rem, 4vw, 3.5rem);
	align-items: center;
}

.hero__title {
	margin: 0 0 1.3rem;
	font-family: var(--font-display);
	font-weight: 400;
	font-size: clamp(1.9rem, 4.1vw, 3.7rem);
	line-height: 1.32;
	text-wrap: balance;
}
.hero__lead {
	margin: 0;
	max-width: 32ch;
	font-size: clamp(1.1rem, 1.7vw, 1.4rem);
	line-height: 1.5;
}
.hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem 1.1rem;
	margin-top: 2.1rem;
}

/* ---------- Sztuczka z kartą ---------- */
.trick {
	--cw: 128px;
	--ch: 188px;
	position: relative;
	display: grid;
	justify-items: center;
	gap: 1.4rem;
}
.trick__fan {
	position: relative;
	width: min(100%, 340px);
	height: 262px;
	margin-bottom: 2.2rem;
}
.pcard {
	--rot: calc((var(--i) - 2) * 12deg);
	position: absolute;
	left: 50%;
	bottom: 0;
	width: var(--cw);
	height: var(--ch);
	margin-left: calc(var(--cw) / -2);
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	cursor: pointer;
	perspective: 800px;
	transform-origin: 50% 165%;
	transform: rotate(var(--rot));
	transition: transform 0.9s var(--spring) calc(var(--i) * 70ms), opacity 0.45s;
	-webkit-tap-highlight-color: transparent;
}
.js .trick:not(.is-fanned) .pcard {
	transform: translateY(26px) rotate(0deg);
}
.trick:not(.is-picked) .pcard:hover,
.trick:not(.is-picked) .pcard:focus-visible {
	transform: rotate(var(--rot)) translateY(-18px);
	transition-delay: 0s;
	z-index: 3;
}
.trick.is-picked .pcard {
	cursor: default;
	transition-delay: 0s;
}
.trick.is-picked .pcard:not(.is-chosen) {
	opacity: 0;
	pointer-events: none;
	transform: rotate(var(--rot)) translateY(150px);
}
.trick.is-picked .pcard.is-chosen {
	z-index: 5;
	transform: rotate(0deg) translateY(-26px) scale(1.18);
}

.pcard__inner {
	position: absolute;
	inset: 0;
	transform-style: preserve-3d;
	transition: transform 0.9s var(--spring);
}
.pcard.is-chosen .pcard__inner {
	transform: rotateY(180deg);
}
.pcard__face {
	position: absolute;
	inset: 0;
	overflow: hidden;
	border: 3px solid var(--ink);
	border-radius: 14px;
	box-shadow: 4px 4px 0 var(--ink);
	-webkit-backface-visibility: hidden;
	backface-visibility: hidden;
}
.pcard__back {
	background: var(--pink);
	color: var(--white);
}
.pcard__back::before {
	content: "";
	position: absolute;
	inset: 7px;
	border: 2px solid rgba(255, 255, 255, 0.75);
	border-radius: 8px;
}
.pcard__spring {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 50%;
	height: 66%;
	transform: translate(-50%, -50%);
}
.pcard__front {
	background: var(--sun);
	color: var(--ink);
	transform: rotateY(180deg);
}
.pcard__spring--front {
	color: var(--blue);
}
.pcard__corner {
	position: absolute;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 2px;
	font-family: var(--font-display);
	font-size: 0.95rem;
	line-height: 1.1;
}
.pcard__corner svg {
	width: 12px;
	height: 12px;
}
.pcard__corner--tl {
	top: 8px;
	left: 9px;
}
.pcard__corner--br {
	right: 9px;
	bottom: 8px;
	transform: rotate(180deg);
}

.trick__text {
	display: grid;
	align-content: start;
	width: 100%;
	max-width: 24rem;
	min-height: 12.5rem;
	text-align: center;
}
.trick__prompt,
.trick__result {
	grid-area: 1 / 1;
	align-self: start;
	margin: 0;
	transition: opacity 0.35s, visibility 0.35s;
}
.trick__prompt {
	font-family: var(--font-display);
	font-size: clamp(1rem, 1.5vw, 1.2rem);
	line-height: 1.5;
}
.trick__result[hidden] {
	display: none;
}
.trick__result {
	display: block;
}
.trick.is-picked .trick__prompt {
	opacity: 0;
	visibility: hidden;
}
.trick__result.is-in {
	animation: pop-in 0.7s var(--spring) both;
}
@keyframes pop-in {
	from {
		opacity: 0;
		transform: translateY(14px) scale(0.92);
	}
	to {
		opacity: 1;
		transform: none;
	}
}
.trick__result-title {
	margin: 0 0 0.4rem;
	font-family: var(--font-display);
	font-size: clamp(1.4rem, 2.4vw, 1.9rem);
	line-height: 1.25;
	color: var(--sun);
	outline: none;
}
.trick__result-text {
	margin: 0 0 1rem;
	font-size: 1.05rem;
	line-height: 1.5;
}
.trick__result-actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.8rem;
}
.no-js .trick {
	display: none;
}

.spark {
	position: absolute;
	z-index: 6;
	width: 14px;
	height: 14px;
	pointer-events: none;
	clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
}

/* ---------- Dzielniki: sprężyna ---------- */
.coil {
	--coil-color: var(--pink);
	position: relative;
	z-index: 3;
	height: 34px;
	margin: -17px 0;
	background: var(--coil-color);
	-webkit-mask: var(--coil-h) repeat-x center / 22px 34px;
	mask: var(--coil-h) repeat-x center / 22px 34px;
	pointer-events: none;
	transition: -webkit-mask-size 1.2s var(--spring), mask-size 1.2s var(--spring);
}
.coil--blue {
	--coil-color: var(--blue);
}
.js .coil:not(.is-in) {
	-webkit-mask-size: 5px 34px;
	mask-size: 5px 34px;
}

/* ---------- Sekcje: wspólne ---------- */
.section {
	position: relative;
	padding: clamp(4rem, 9vw, 7.5rem) 0;
}
.section__title {
	margin: 0 0 1rem;
	font-family: var(--font-display);
	font-weight: 400;
	font-size: clamp(1.8rem, 4vw, 3.1rem);
	line-height: 1.3;
	text-wrap: balance;
}
.section__title--sm {
	font-size: clamp(1.25rem, 2.4vw, 1.8rem);
}
.section__lead {
	margin: 0;
	max-width: 46ch;
	font-size: clamp(1.05rem, 1.5vw, 1.25rem);
	line-height: 1.55;
}
.section__head {
	margin-bottom: clamp(2rem, 4vw, 3.2rem);
}

.admin-hint {
	display: inline-block;
	margin: 1.2rem 0 0;
	padding: 0.4rem 0.8rem;
	border: 2px dashed currentColor;
	border-radius: 10px;
	font-size: 0.9rem;
}

/* ---------- Pokazy (oferta) ---------- */
.shows {
	background: var(--paper);
	--focus: var(--blue);
}
.shows__list {
	margin: 0;
	padding: 0;
	list-style: none;
	border-top: 3px solid var(--ink);
}
.show {
	position: relative;
	padding-left: calc(34px + 1.4rem);
	border-bottom: 3px solid var(--ink);
}
.show::before {
	content: "";
	position: absolute;
	left: 0;
	top: 1.3rem;
	bottom: 1.3rem;
	width: 34px;
	background: var(--pink);
	-webkit-mask: var(--coil-v) repeat-y center top / 34px 14px;
	mask: var(--coil-v) repeat-y center top / 34px 14px;
	transition: -webkit-mask-size 0.8s var(--spring), mask-size 0.8s var(--spring), background-color 0.3s;
}
.show.is-open::before {
	background: var(--blue);
	-webkit-mask-size: 34px 24px;
	mask-size: 34px 24px;
}
.show__heading {
	margin: 0;
}
.show__toggle {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	grid-template-areas: "name plus" "sub plus";
	align-items: center;
	column-gap: 1rem;
	width: 100%;
	padding: 1.3rem 0;
	border: 0;
	background: none;
	color: inherit;
	font: inherit;
	text-align: left;
	cursor: pointer;
}
.show__name {
	grid-area: name;
	font-family: var(--font-display);
	font-size: clamp(1.15rem, 2.8vw, 2rem);
	line-height: 1.3;
}
.show__sub {
	grid-area: sub;
	margin-top: 0.15rem;
	font-size: 1rem;
	opacity: 0.75;
}
.show__plus {
	grid-area: plus;
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	border: 3px solid var(--ink);
	border-radius: 50%;
	background: var(--sun);
	transition: transform 0.6s var(--spring), background-color 0.3s;
}
.show__plus svg {
	width: 20px;
	height: 20px;
}
.show__toggle:hover .show__plus {
	background: var(--pink);
}
.show.is-open .show__plus {
	transform: rotate(135deg);
	background: var(--blue);
	color: var(--white);
}
.show__panel {
	display: grid;
	grid-template-rows: 0fr;
	transition: grid-template-rows 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.show.is-open .show__panel {
	grid-template-rows: 1fr;
}
.show__panel-inner {
	min-height: 0;
	overflow: hidden;
	visibility: hidden;
	transition: visibility 0s 0.5s;
}
.show.is-open .show__panel-inner {
	visibility: visible;
	transition-delay: 0s;
}
.show__panel-inner p {
	max-width: 58ch;
	margin: 0 0 1.2rem;
	font-size: 1.15rem;
	line-height: 1.6;
}
.show__panel-inner > :last-child {
	margin-bottom: 1.6rem;
}

/* ---------- FAQ ---------- */
.faq {
	background: var(--paper);
	--focus: var(--blue);
}
.faq .show::before {
	background: var(--blue);
}
.faq .show.is-open::before {
	background: var(--pink);
}
.faq .show__name {
	font-size: clamp(1.05rem, 2.2vw, 1.5rem);
}

/* ---------- O mnie ---------- */
.about {
	background: var(--ink);
	color: var(--paper);
	--focus: var(--sun);
}
.about__grid {
	display: grid;
	grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
	gap: clamp(2.5rem, 6vw, 5.5rem);
	align-items: center;
}
.portrait {
	margin: 0;
}
.portrait__frame {
	position: relative;
	aspect-ratio: 4 / 5;
	overflow: hidden;
	border: 4px solid var(--paper);
	border-radius: 22px;
	background: var(--blue);
	box-shadow: 10px 10px 0 var(--pink);
	transform: rotate(-2deg);
}
.portrait__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.portrait__ph {
	position: absolute;
	inset: 0;
	display: grid;
	place-items: center;
	color: var(--sun);
	background:
		radial-gradient(rgba(255, 255, 255, 0.18) 1.6px, transparent 1.8px) 0 0 / 22px 22px,
		var(--blue);
}
.portrait__spring {
	width: 46%;
	height: auto;
}
.about__body .section__title {
	color: var(--white);
}
.about__text {
	max-width: 58ch;
	font-size: clamp(1.08rem, 1.5vw, 1.25rem);
	line-height: 1.65;
}
.about__text p {
	margin: 0 0 1.1rem;
}
.facts {
	max-width: 34rem;
	margin: 2rem 0 0;
}
.facts__row {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.2rem 1rem;
	padding: 0.8rem 0;
	border-top: 2px solid rgba(244, 242, 255, 0.28);
}
.facts dt {
	opacity: 0.75;
}
.facts dd {
	margin: 0;
	font-weight: 700;
	color: var(--sun);
}

/* ---------- Galeria ---------- */
.gallery {
	background: var(--paper);
	--focus: var(--blue);
}
.gal {
	margin: 0;
	padding: 0;
	list-style: none;
	columns: 3 250px;
	column-gap: 1.2rem;
}
.gal__item {
	break-inside: avoid;
	margin: 0 0 1.2rem;
}
.gal__link {
	display: block;
	overflow: hidden;
	border: 3px solid var(--ink);
	border-radius: 14px;
	background: var(--white);
	box-shadow: 5px 5px 0 var(--ink);
	transition: transform 0.45s var(--spring), box-shadow 0.45s var(--spring);
}
.gal__link:hover,
.gal__link:focus-visible {
	transform: translate(-3px, -3px) rotate(-0.8deg);
	box-shadow: 8px 8px 0 var(--pink);
}
.gal__img {
	display: block;
	width: 100%;
	height: auto;
}
.gal__item--ph {
	display: grid;
	place-items: center;
	border: 3px solid var(--ink);
	border-radius: 14px;
	box-shadow: 5px 5px 0 var(--ink);
}
.gal__item--r0 {
	aspect-ratio: 4 / 5;
}
.gal__item--r1 {
	aspect-ratio: 1;
}
.gal__item--r2 {
	aspect-ratio: 4 / 3;
}
.gal__item--blue {
	background: var(--blue);
	color: var(--sun);
}
.gal__item--sun {
	background: var(--sun);
	color: var(--ink);
}
.gal__item--pink {
	background: var(--pink);
	color: var(--ink);
}
.gal__item--ink {
	background: var(--ink);
	color: var(--sun);
}
.gal__ph-icon {
	width: 34%;
	height: auto;
}
.gal__ph-icon.icon {
	width: 30%;
}

/* Galeria: na start 9 zdjęć, reszta po kliknięciu */
.gal.is-collapsed .gal__item:nth-child(n + 10) {
	display: none;
}
.gal__more-wrap {
	display: flex;
	justify-content: center;
	margin: 1.6rem 0 0;
}
.gal__more[hidden] {
	display: none;
}

/* Lightbox */
.lb {
	width: 100%;
	max-width: none;
	height: 100%;
	max-height: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--white);
}
.lb::backdrop {
	background: rgba(20, 17, 43, 0.93);
}
.lb__stage {
	display: grid;
	place-items: center;
	align-content: center;
	gap: 1rem;
	width: 100%;
	height: 100%;
	padding: 4.5rem 1rem 2rem;
}
.lb__img {
	display: block;
	max-width: min(92vw, 1400px);
	max-height: 78vh;
	width: auto;
	height: auto;
	border: 4px solid var(--paper);
	border-radius: 12px;
	background: var(--ink);
	box-shadow: 8px 8px 0 var(--pink);
}
.lb__cap {
	max-width: 60ch;
	margin: 0;
	text-align: center;
	font-size: 1rem;
}
.lb__btn {
	position: absolute;
	display: grid;
	place-items: center;
	width: 52px;
	height: 52px;
	padding: 0;
	border: 3px solid var(--ink);
	border-radius: 50%;
	background: var(--sun);
	color: var(--ink);
	box-shadow: 3px 3px 0 var(--ink);
	cursor: pointer;
	transition: transform 0.3s var(--spring);
}
.lb__btn:hover {
	transform: scale(1.1);
}
.lb__btn svg {
	width: 24px;
	height: 24px;
}
.lb__btn--close {
	top: 1rem;
	right: 1rem;
}
.lb__btn--prev {
	left: 1rem;
	top: 50%;
	margin-top: -26px;
}
.lb__btn--next {
	right: 1rem;
	top: 50%;
	margin-top: -26px;
}
@media (max-width: 640px) {
	.lb__btn--prev,
	.lb__btn--next {
		top: auto;
		bottom: 1rem;
		margin-top: 0;
	}
}

/* ---------- Zaufali mi ---------- */
.clients {
	padding-bottom: 0;
	background: var(--white);
	--focus: var(--blue);
}
.clients .section__title {
	margin-bottom: 1.6rem;
}
.marquee {
	overflow: hidden;
	margin-top: 0.5rem;
	border-block: 3px solid var(--ink);
	background: var(--paper);
}
.marquee__track {
	display: flex;
	width: max-content;
	animation: marquee var(--marquee-duration, 38s) linear infinite;
}
.marquee:hover .marquee__track,
.marquee:focus-within .marquee__track {
	animation-play-state: paused;
}
.marquee__group {
	display: flex;
	flex: none;
	align-items: center;
	justify-content: space-around;
	gap: 3.5rem;
	min-width: 100vw;
	margin: 0;
	padding: 1.5rem 1.75rem;
	list-style: none;
}
.marquee__group li {
	flex: none;
}
@keyframes marquee {
	to {
		transform: translateX(-50%);
	}
}
.clients__logo {
	display: block;
	width: auto;
	height: 58px;
	max-width: 180px;
	object-fit: contain;
	transition: transform 0.5s var(--spring);
}
.clients__logo:hover {
	transform: scale(1.08);
}
.clients__name {
	display: block;
	font-family: var(--font-display);
	font-size: clamp(1.1rem, 2vw, 1.45rem);
	line-height: 1.3;
	white-space: nowrap;
}

/* ---------- Kontakt ---------- */
.contact {
	background: var(--sun);
	--focus: var(--ink);
}
.contact__grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
	gap: clamp(2.5rem, 5vw, 5rem);
	align-items: start;
}
.bigphone {
	display: inline-flex;
	flex-direction: column;
	margin: 2rem 0 1.6rem;
	color: var(--ink);
	text-decoration: none;
	transform-origin: left center;
	transition: transform 0.5s var(--spring);
}
.bigphone:hover,
.bigphone:focus-visible {
	transform: rotate(-2deg) scale(1.03);
}
.bigphone__label {
	font-weight: 700;
	font-size: 1.1rem;
}
.bigphone__number {
	font-family: var(--font-display);
	font-size: clamp(2rem, 5.4vw, 3.8rem);
	line-height: 1.2;
	text-shadow: 3px 3px 0 var(--white);
	white-space: nowrap;
}
.contact__links {
	display: grid;
	gap: 0.6rem;
	margin: 0;
	padding: 0;
	list-style: none;
}
.contact__links a {
	display: inline-flex;
	align-items: center;
	gap: 0.75rem;
	font-weight: 700;
	text-decoration: none;
}
.contact__links a svg {
	box-sizing: content-box;
	width: 20px;
	height: 20px;
	padding: 9px;
	border: 3px solid var(--ink);
	border-radius: 50%;
	background: var(--white);
	transition: transform 0.4s var(--spring), background-color 0.2s;
}
.contact__links a:hover svg {
	transform: rotate(-12deg) scale(1.1);
	background: var(--pink);
}
.contact__links a span {
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 4px;
}

.formcard {
	padding: clamp(1.2rem, 3vw, 2rem);
	border: 3px solid var(--ink);
	border-radius: 22px;
	background: var(--white);
	box-shadow: 8px 8px 0 var(--ink);
}
.form {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1rem 1.1rem;
}
.field {
	display: grid;
	gap: 0.35rem;
	align-content: start;
}
.field--wide {
	grid-column: 1 / -1;
}
.field label {
	font-weight: 700;
	font-size: 0.97rem;
}
.field input[type="text"],
.field select,
.field textarea {
	width: 100%;
	padding: 0.7em 0.85em;
	border: 3px solid var(--ink);
	border-radius: 10px;
	background: var(--paper);
	color: var(--ink);
	font: inherit;
	font-size: 1rem;
	transition: border-color 0.2s, background-color 0.2s;
}
.field textarea {
	resize: vertical;
	min-height: 7rem;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
	border-color: var(--blue);
	background: var(--white);
	outline: 3px solid var(--blue);
	outline-offset: 1px;
}
.field input.is-invalid,
.field select.is-invalid,
.field textarea.is-invalid {
	border-color: #c4123f;
}
.field--check {
	display: flex;
	align-items: flex-start;
	gap: 0.7rem;
}
.field--check input {
	flex: none;
	width: 22px;
	height: 22px;
	margin: 0.15rem 0 0;
	accent-color: var(--ink);
}
.field--check label {
	font-weight: 400;
	font-size: 0.93rem;
	line-height: 1.45;
}
.form__hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}
.form__status {
	grid-column: 1 / -1;
	min-height: 1.4em;
	margin: 0;
	font-weight: 700;
}
.form__status.is-error {
	color: #b0103a;
}
.formcard__done {
	display: none;
	justify-items: center;
	gap: 0.6rem;
	padding: 1.5rem 0.5rem;
	text-align: center;
}
.formcard.is-sent .form {
	display: none;
}
.formcard.is-sent .formcard__done {
	display: grid;
}
.formcard__spring {
	width: 64px;
	height: auto;
	color: var(--blue);
	transform-origin: 50% 100%;
	animation: boing 1.2s var(--spring) both;
}
@keyframes boing {
	0% {
		transform: scaleY(0.2);
	}
	100% {
		transform: scaleY(1);
	}
}
.formcard__done-title {
	margin: 0;
	font-family: var(--font-display);
	font-size: clamp(1.25rem, 2.6vw, 1.7rem);
	line-height: 1.3;
}
.formcard__done-text {
	margin: 0;
}

/* ---------- Stopka ---------- */
.site-footer {
	padding: 2.2rem 0 2.4rem;
	background: var(--ink);
	color: var(--paper);
	--focus: var(--sun);
}
.site-footer__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1rem 2rem;
}
.site-footer p {
	margin: 0;
}
.site-footer__note {
	font-size: 0.97rem;
}
.site-footer__social {
	display: flex;
	gap: 0.6rem;
	margin: 0;
	padding: 0;
	list-style: none;
}
.site-footer__social a {
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	border: 2px solid var(--paper);
	border-radius: 50%;
	transition: transform 0.4s var(--spring), background-color 0.2s, color 0.2s;
}
.site-footer__social a:hover {
	background: var(--sun);
	color: var(--ink);
	transform: rotate(-10deg) scale(1.08);
}
.site-footer__social svg {
	width: 20px;
	height: 20px;
}
.site-footer__meta {
	display: flex;
	gap: 1.2rem;
	font-size: 0.93rem;
}
.site-footer__meta a {
	text-underline-offset: 3px;
}

/* Podpis twórcy z komiksową chmurką */
.site-footer__meta {
	align-items: center;
}
.credit {
	position: relative;
	display: inline-block;
}
.credit__link {
	position: relative;
	z-index: 2;
	text-underline-offset: 3px;
}
/* Włebek wychyla się zza podpisu i mówi to, co w chmurce */
.credit__peek {
	position: absolute;
	right: 4px;
	bottom: calc(100% + 1px);
	z-index: 1;
	width: 112px;
	height: 124px;
	overflow: hidden;
	pointer-events: none;
}
.credit__peek img {
	position: absolute;
	left: 0;
	bottom: 0;
	display: block;
	width: 100%;
	height: auto;
	transform: translateY(105%) rotate(7deg);
	transform-origin: 50% 100%;
	transition: transform 0.6s var(--spring);
}
.credit:hover .credit__peek img,
.credit:focus-within .credit__peek img,
.credit.is-peek .credit__peek img {
	transform: none;
}
/* Obok Włebka chmurka wyskakuje z jego strony */
.credit--wlebek .credit__bubble {
	right: 122px;
	bottom: calc(100% + 34px);
	transform-origin: 100% 100%;
}
.credit--wlebek .credit__bubble::after {
	right: -12px;
	top: auto;
	bottom: 14px;
	margin-top: 0;
	border: 0;
	border-top: 3px solid var(--ink);
	border-right: 3px solid var(--ink);
	transform: rotate(45deg);
}
.credit__bubble {
	position: absolute;
	right: 0;
	bottom: calc(100% + 16px);
	z-index: 20;
	width: max-content;
	max-width: min(17rem, 80vw);
	padding: 0.7rem 0.95rem;
	border: 3px solid var(--ink);
	border-radius: 16px;
	background: var(--sun);
	color: var(--ink);
	font-size: 0.95rem;
	font-weight: 700;
	line-height: 1.35;
	box-shadow: 4px 4px 0 var(--pink);
	visibility: hidden;
	opacity: 0;
	transform: translateY(10px) scale(0.85);
	transform-origin: 85% 100%;
	pointer-events: none;
	transition: opacity 0.2s, transform 0.5s var(--spring), visibility 0s 0.5s;
}
.credit__bubble::after {
	content: "";
	position: absolute;
	right: 22px;
	top: 100%;
	width: 18px;
	height: 18px;
	margin-top: -11px;
	border-right: 3px solid var(--ink);
	border-bottom: 3px solid var(--ink);
	background: var(--sun);
	transform: rotate(45deg);
}
.credit:hover .credit__bubble,
.credit:focus-within .credit__bubble,
.credit.is-peek .credit__bubble {
	visibility: visible;
	opacity: 1;
	transform: none;
	transition-delay: 0s;
}
@media (max-width: 639px) {
	.credit__bubble {
		right: auto;
		left: 0;
		transform-origin: 15% 100%;
	}
	.credit__bubble::after {
		right: auto;
		left: 22px;
	}
	.credit--wlebek .credit__bubble {
		right: 0;
		left: auto;
		bottom: calc(100% + 136px);
		transform-origin: 85% 100%;
	}
	.credit--wlebek .credit__bubble::after {
		left: auto;
		right: 46px;
		top: 100%;
		bottom: auto;
		margin-top: -11px;
		border: 0;
		border-right: 3px solid var(--ink);
		border-bottom: 3px solid var(--ink);
	}
}

/* ---------- Pływający przycisk „Zadzwoń” (telefony) ---------- */
.call-fab {
	position: fixed;
	right: 1rem;
	bottom: 1rem;
	z-index: 40;
	display: none;
	align-items: center;
	gap: 0.6rem;
	padding: 0.75em 1.1em;
	border: 3px solid var(--ink);
	border-radius: 999px;
	background: var(--sun);
	color: var(--ink);
	font-weight: 700;
	text-decoration: none;
	box-shadow: 4px 4px 0 var(--ink);
	opacity: 0;
	transform: translateY(24px);
	pointer-events: none;
	transition: opacity 0.3s, transform 0.5s var(--spring);
}
.call-fab svg {
	width: 20px;
	height: 20px;
}
@media (max-width: 959px) {
	.call-fab {
		display: inline-flex;
	}
	body.past-hero:not(.nav-open):not(.at-contact) .call-fab {
		opacity: 1;
		transform: none;
		pointer-events: auto;
	}
}

/* ---------- Podstrony i 404 ---------- */
.page-plain {
	min-height: 70vh;
	padding: calc(var(--header-h) + 3rem) 0 5rem;
	background: var(--paper);
	--focus: var(--blue);
}
.entry__title {
	margin: 0 0 1.2rem;
	font-family: var(--font-display);
	font-weight: 400;
	font-size: clamp(1.7rem, 4vw, 2.6rem);
	line-height: 1.25;
}
.entry__title a {
	text-decoration: none;
}
.entry__content {
	font-size: 1.1rem;
}
.entry__content a {
	text-underline-offset: 3px;
}
.entry__content h2,
.entry__content h3 {
	margin: 2rem 0 0.6rem;
	line-height: 1.3;
}
.e404__spring {
	width: 70px;
	margin-bottom: 1rem;
	color: var(--pink);
}

/* ---------- Responsywność ---------- */
@media (max-width: 959px) {
	.hero__grid {
		grid-template-columns: minmax(0, 1fr);
	}
	.hero__copy {
		max-width: 40rem;
	}
	.trick {
		margin-top: 1.5rem;
	}
	.hero__star--1 {
		left: auto;
		right: 12%;
		top: auto;
		bottom: 38%;
	}
	.hero__star--3 {
		top: auto;
		right: 6%;
		bottom: 8%;
	}
	.hero {
		padding-bottom: 3.5rem;
	}
	.hero__actions {
		margin-top: 1.6rem;
	}
	.trick {
		margin-top: 0;
	}
	.trick__text {
		min-height: 13.5rem;
	}
}
@media (max-width: 860px) {
	.about__grid {
		grid-template-columns: minmax(0, 1fr);
	}
	.portrait {
		max-width: 340px;
		margin-inline: 0.5rem;
	}
}
@media (max-width: 899px) {
	.contact__grid {
		grid-template-columns: minmax(0, 1fr);
	}
}
@media (max-width: 559px) {
	.form {
		grid-template-columns: minmax(0, 1fr);
	}
	.trick {
		--cw: 112px;
		--ch: 165px;
	}
	.trick__fan {
		height: 232px;
		margin-bottom: 1.4rem;
	}
	.hero__actions .btn {
		width: 100%;
	}
	.show {
		padding-left: calc(26px + 1rem);
	}
	.show::before {
		width: 26px;
	}
	.show__plus {
		width: 38px;
		height: 38px;
	}
	.gal {
		columns: 2 140px;
		column-gap: 0.8rem;
	}
	.gal__item {
		margin-bottom: 0.8rem;
	}
}

/* ---------- Ograniczenie ruchu ---------- */
@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
	*,
	*::before,
	*::after {
		animation-duration: 0.001ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.001ms !important;
		transition-delay: 0s !important;
	}
	.hero__star {
		animation: none;
	}
	.marquee__track {
		width: auto;
		flex-wrap: wrap;
		animation: none;
	}
	.marquee__group {
		min-width: 0;
		flex-wrap: wrap;
	}
	.marquee__group[aria-hidden="true"] {
		display: none;
	}
}
