/* ============================================================
   BASE — reset, elementy bazowe, typografia, 2 typy buttonów, formularze.
   ============================================================ */

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
	font-family: var(--font-body);
	font-size: var(--text-base);
	line-height: var(--lh-body);
	color: var(--c-ink);
	background: var(--c-bg);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
img, picture, svg, video { display: block; max-width: 100%; height: auto; }
ul, ol { padding: 0; list-style-position: inside; }
a { color: var(--c-brand-ink); text-decoration: none; transition: color var(--dur-fast) var(--ease); }
a:hover { color: var(--c-ink); }
strong { font-weight: var(--fw-semibold); }

/* ── Nagłówki (Kumbh Sans, bold, tight) ── */
h1, h2, h3, h4 {
	font-family: var(--font-display);
	font-weight: 700;
	line-height: var(--lh-tight);
	letter-spacing: var(--ls-tight);
	color: var(--c-ink);
	text-wrap: balance;
}
h1 { font-size: var(--text-2xl); font-weight: 700; }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-lg); font-weight: 700; }
h4 { font-weight: 700; }
p { max-width: 70ch; }

/* ── Focus (a11y) ── */
:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 2px; border-radius: var(--radius-sm); }

/* ── Skip link ── */
.xelox-skip { position: absolute; left: -9999px; top: 0; z-index: var(--z-toast); background: var(--c-ink); color:#fff; padding: var(--sp-3) var(--sp-4); border-radius: 0 0 var(--radius-md) 0; }
.xelox-skip:focus { left: 0; color:#fff; }

/* ============================================================
   BUTTONY — DOKŁADNIE 2 typy. Każdy: default/hover/active/disabled/focus.
   ============================================================ */
.xelox-btn {
	display: inline-flex; align-items: center; gap: 8px;
	padding: 15px 30px;
	border-radius: 3px;
	font-size: 0.9375rem; font-weight: 700; line-height: 1;
	text-decoration: none; border: 2px solid transparent;
	cursor: pointer; transition: background 180ms, border-color 180ms, transform 150ms, box-shadow 180ms;
	white-space: nowrap;
	will-change: transform;
}
.xelox-btn:active { transform: translateY(1px) scale(.99); }
.xelox-btn[disabled], .xelox-btn.is-disabled { opacity: .5; pointer-events: none; }
.xelox-btn .xelox-ico { width: 20px; height: 20px; }

/* 1) PRIMARY — głębszy brand-blue (biały tekst AA ~4.6:1; jasny cyjan zostaje akcentem) */
.xelox-btn--primary {
	background: #0f78a6; color: #fff; border-color: #0f78a6;
}
.xelox-btn--primary:hover {
	background: #0d6a94; border-color: #0d6a94;
	box-shadow: 0 8px 22px rgba(22,31,54, .38);
	transform: translateY(-2px);
	color: #fff;
}

/* 1b) INDIGO (solid, high-contrast conversion CTA) */
.xelox-btn--indigo { background: var(--c-ink); color: #fff; border-color: var(--c-ink); }
.xelox-btn--indigo:hover {
	background: var(--c-navy-2); border-color: var(--c-navy-2);
	box-shadow: 0 8px 22px rgba(35, 35, 90, .32);
	transform: translateY(-2px); color: #fff;
}

/* 2) SECONDARY (ghost / outline) */
.xelox-btn--secondary { background: transparent; color: var(--c-ink); border-color: var(--c-line); }
.xelox-btn--secondary:hover { background: var(--c-brand-soft); border-color: var(--c-brand); color: var(--c-brand-ink); transform: translateY(-2px); }

/* 3) GHOST (for dark backgrounds) */
.xelox-btn--ghost {
	background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45);
}
.xelox-btn--ghost:hover {
	background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .8); color: #fff;
}

.xelox-btn--block { width: 100%; }
.xelox-btn--sm { min-height: 44px; padding: 0 18px; }

/* ── Formularze ── */
input, textarea, select, button { font: inherit; color: inherit; }
input[type=text], input[type=email], input[type=tel], input[type=url],
input[type=number], input[type=search], textarea, select {
	width: 100%;
	padding: 14px 16px;
	background: var(--c-bg);
	border: 1.5px solid var(--c-line);
	border-radius: var(--radius-md);
	transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
}
input:focus, textarea:focus, select:focus { border-color: var(--c-brand); box-shadow: 0 0 0 4px var(--c-brand-soft); outline: none; }
textarea { min-height: 140px; resize: vertical; }
label { font-weight: var(--fw-medium); font-size: var(--text-sm); }

/* ── Prose (treść artykułu / strony) ── */
.xelox-prose { color: var(--c-ink-soft); }
.xelox-prose > * + * { margin-top: var(--sp-4); }
.xelox-prose h2 { margin-top: var(--sp-7); color: var(--c-ink); }
.xelox-prose h3 { margin-top: var(--sp-5); color: var(--c-ink); }
.xelox-prose a { text-decoration: underline; text-underline-offset: 3px; }
.xelox-prose img { border-radius: var(--radius-lg); margin: var(--sp-5) 0; }
.xelox-prose blockquote { border-left: 4px solid var(--c-brand); padding-left: var(--sp-4); color: var(--c-ink); font-style: italic; }
.xelox-prose ul, .xelox-prose ol { padding-left: var(--sp-5); list-style-position: outside; }
.xelox-prose li + li { margin-top: var(--sp-2); }

/* WP a11y: elementy tylko dla czytnikow ekranu (np. naglowek "Stronicowanie wpisow",
   label "Szukaj:") maja byc NIEWIDOCZNE wizualnie - fix na prosbe SEO 2026-07-27. */
.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}
.screen-reader-text:focus {
	position: static !important;
	width: auto;
	height: auto;
	clip: auto;
	clip-path: none;
	white-space: normal;
}
