/* ==========================================================================
   Egzamin na 6 — style motywu
   ========================================================================== */

:root {
	--c-ink: #032d59;
	--c-text: #22334f;
	--c-muted: #5a6880;
	--c-primary: #2c5592;
	--c-primary-dark: #032d59;
	--c-accent: #f5b81e;
	--c-accent-soft: #fef3d6;
	--c-bg: #ffffff;
	--c-soft: #f3f6fa;
	--c-line: #e1e7ef;

	--radius: 16px;
	--radius-sm: 10px;
	--shadow: 0 1px 2px rgba(3, 45, 89, .04), 0 8px 24px rgba(3, 45, 89, .06);

	--font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--w-content: 720px;
	--w-wide: 1120px;
	--gutter: 20px;
}

/* ---------- Podstawy ---------- */

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

html { scroll-behavior: smooth; scroll-padding-top: 90px; }

body {
	margin: 0;
	font-family: var(--font);
	font-size: 1.0625rem;
	line-height: 1.7;
	color: var(--c-text);
	background: var(--c-bg);
	-webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--c-primary); text-underline-offset: .2em; }
a:hover { color: var(--c-primary-dark); }

h1, h2, h3, h4 {
	color: var(--c-ink);
	line-height: 1.2;
	letter-spacing: -.015em;
	margin: 0 0 .5em;
}
h1 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.25rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 1.3rem + 1.2vw, 2.25rem); font-weight: 750; }
h3 { font-size: 1.25rem; font-weight: 700; }

p { margin: 0 0 1em; }

mark {
	background: linear-gradient(transparent 60%, var(--c-accent) 60%);
	color: inherit;
	padding: 0 .1em;
}

.lead { font-size: 1.2rem; color: var(--c-muted); }

.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

.skip-link {
	position: absolute; left: 1rem; top: -100px; z-index: 100;
	background: var(--c-ink); color: #fff; padding: .6rem 1rem; border-radius: var(--radius-sm);
}
.skip-link:focus { top: 1rem; }

:focus-visible { outline: 3px solid var(--c-accent); outline-offset: 2px; }

.container {
	width: min(var(--w-wide), 100% - 2 * var(--gutter));
	margin-inline: auto;
}
.container--narrow { width: min(var(--w-content), 100% - 2 * var(--gutter)); }

/* ---------- Przyciski ---------- */

.btn,
.wp-block-button__link {
	display: inline-block;
	padding: .8em 1.5em;
	border: 2px solid var(--c-primary);
	border-radius: 999px;
	background: var(--c-primary);
	color: #fff;
	font-weight: 650;
	font-size: 1rem;
	line-height: 1.2;
	text-decoration: none;
	transition: background .15s, color .15s, transform .15s;
}
.btn:hover,
.wp-block-button__link:hover {
	background: var(--c-primary-dark);
	border-color: var(--c-primary-dark);
	color: #fff;
	transform: translateY(-1px);
}
.wp-block-button.is-style-outline > .wp-block-button__link {
	background: transparent;
	color: var(--c-primary);
	border-color: currentColor;
	padding: .8em 1.5em;
}
.wp-block-button.is-style-outline > .wp-block-button__link:hover {
	background: var(--c-primary);
	border-color: var(--c-primary);
	color: #fff;
}
.wp-block-buttons { gap: .75rem; }

.link-arrow { font-weight: 650; text-decoration: none; }
.link-arrow::after { content: " →"; }

/* ---------- Nagłówek ---------- */

.site-header {
	position: sticky; top: 0; z-index: 50;
	background: rgba(255, 255, 255, .92);
	backdrop-filter: saturate(180%) blur(10px);
	border-bottom: 1px solid var(--c-line);
}
.admin-bar .site-header { top: var(--wp-admin--admin-bar--height, 32px); }

.site-header__inner {
	display: flex; align-items: center; justify-content: space-between;
	min-height: 72px; gap: 1rem;
}

.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand__logo { display: block; height: 52px; width: auto; }
.custom-logo { max-height: 56px; width: auto; }

.site-nav .menu {
	display: flex; gap: .25rem;
	list-style: none; margin: 0; padding: 0;
}
.site-nav a {
	display: block; padding: .5rem .9rem; border-radius: 999px;
	color: var(--c-ink); font-weight: 600; text-decoration: none;
}
.site-nav a:hover { background: var(--c-soft); }
.site-nav .current-menu-item:not(.menu-item-type-custom) > a,
.site-nav .current_page_parent > a { color: var(--c-primary); background: var(--c-soft); }

.nav-toggle {
	display: none;
	width: 44px; height: 44px; border: 0; border-radius: 12px;
	background: var(--c-soft); cursor: pointer; position: relative;
}
.nav-toggle__bar,
.nav-toggle__bar::before,
.nav-toggle__bar::after {
	position: absolute; left: 12px; width: 20px; height: 2px;
	background: var(--c-ink); border-radius: 2px; transition: transform .2s, opacity .2s;
}
.nav-toggle__bar { top: 21px; }
.nav-toggle__bar::before, .nav-toggle__bar::after { content: ""; left: 0; }
.nav-toggle__bar::before { top: -6px; }
.nav-toggle__bar::after { top: 6px; }
.nav-open .nav-toggle__bar { background: transparent; }
.nav-open .nav-toggle__bar::before { transform: translateY(6px) rotate(45deg); }
.nav-open .nav-toggle__bar::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 760px) {
	.nav-toggle { display: block; }
	.site-nav {
		position: absolute; left: 0; right: 0; top: 100%;
		background: #fff; border-bottom: 1px solid var(--c-line);
		padding: .5rem var(--gutter) 1rem;
		display: none;
	}
	.nav-open .site-nav { display: block; }
	.site-nav .menu { flex-direction: column; }
	.site-nav a { padding: .75rem 1rem; }
}

/* ---------- Treść stron (bloki) ---------- */

.site-main { min-height: 60vh; }

.entry-content {
	display: grid;
	grid-template-columns:
		[full-start] minmax(var(--gutter), 1fr)
		[wide-start] minmax(0, calc((var(--w-wide) - var(--w-content)) / 2))
		[content-start] min(var(--w-content), 100% - 2 * var(--gutter))
		[content-end] minmax(0, calc((var(--w-wide) - var(--w-content)) / 2))
		[wide-end] minmax(var(--gutter), 1fr)
		[full-end];
	padding-bottom: 4rem;
}
.entry-content > * { grid-column: content; margin-block: 0; }
.entry-content > * + * { margin-top: 1.25rem; }
.entry-content > h2 { margin-top: 2.5rem; }
.entry-content > h3 { margin-top: 2rem; }
.entry-content > .alignwide { grid-column: wide; }
.entry-content > .alignfull { grid-column: full; }

.entry-content ul, .entry-content ol { padding-left: 1.3em; }
.entry-content li + li { margin-top: .35em; }

.entry-content blockquote {
	margin-inline: 0; padding: 1rem 1.5rem;
	border-left: 4px solid var(--c-accent); background: var(--c-accent-soft);
	border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* Sekcje strony głównej */
.entry-content--front { padding-bottom: 0; }
.entry-content--front > * + * { margin-top: 0; }

.section { padding-block: clamp(3rem, 6vw, 5rem); }
.alignfull.section > * { max-width: var(--w-wide); margin-inline: auto; padding-inline: var(--gutter); }
.section--soft { background: var(--c-soft); }

.hero {
	text-align: center;
	padding: clamp(4rem, 10vw, 7rem) var(--gutter);
	background:
		radial-gradient(60rem 30rem at 15% -10%, #dde7f4 0%, transparent 60%),
		radial-gradient(40rem 25rem at 100% 10%, var(--c-accent-soft) 0%, transparent 60%),
		var(--c-bg);
}
.hero > * { max-width: 780px; margin-inline: auto; }
.hero .lead { margin-bottom: 2rem; }
.hero .wp-block-buttons { justify-content: center; }

.eyebrow {
	display: inline-block;
	padding: .35rem .9rem; border-radius: 999px;
	background: #fff; border: 1px solid var(--c-line);
	font-size: .9rem; font-weight: 650; color: var(--c-primary);
	margin-bottom: 1.25rem;
}

.card {
	background: #fff; border: 1px solid var(--c-line);
	border-radius: var(--radius); padding: 1.75rem;
	box-shadow: var(--shadow);
}
.card > :last-child { margin-bottom: 0; }

.features { margin-top: 2rem; gap: 1.5rem; }

.steps {
	counter-reset: step;
	list-style: none;
	padding: 0 !important;
	max-width: var(--w-content) !important;
	display: grid; gap: 1rem;
	margin: 2rem auto 0 !important;
}
.steps li {
	counter-increment: step;
	position: relative;
	background: #fff; border-radius: var(--radius); padding: 1.1rem 1.25rem 1.1rem 4.25rem;
	box-shadow: var(--shadow); margin: 0 !important;
}
.steps li::before {
	content: counter(step);
	position: absolute; left: 1.1rem; top: 50%; transform: translateY(-50%);
	width: 2.2rem; height: 2.2rem; border-radius: 50%;
	display: grid; place-items: center;
	background: var(--c-accent); color: var(--c-ink); font-weight: 800;
}

.cta {
	margin-block: clamp(3rem, 6vw, 5rem) !important;
	background: var(--c-ink); color: #dbe4f0;
	border-radius: calc(var(--radius) * 1.5);
	padding: clamp(2.5rem, 6vw, 4rem) var(--gutter);
}
.cta h2 { color: #fff; }
.cta a { color: var(--c-accent); }
.cta__contact { font-size: 1.25rem; font-weight: 650; line-height: 2; margin: 0; }

/* Cennik */
.pricing { gap: 1.5rem; margin-block: 2rem 1rem !important; align-items: stretch; }
.pricing--two { width: min(760px, 100%); justify-self: center; }
.price-card {
	position: relative;
	display: flex; flex-direction: column;
	background: #fff; border: 2px solid var(--c-line);
	border-radius: var(--radius); padding: 2rem 1.75rem;
	box-shadow: var(--shadow);
	cursor: pointer;
	transition: border-color .2s, box-shadow .2s, transform .2s;
}
.price-card:hover { border-color: #b7c7de; transform: translateY(-2px); }
.price-card:focus-visible { outline: 3px solid var(--c-accent); outline-offset: 3px; }
/* Karta wybrana kliknięciem (assets/js/main.js) */
.price-card.is-selected {
	border-color: var(--c-primary);
	box-shadow: 0 0 0 4px rgba(44, 85, 146, .15), 0 12px 32px rgba(3, 45, 89, .12);
}
.price-card.is-selected .wp-block-button.is-style-outline > .wp-block-button__link {
	background: var(--c-primary); border-color: var(--c-primary); color: #fff;
}
.price-card h3 { margin-bottom: .25rem; }
.price-card ul { list-style: none; padding: 0; margin: 1rem 0 1.5rem; flex: 1; }
.price-card li { padding-left: 1.6rem; position: relative; }
.price-card li::before { content: "✓"; position: absolute; left: 0; color: var(--c-primary); font-weight: 800; }
.price-card .wp-block-buttons { margin-top: auto; }
.price-card .wp-block-button, .price-card .wp-block-button__link { width: 100%; text-align: center; }
.price { font-size: 2.25rem; font-weight: 800; color: var(--c-ink); line-height: 1.2; margin: .5rem 0 0; }
.price span { font-size: 1rem; font-weight: 500; color: var(--c-muted); }
.badge {
	position: absolute; top: -.85rem; left: 1.75rem; margin: 0;
	background: var(--c-accent); color: var(--c-ink);
	font-size: .8rem; font-weight: 750; padding: .2rem .75rem; border-radius: 999px;
}

/* O mnie */
.about { gap: clamp(2rem, 5vw, 4rem); align-items: center; margin-block: 1rem 3rem !important; }
.page-header:has(+ .entry-content > .about) { width: min(var(--w-wide), 100% - 2 * var(--gutter)); }
.about__photo { max-width: 400px; margin-inline: auto; }
.about__photo figure { position: relative; margin: 0 1.25rem 1.25rem 0; }
.about__photo figure::before {
	content: ""; position: absolute; inset: 1.25rem -1.25rem -1.25rem 1.25rem;
	background: var(--c-accent); border-radius: calc(var(--radius) * 1.5);
}
.about__photo img {
	position: relative; display: block; width: 100%; aspect-ratio: 1; object-fit: cover;
	border-radius: calc(var(--radius) * 1.5); box-shadow: var(--shadow);
}
.about__text h2 { margin-bottom: .5rem; }
.about__text .lead { color: var(--c-ink); font-weight: 600; }
.about__text .wp-block-buttons { margin-top: 1.75rem; }

/* FAQ */
.wp-block-details {
	border: 1px solid var(--c-line); border-radius: var(--radius-sm);
	padding: 1rem 1.25rem; background: #fff;
}
.entry-content > .wp-block-details + .wp-block-details { margin-top: .75rem; }
.wp-block-details summary { font-weight: 650; color: var(--c-ink); cursor: pointer; }
.wp-block-details[open] summary { margin-bottom: .5rem; }
.wp-block-details > :last-child { margin-bottom: 0; }

/* ---------- Nagłówki podstron ---------- */

.page-header { padding-block: clamp(2.5rem, 6vw, 4.5rem) 1.5rem; }
.page-header h1 { margin-bottom: .3em; }
.page-header .lead { max-width: 640px; }

.meta { color: var(--c-muted); font-size: .92rem; margin-bottom: .5rem; }
.meta a { color: inherit; }

/* ---------- Blog ---------- */

.post-grid {
	display: grid; gap: 1.5rem;
	grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
	padding-bottom: 3rem;
}
.post-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; transition: transform .15s, box-shadow .15s; }
.post-card:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(3, 45, 89, .1); }
.post-card__image img { aspect-ratio: 12 / 7; object-fit: cover; width: 100%; }
.post-card__body { padding: 1.5rem; }
.post-card__title { font-size: 1.2rem; margin-bottom: .5rem; }
.post-card__title a { color: var(--c-ink); text-decoration: none; }
.post-card__title a:hover { color: var(--c-primary); }
.post-card__body p:last-child { margin: 0; color: var(--c-muted); }

.latest { padding-block: 1rem 3rem; }
.latest__head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.latest__head h2 { margin: 0; }

.single-post__image img { border-radius: var(--radius); width: 100%; max-height: 520px; object-fit: cover; margin-bottom: 2.5rem; }

.post-cta {
	background: var(--c-accent-soft); border-radius: var(--radius);
	padding: 2rem; margin-bottom: 4rem;
}
.post-cta__title { font-size: 1.3rem; font-weight: 750; color: var(--c-ink); margin-bottom: .25rem; }
.post-cta__actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; margin: 1.25rem 0 0; }

.pagination .nav-links { display: flex; gap: .5rem; justify-content: center; padding-bottom: 3rem; }
.pagination .page-numbers {
	display: grid; place-items: center; min-width: 42px; height: 42px; padding: 0 .75rem;
	border-radius: 999px; border: 1px solid var(--c-line); text-decoration: none; color: var(--c-ink);
}
.pagination .page-numbers.current { background: var(--c-primary); border-color: var(--c-primary); color: #fff; }

/* ---------- 404 ---------- */

.not-found { text-align: center; padding-bottom: 5rem; }
.not-found__code { font-size: 6rem; font-weight: 900; color: var(--c-accent); line-height: 1; margin: 0; }

/* ---------- Stopka ---------- */

.site-footer { background: var(--c-ink); color: #b8c6d9; padding-top: 3.5rem; font-size: .97rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--c-accent); }
.site-footer__grid { display: grid; gap: 2rem; grid-template-columns: 2fr 1fr 1fr; }
.site-footer__brand { color: #fff; font-weight: 800; font-size: 1.2rem; margin-bottom: .5rem; }
.site-footer__title { color: #fff; font-weight: 700; margin-bottom: .75rem; }
.site-footer__list { list-style: none; margin: 0; padding: 0; }
.site-footer__list li + li { margin-top: .4rem; }
.site-footer__bottom {
	display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
	border-top: 1px solid rgba(255, 255, 255, .1);
	margin-top: 2.5rem; padding-block: 1.25rem; font-size: .88rem;
}
.site-footer__bottom p { margin: 0; }

@media (max-width: 760px) {
	.site-footer__grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	* { transition: none !important; }
}
