/* STAYGO | Global marketing typography v2 | 23 Nov 2026.
   One canonical, cache-busted stylesheet for all Polish and English public pages.
   Controls headings only; leaves application panels, data, analytics and forms untouched.
   Mandatory stg-h class + semantic variant. Forced line breaks use stg-heading-line.
*/
:root {
  --stg-type-hero: clamp(50px, 6.15vw, 96px);
  --stg-type-page: clamp(44px, 5.45vw, 78px);
  --stg-type-section: clamp(35px, 4.15vw, 64px);
  --stg-type-section-sm: clamp(31px, 3.4vw, 51px);
  --stg-type-feature: clamp(25px, 3vw, 43px);
  --stg-type-card: clamp(21px, 1.9vw, 28px);
  --stg-type-plan: clamp(21px, 1.75vw, 26px);
  --stg-type-article: clamp(30px, 3.05vw, 44px);
  --stg-type-article-small: 23px;
}
/* Class-based hierarchy beats legacy tag selectors without changing section color/weight. */
:is(h1,h2,h3,h4).stg-h {
  line-height: var(--stg-type-leading, 1.3) !important;
  letter-spacing: var(--stg-type-tracking, -.025em) !important;
  text-wrap: balance;
  overflow-wrap: break-word;
  word-break: normal;
  font-kerning: normal;
  max-width: 100%;
}
/* Keep <br> as a no-CSS fallback, but use an explicit separate line with a real gap. */
:is(h1,h2,h3,h4).stg-h > br { display:none; }
:is(h1,h2,h3,h4).stg-h > .stg-heading-line {
  display: block;
  margin-block-start: .14em;
  line-height: inherit;
}
/* Forced lines that were plain text must not inherit muted-color styles for spans. */
:is(h1,h2,h3,h4).stg-h > .stg-heading-line--plain { color:inherit !important; }

h1.stg-h--hero {
  --stg-type-leading: 1.18;
  --stg-type-tracking: -.034em;
  font-size: var(--stg-type-hero) !important;
  margin-block-end: 32px !important;
}
h1.stg-h--hero > .stg-heading-line {margin-block-start: .19em;}
h1.stg-h--page {
  --stg-type-leading: 1.25;
  --stg-type-tracking: -.034em;
  font-size: var(--stg-type-page) !important;
  margin-block-end: 30px;
}
h1.stg-h--page > .stg-heading-line {margin-block-start:.14em;}

h2.stg-h--section {
  --stg-type-leading: 1.28;
  --stg-type-tracking: -.03em;
  font-size: var(--stg-type-section) !important;
  margin-block-end: 25px;
}
h2.stg-h--section > .stg-heading-line {margin-block-start: .16em;}
:is(h2,h3).stg-h--section-compact {
  --stg-type-leading: 1.3;
  --stg-type-tracking: -.028em;
  font-size: var(--stg-type-section-sm) !important;
  margin-block-end: 21px;
}
h3.stg-h--feature {
  --stg-type-leading: 1.31;
  --stg-type-tracking: -.024em;
  font-size: var(--stg-type-feature) !important;
}
:is(h3,h4).stg-h--card {
  --stg-type-leading: 1.37;
  --stg-type-tracking: -.02em;
  font-size: var(--stg-type-card) !important;
}
h3.stg-h--subheading {
  --stg-type-leading: 1.31;
  --stg-type-tracking: -.025em;
  font-size: clamp(29px, 3vw, 42px) !important;
}
h3.stg-h--plan {
  --stg-type-leading: 1.32;
  --stg-type-tracking: -.02em;
  font-size: var(--stg-type-plan) !important;
}
h3.stg-h--form {
  --stg-type-leading: 1.35;
  --stg-type-tracking: -.02em;
  font-size: clamp(22px, 2.1vw, 27px) !important;
}
:is(h2,h3,h4).stg-h--ui {
  --stg-type-leading: 1.33;
  --stg-type-tracking: -.015em;
}
h2.stg-h--article-section {
  --stg-type-leading: 1.34;
  --stg-type-tracking: -.026em;
  font-size: var(--stg-type-article) !important;
  margin-block-end: 26px;
}
h3.stg-h--article-subsection {
  --stg-type-leading: 1.4;
  --stg-type-tracking: -.015em;
  font-size: var(--stg-type-article-small) !important;
  margin-block-end: 16px;
}
/* Login is a separate layout. Keep sizes/weights unchanged, fix leading only. */
h1.stg-h--login-lead {--stg-type-leading: 1.25;--stg-type-tracking: -.035em;}
h2.stg-h--login-form {--stg-type-leading: 1.3;--stg-type-tracking: -.025em;}

/* Small embedded interface titles and special CTA blocks keep their original spacing. */
.stg-stage-window .stg-h--ui, .demo-app .stg-h--ui {margin-block-end:0;}
.stg-interlude h2.stg-h--section {margin-block-end:0;}
.stg-article-closing h2.stg-h--section-compact {margin-block:20px 25px !important;}
.stg-related-article h2.stg-h--section-compact {margin-block-end:0;}
.stg-new-plan h3.stg-h--plan {margin-block-end:16px !important;}
.stg-founder-author h3.stg-h--card {font-size:25px !important;margin-block-end:10px;}
@media (max-width:980px) {
 :root {--stg-type-hero:clamp(48px,6.9vw,82px);--stg-type-page:clamp(42px,6vw,68px);--stg-type-section:clamp(34px,4.9vw,55px);}
}
@media (max-width:640px) {
 :root {
   --stg-type-hero:clamp(38px,9.5vw,55px);
   --stg-type-page:clamp(36px,8.8vw,57px);
   --stg-type-section:clamp(31px,8.2vw,46px);
   --stg-type-section-sm:clamp(28px,7.5vw,40px);
   --stg-type-feature:clamp(24px,7.2vw,33px);
   --stg-type-card:clamp(20px,5.8vw,25px);
   --stg-type-plan:22px;
   --stg-type-article:clamp(28px,7.4vw,35px);
   --stg-type-article-small:21px;
 }
 h1.stg-h--hero {margin-block-end:25px !important;}
 h1.stg-h--hero > .stg-heading-line {margin-block-start:.18em;}
 h1.stg-h--page {margin-block-end:25px;}
 h2.stg-h--section {margin-block-end:22px;}
 h2.stg-h--section > .stg-heading-line {margin-block-start:.14em;}
 h2.stg-h--article-section {margin-block-end:22px;}
 .stg-article-closing h2.stg-h--section-compact {margin-block:16px 21px !important;}
}
