/* =========================================================================
   KAMAN – SKALA TYPOGRAFICZNA
   Ten plik jest kolejkowany JAKO OSTATNI. Reguły komponentów mają taką samą
   specyfikację (.kmn-theme .klasa), więc o wyniku decyduje kolejność wczytania –
   trzymanie skali w globals.css sprawiało, że home.css/pages.css ją nadpisywały.
   ========================================================================= */

/* =========================================================================
   SKALA TYPOGRAFICZNA (ustalona z klientem)
   H1 60 / H2 40 / H3 32 / eyebrow 14 / tekst 16.
   Wartości desktopowe są górną granicą clamp() – na wąskich ekranach schodzą
   proporcjonalnie w dół. Prefiks .kmn-theme, bo reguły komponentów mają (0,1,0).
   ========================================================================= */

:root {
	--kmn-h1: clamp(36px, 5vw, 60px);
	--kmn-h2: clamp(28px, 3.6vw, 40px);
	--kmn-h3: clamp(22px, 2.6vw, 32px);
	--kmn-eyebrow-fs: 14px;
	--kmn-text-fs: 16px;
}

/* --- H1 --- */
.kmn-theme .kmn-hero__title,
.kmn-theme .kmn-pagehead__title,
.kmn-theme .kmn-ohero__title,
.kmn-theme .kmn-strefa__title,
.kmn-theme .kmn-wiz__title,
.kmn-theme .kmn-kontakt__title,
.kmn-theme .kmn-shophead__title,
.kmn-theme .kmn-prod__title,
.kmn-theme .kmn-real__title,
.kmn-theme .kmn-404__title,
.kmn-theme .kmn-colviewer__title {
	font-size: var(--kmn-h1);
	line-height: 1.04;
}

.kmn-theme .kmn-hero__title {
	max-width: 22ch;
}

/* --- H2 --- */
.kmn-theme .kmn-h2,
.kmn-theme .kmn-h2--tight,
.kmn-theme .kmn-feat__title,
.kmn-theme .kmn-about__title,
.kmn-theme .kmn-opinie__title,
.kmn-theme .kmn-mats__title,
.kmn-theme .kmn-cta__title,
.kmn-theme .kmn-chapter__title,
.kmn-theme .kmn-paryz__title,
.kmn-theme .kmn-related__title,
.kmn-theme .kmn-shopnote__title,
.kmn-theme .kmn-pusto__title,
.kmn-theme .kmn-note__title,
.kmn-theme .kmn-doc h2 {
	font-size: var(--kmn-h2);
	line-height: 1.08;
}

/* --- H3 --- */
.kmn-theme .kmn-wyr__h,
.kmn-theme .kmn-proces__h,
.kmn-theme .kmn-wizstep__h,
.kmn-theme .kmn-ms__title,
.kmn-theme .kmn-mat__name,
.kmn-theme .kmn-galitem__label,
.kmn-theme .kmn-faq__qtext,
.kmn-theme .kmn-room__name,
.kmn-theme .kmn-form__title,
.kmn-theme .kmn-formok__title,
.kmn-theme .kmn-drawer__headtitle,
.kmn-theme .kmn-kontakt__firma,
.kmn-theme .kmn-wiz__sub,
.kmn-theme .kmn-doc h3 {
	font-size: var(--kmn-h3);
	line-height: 1.2;
}

/* --- eyebrow / nadtytuły --- */
.kmn-theme .kmn-eyebrow,
.kmn-theme .kmn-hero__eyebrow,
.kmn-theme .kmn-strefa__sub,
.kmn-theme .kmn-footer__title,
.kmn-theme .kmn-kontakt__label,
.kmn-theme .kmn-chapter__num,
.kmn-theme .kmn-ms__meta,
.kmn-theme .kmn-card__room,
.kmn-theme .kmn-prod__room,
.kmn-theme .kmn-prod__speclabel,
.kmn-theme .kmn-prod__badgelab,
.kmn-theme .kmn-galitem__cat,
.kmn-theme .kmn-real__meta strong,
.kmn-theme .kmn-real__meta a,
.kmn-theme .kmn-colviewer__kicker,
.kmn-theme .kmn-col__label,
.kmn-theme .kmn-ci__room,
.kmn-theme .kmn-field label,
.kmn-theme .kmn-room__count,
.kmn-theme .kmn-strefa__count,
.kmn-theme .kmn-real__meta span,
.kmn-theme .kmn-404__linkslabel,
.kmn-theme .kmn-field__legend {
	font-size: var(--kmn-eyebrow-fs);
}

/* --- tekst --- */
.kmn-theme .kmn-lead,
.kmn-theme .kmn-hero__lead,
.kmn-theme .kmn-pagehead__lead,
.kmn-theme .kmn-strefa__lead,
.kmn-theme .kmn-shophead__lead,
.kmn-theme .kmn-wyr__p,
.kmn-theme .kmn-proces__p,
.kmn-theme .kmn-wizstep__p,
.kmn-theme .kmn-feat__p,
.kmn-theme .kmn-about__p,
.kmn-theme .kmn-chapter__p,
.kmn-theme .kmn-mat__blurb,
.kmn-theme .kmn-mats__note,
.kmn-theme .kmn-mats__foot,
.kmn-theme .kmn-ms__desc,
.kmn-theme .kmn-paryz__p,
.kmn-theme .kmn-wiz__p,
.kmn-theme .kmn-stat__txt,
.kmn-theme .kmn-ohero__stattxt,
.kmn-theme .kmn-faq__a p,
.kmn-theme .kmn-card__desc,
.kmn-theme .kmn-prod__short p,
.kmn-theme .kmn-prod__long p,
.kmn-theme .kmn-real__lead,
.kmn-theme .kmn-real__text,
.kmn-theme .kmn-pusto__text,
.kmn-theme .kmn-404__lead,
.kmn-theme .kmn-shopnote__text,
.kmn-theme .kmn-note p,
.kmn-theme .kmn-doc p,
.kmn-theme .kmn-doc li,
.kmn-theme .kmn-footer__about,
.kmn-theme .kmn-footer__list,
.kmn-theme .kmn-footer__list a {
	font-size: var(--kmn-text-fs);
}

/* cytat opinii zostaje wyróżniony, ale zbliżony do skali */
.kmn-theme .kmn-opinia__quote {
	font-size: 20px;
	line-height: 1.5;
}

/* motto na „O firmie" jest lidem sekcji hero, nie nagłówkiem */
.kmn-theme .kmn-ohero__lead {
	font-size: clamp(19px, 2.2vw, 24px);
}

/* --- domknięcie skali: liczby ozdobne, opinie, mikro-etykiety, przyciski --- */

:root {
	--kmn-num-lg: clamp(34px, 4.6vw, 50px);  /* duże liczby zostają na 50 – 60 rozbijałoby pas statystyk */
	--kmn-num-sm: var(--kmn-h2);   /* numeratory kroków: 01, 02, 03 */
	--kmn-quote: 20px;             /* cytat opinii i pasek marek */
	--kmn-micro: 12px;             /* plakietki na zdjęciach, stopka dolna */
	--kmn-btn-fs: 13px;
}

.kmn-theme .kmn-stat__num,
.kmn-theme .kmn-ohero__statnum,
.kmn-theme .kmn-paryz__num {
	font-size: var(--kmn-num-lg);
}

.kmn-theme .kmn-wyr__num,
.kmn-theme .kmn-proces__num,
.kmn-theme .kmn-wizstep__num {
	font-size: var(--kmn-num-sm);
}

.kmn-theme .kmn-opinia__quote,
.kmn-theme .kmn-marquee__row,
.kmn-theme .kmn-card__title {
	font-size: var(--kmn-quote);
}

/* katalog: nazwa produktu w siatce ma być zwarta - 2 linie i tyle */
.kmn-theme .kmn-card__title {
	line-height: 1.25;
}

.kmn-theme .kmn-opinia__name,
.kmn-theme .kmn-kontakt__val,
.kmn-theme .kmn-drawer__sumlabel,
.kmn-theme .kmn-card__price,
.kmn-theme .kmn-spec__v,
.kmn-theme .kmn-prod__badgeval {
	font-size: var(--kmn-text-fs);
}

.kmn-theme .kmn-opinia__place,
.kmn-theme .kmn-paryz__lab,
.kmn-theme .kmn-spec__k,
.kmn-theme .kmn-viewbar__count,
.kmn-theme .kmn-chip,
.kmn-theme .kmn-switch__btn,
.kmn-theme .kmn-drawer__headsub,
.kmn-theme .kmn-ci__name,
.kmn-theme .kmn-ci__qty,
.kmn-theme .kmn-ci__price,
.kmn-theme .kmn-toast__text {
	font-size: var(--kmn-eyebrow-fs);
}

.kmn-theme .kmn-imgtag,
.kmn-theme .kmn-cmp__tag,
.kmn-theme .kmn-cmp__hint,
.kmn-theme .kmn-hero__cap,
.kmn-theme .kmn-hero__counter,
.kmn-theme .kmn-card__tag,
.kmn-theme .kmn-prod__tag,
.kmn-theme .kmn-prod__pricenote,
.kmn-theme .kmn-crumbs,
.kmn-theme .kmn-crumbs a,
.kmn-theme .kmn-footer__barin,
.kmn-theme .kmn-doc__note,
.kmn-theme .kmn-drawer__note,
.kmn-theme .kmn-col__label,
.kmn-theme .kmn-colviewer__kicker,
.kmn-theme .kmn-collection__hint,
.kmn-theme .kmn-colviewer__brand,
.kmn-theme .kmn-consent,
.kmn-theme .kmn-form__err {
	font-size: var(--kmn-micro);
}

.kmn-theme .kmn-btn,
.kmn-theme .kmn-textlink,
.kmn-theme .kmn-nav a,
.kmn-theme .kmn-nav__cta,
.kmn-theme .kmn-toast__link,
.kmn-theme .kmn-card__more,
.kmn-theme .kmn-footer__social a {
	font-size: var(--kmn-btn-fs);
}

.kmn-theme .kmn-btn--sm,
.kmn-theme ul.products li.product a.kmn-card__btn {
	font-size: var(--kmn-micro);
}

/* ceny pozostają wyróżnione: duża na karcie produktu, tekstowa w siatce */
.kmn-theme .kmn-prod__price,
.kmn-theme .kmn-prod__price .amount,
.kmn-theme .kmn-prod__price .woocommerce-Price-amount,
.kmn-theme .kmn-drawer__sumval,
.kmn-theme .kmn-drawer__sumval .amount {
	font-size: var(--kmn-h3);
}

/* --- ostatnie odstępstwa wychwycone audytem --- */
.kmn-theme .kmn-kontakt__sociallinks,
.kmn-theme .kmn-kontakt__sociallinks a,
.kmn-theme .kmn-card__price .amount,
.kmn-theme .kmn-card__price .woocommerce-Price-amount,
.kmn-theme .kmn-galitem__plus,
.kmn-theme .kmn-cmp__hint span {
	font-size: var(--kmn-text-fs);
}

.kmn-theme .kmn-ohero__lead,
.kmn-theme .kmn-colviewer__cur,
.kmn-theme .kmn-collection__counter {
	font-size: var(--kmn-quote);
}

.kmn-theme .kmn-galitem__badge,
.kmn-theme .kmn-real__coverbadge,
.kmn-theme .kmn-wiz__tag,
.kmn-theme .kmn-collection__slash,
.kmn-theme .kmn-collection__tot,
.kmn-theme .kmn-colviewer__counter {
	font-size: var(--kmn-micro);
}


/* Lead o szerokości nagłówka.
   Rodzic ma width:max-content, więc o szerokości decyduje najszerszy potomek.
   Akapit z max-width:0 nie wnosi nic do tego wyliczenia (dyktuje nagłówek),
   a min-width:100% i tak każe mu wypełnić blok. */
.kmn-lede {
	width: max-content;
	max-width: 100%;
	/* przy krótkim nagłówku (np. „Kuchnia" na archiwum kategorii) blok zwężał się
	   do szerokości jednego słowa i akapit robił się nieczytelną kolumienką –
	   pilnujemy sensownej długości wiersza. */
	min-width: min(48ch, 100%);
}

.kmn-lede > p {
	max-width: 0;
	min-width: 100%;
}

@media (max-width: 900px) {
	/* krótki nagłówek zwężałby akapit do kilku słów - zwalniamy ograniczenie */
	.kmn-lede {
		width: auto;
	}

	.kmn-lede > p {
		max-width: 66ch;
		min-width: 0;
	}
}

/* Hasła słowne w statystykach (np. „Największy projekt") czytają się jak etykieta,
   nie jak liczba – przy 50 px łamały się na dwie linie i rozjeżdżały opisy. */
.kmn-theme .kmn-stat__num--slowo,
.kmn-theme .kmn-ohero__statnum--slowo {
	font-size: var(--kmn-h3);
	line-height: 1.15;
}

/* Statystyka „bez ograniczeń” – symbol ∞ nie jest liczbą, więc bez tej reguły
   złapałby rozmiar hasła słownego. Ma stać w jednym rzędzie z „2021" i „2". */
.kmn-theme .kmn-stat__num--inf,
.kmn-theme .kmn-ohero__statnum--inf {
	font-size: var(--kmn-num-lg);
	line-height: 1;
}


/* Nagłówek sklepu i archiwum kategorii: opis ma mieć STAŁĄ szerokość, a nie
   dopasowywać się do tytułu – inaczej „Kuchnia" dawała wąską kolumnę, a
   „Meble na wymiar wg pomieszczeń" szeroką. Jedna miara dla obu widoków. */
.kmn-theme .kmn-shophead .kmn-lede {
	width: min(100%, 780px);
	min-width: 0;
}

.kmn-theme .kmn-shophead .kmn-lede > p {
	max-width: none;
	min-width: 0;
}
