/* Base: fonts, reset, elements, focus, type helpers, stand-in chips, motion. */

/* ---------- Self-hosted fonts (Latin subset, variable wght) ----------
   Montserrat and Open Sans, SIL OFL 1.1: see /fonts/OFL.txt.
   Open Sans also ships Latin Extended for Polish names such as "Poznań";
   thanks to unicode-range it downloads only on pages that use such glyphs. */
@font-face {
	font-family: 'Montserrat';
	font-style: normal;
	font-display: swap;
	font-weight: 100 900;
	src: url('/fonts/montserrat-latin-wght-normal.woff2') format('woff2');
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
	font-family: 'Open Sans';
	font-style: normal;
	font-display: swap;
	font-weight: 300 800;
	src: url('/fonts/open-sans-latin-wght-normal.woff2') format('woff2');
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
	font-family: 'Open Sans';
	font-style: normal;
	font-display: swap;
	font-weight: 300 800;
	src: url('/fonts/open-sans-polish-wght-normal.woff2') format('woff2');
	/* Only the Polish letters outside Latin-1 (Poznań in the footer on every
	   page, names and legal terms): 9 KB instead of the 35 KB latin-ext file.
	   Anything else from latin-ext falls back to the system font. */
	unicode-range: U+0104-0107, U+0118-0119, U+0141-0144, U+015A-015B, U+0179-017C;
}

/* Arial, resized to each web font's metrics, stands in until the font
   arrives, so the swap barely moves the text. Values from the font files
   (average width and hhea ascent/descent against Arial's), 2026-10-04. */
@font-face {
	font-family: 'Montserrat Fallback';
	src: local('Arial'), local('ArialMT');
	size-adjust: 105.73%;
	ascent-override: 91.55%;
	descent-override: 23.74%;
	line-gap-override: 0%;
}

@font-face {
	font-family: 'Open Sans Fallback';
	src: local('Arial'), local('ArialMT');
	size-adjust: 101.32%;
	ascent-override: 105.49%;
	descent-override: 28.91%;
	line-gap-override: 0%;
}

/* ---------- 2. Base ---------- */
*,
*::before,
*::after {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

html {
	scroll-behavior: smooth;
	-webkit-text-size-adjust: 100%;
	/* Scrollbars, autofill and validation bubbles in dark too. */
	color-scheme: dark;
	/* Below the footer on short pages, the canvas matches the footer. */
	background-color: var(--c-bg-deep);
}

body {
	background: var(--c-bg);
	color: var(--c-text);
	font-family: var(--font-body);
	font-size: var(--fs-base);
	line-height: 1.65;
	-webkit-font-smoothing: antialiased;
}

img,
video,
svg,
canvas {
	display: block;
	max-width: 100%;
}

img { height: auto; }

[hidden] { display: none !important; }

h1, h2, h3 {
	font-family: var(--font-head);
	color: var(--c-heading);
	line-height: 1.15;
	letter-spacing: -0.01em;
	font-weight: 700;
	/* No heading ends on a lone word where the lines can be evened out. */
	text-wrap: balance;
}

h2 { font-size: var(--fs-3xl); }
h3 { font-size: var(--fs-lg); }

p + p { margin-top: var(--s-4); }

/* Running text avoids a one-word last line (ignored where unsupported). */
p, li, figcaption, dd { text-wrap: pretty; }

ul { list-style: none; }

a {
	color: var(--c-link);
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 0.2em;
	text-decoration-color: rgba(140, 198, 232, 0.45);
	transition: color var(--t-fast), text-decoration-color var(--t-fast);
}

a:hover {
	color: var(--c-heading);
	text-decoration-color: currentColor;
}

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

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

/* Keeps a short phrase on one line, e.g. "61-758 Poznań" (a hyphen is a
   break point). */
.nowrap { white-space: nowrap; }

.skip-link {
	position: absolute;
	left: var(--s-4);
	top: -100px;
	z-index: 3000;
	background: var(--c-heading);
	color: var(--c-bg);
	padding: var(--s-2) var(--s-4);
	border-radius: var(--r-sm);
	font-weight: 600;
}

.skip-link:focus { top: var(--s-4); }

/* ---------- 3. Minor heading ---------- */
/* The footer column titles, the press fact sheet title and the legal
   contents title: small, bold, sentence case. */
.minor-heading {
	font-family: var(--font-head);
	font-size: var(--fs-sm);
	font-weight: 700;
	color: var(--c-heading);
}

.section-head {
	max-width: 680px;
	margin-bottom: var(--s-7);
}

.section-head p {
	margin-top: var(--s-4);
	font-size: var(--fs-md);
	color: var(--c-text-muted);
}

.section-head--center {
	margin-left: auto;
	margin-right: auto;
	text-align: center;
}

.lede {
	font-size: var(--fs-md);
	color: var(--c-text);
}

.muted { color: var(--c-text-muted); }
.mt-4 { margin-top: var(--s-4); }
.mt-6 { margin-top: var(--s-6); }
.small { font-size: var(--fs-sm); }

/* ---------- Stand-in marker (visible PLACEHOLDER chips, dev branches only) ----------
   Every visible chip carries the full
   two-argument marker (what, exact backlog title) from CLAUDE.md, so the
   release grep finds it. These rules stay; the chips themselves must go. */
.stand-in {
	display: inline-block;
	font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace;
	font-size: var(--fs-2xs);
	line-height: 1.3;
	font-weight: 600;
	letter-spacing: 0;
	text-transform: none;
	color: var(--c-standin);
	background: color-mix(in srgb, var(--c-standin) 8%, transparent);
	border: 1px dashed color-mix(in srgb, var(--c-standin) 70%, transparent);
	border-radius: 4px;
	padding: 2px 6px;
	vertical-align: middle;
	max-width: 100%;
	overflow-wrap: anywhere;
}

.stand-in-box {
	display: grid;
	place-items: center;
	text-align: center;
	gap: var(--s-2);
	padding: var(--s-5);
	background:
		repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.025) 0 12px, transparent 12px 24px),
		var(--c-surface-2);
	border: 1px dashed color-mix(in srgb, var(--c-standin) 50%, transparent);
	color: var(--c-text-muted);
	font-size: var(--fs-sm);
}

/* ---------- 19. Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}

	/* Hover lifts are never declared under reduced motion: each sits in a
	   (prefers-reduced-motion: no-preference) block next to its hover rule. */
}
