/* RS Mobile — PL homepage (/) and case-study index (/realizacje/), variant A „Warsztat”.
   Loaded after site.css on the home-pl and cases-pl partials only (cases-en/home-en
   have their own file). Root element .hp; every selector uses the hp- namespace
   (shared rsm-* parts only inside hp- parents), so nothing leaks into the shared
   header/footer. Tokens come from site.css (--rsm-*).
   Markup: pages/home-pl.php (also holds the case-card component) and pages/cases-pl.php. */

.hp {
  --hp-line: #DAD7D0;
  --hp-line-soft: #ECE9E3;
  --hp-chip: #F6F5F2;
  --hp-on-dark: #B4B9C1;
  --hp-on-dark-blue: #6CB0FF;
  --hp-radius: 14px;
}

/* ---- Shared section parts ---------------------------------------------------- */
.hp-sec { padding-block: clamp(56px, 7vw, 96px); }
.hp-sec--white { background: #FFFFFF; border-top: 1px solid var(--hp-line); border-bottom: 1px solid var(--hp-line); }
.hp-sec--dark { background: var(--rsm-dark); color: #FFFFFF; }
.hp-sec__inner { display: flex; flex-direction: column; gap: clamp(32px, 4vw, 48px); }
.hp-sec__inner--tight { gap: clamp(32px, 4vw, 44px); }
.hp-sec__inner--steps { gap: clamp(36px, 4.5vw, 56px); }
.hp-sec__inner--blog { gap: clamp(28px, 3.5vw, 40px); }

.hp-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 64px; }
.hp-head--link { gap: 16px 48px; }
.hp-head__main { flex: 1 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.hp-head__main--wide { flex-basis: 560px; }
.hp-head__intro { flex: 1 1 360px; min-width: 0; max-width: 480px; font-size: 17px; line-height: 1.6; color: var(--rsm-muted); text-wrap: pretty; }
.hp-head__intro--narrow { flex-basis: 340px; max-width: 440px; }
.hp-kicker { font-family: var(--rsm-f-mono); font-size: 13px; font-weight: 500; line-height: 1.4; color: var(--rsm-muted); }
.hp-kicker__n { color: var(--rsm-blue-text); }
.hp .rsm-h2 { font-size: clamp(30px, 3.2vw, 46px); line-height: 1.06; letter-spacing: -0.022em; color: var(--rsm-ink); }

.hp-ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.hp .hp-btn--md { min-height: 48px; font-size: 15px; }
.hp .hp-btn--wide { padding: 0 22px; }
.hp .hp-link {
  display: inline-flex; align-items: center; gap: 8px; padding-block: 12px; margin-block: -12px;
  font-size: 15px; font-weight: 600; line-height: 1.3; text-decoration: none;
}
.hp .hp-link svg { transition: transform .15s ease; }
.hp .hp-link:hover svg { transform: translateX(3px); }
.hp .hp-tel { color: var(--rsm-ink); font-weight: 600; text-decoration: none; white-space: nowrap; border-bottom: 1px solid #BDB8AE; }
.hp .hp-tel:hover { color: var(--rsm-blue-text); border-bottom-color: currentColor; }

/* ---- Hero ---------------------------------------------------------------------- */
.hp-hero { padding-block: clamp(40px, 5vw, 72px) clamp(48px, 5vw, 72px); }
.hp-hero__inner { display: flex; flex-wrap: wrap; align-items: center; gap: 48px 56px; }
.hp-hero__text { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
/* .rsm h1 (site.css) outranks .rsm-display, so weight and leading are restated here. */
.hp .hp-hero__title { font-size: clamp(40px, 3.9vw, 56px); font-weight: 800; line-height: 1.03; color: var(--rsm-ink); }
.hp-hero__lead { display: flex; flex-direction: column; gap: 12px; max-width: 540px; }
.hp-hero__lead p { font-size: clamp(17px, 1.3vw, 19px); line-height: 1.6; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp-hero__lead .hp-hero__direct { font-weight: 600; color: var(--rsm-ink); }
.hp-hero__reply { display: flex; align-items: flex-start; gap: 10px; font-size: 15px; line-height: 1.6; color: var(--rsm-muted); }
.hp-hero__reply svg { flex: none; margin-top: 3px; color: var(--rsm-blue-text); }
.hp-hero__reply > span { min-width: 0; }

.hp-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 24px; padding-top: 22px; border-top: 1px solid var(--hp-line); }
.hp-stats > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.hp-stats dt { font-family: var(--rsm-f-display); font-weight: 700; font-size: 26px; line-height: 1.1; letter-spacing: -0.02em; color: var(--rsm-ink); white-space: nowrap; }
.hp-stats dd { font-size: 14px; line-height: 1.45; color: var(--rsm-muted); }

.hp-hero__fig { flex: 1 1 460px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
/* Three overlapping app windows. Positions are the approved 592 × 540 composition in %. */
.hp-stage { position: relative; align-self: center; width: 100%; max-width: 592px; aspect-ratio: 592 / 540; }
.hp-stage__shot { position: absolute; }
/* The Kuźnia window wraps its <img> in a <picture> (phones get a blank source); lay the image out as before. */
.hp .hp-stage picture { display: contents; }
.hp-stage__shot--a { top: 0; right: 0; width: 92.75%; z-index: 1; }
.hp-stage__shot--b { top: 40%; left: 0; width: 61.15%; z-index: 2; box-shadow: 0 1px 2px rgba(16, 18, 21, 0.06), 0 18px 40px -18px rgba(16, 18, 21, 0.34); }
.hp-stage__shot--c { top: 50.37%; right: 0; width: 58.72%; z-index: 3; box-shadow: 0 1px 2px rgba(16, 18, 21, 0.06), 0 18px 40px -18px rgba(16, 18, 21, 0.36); }
.hp-frame--sm .rsm-frame__bar { height: 26px; gap: 12px; padding: 0 10px; }
.hp-frame--sm .rsm-frame__dots { gap: 5px; }
.hp-frame--sm .rsm-frame__dots span { width: 6px; height: 6px; }

/* ---- Client logos ---------------------------------------------------------------- */
.hp-logos { background: #FFFFFF; border-top: 1px solid var(--hp-line); border-bottom: 1px solid var(--hp-line); }
.hp-logos__inner { padding-block: 28px; display: flex; flex-wrap: wrap; align-items: center; gap: 16px 40px; }
.hp .hp-logos__title { flex: 0 0 auto; font-family: var(--rsm-f-mono); font-size: 13px; font-weight: 500; line-height: 1.4; color: var(--rsm-muted); }
.hp-logos__list { flex: 1 1 720px; min-width: 0; list-style: none; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.hp-logos__list li { display: flex; min-width: 0; }
.hp .hp-logos__tile {
  flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  min-height: 108px; padding: 14px 12px; border: 1px solid #E4E1DA; border-radius: 10px; background: #FFFFFF;
  color: var(--rsm-muted); text-decoration: none; transition: border-color .15s ease, box-shadow .15s ease, color .15s ease;
}
.hp .hp-logos__tile:hover { border-color: var(--rsm-line-strong); color: var(--rsm-ink); box-shadow: 0 10px 24px -18px rgba(16, 18, 21, 0.45); }
.hp-logos__img { height: 56px; max-width: 100%; display: flex; align-items: center; justify-content: center; }
.hp .hp-logos__img img { display: block; max-width: 100%; }
.hp .hp-logo--kuznia-polska img { width: auto; height: 54px; }
.hp .hp-logo--mostostal-zabrze img { width: 150px; height: auto; }
.hp .hp-logo--humavit img { width: auto; height: 56px; }
.hp .hp-logo--lakotech img { width: 128px; height: auto; }
.hp .hp-logo--turlo img { width: auto; height: 50px; }
.hp-logos__sector { font-family: var(--rsm-f-mono); font-size: 11px; line-height: 1.3; text-align: center; }

/* ---- Case cards (homepage + /realizacje/) ------------------------------------------ */
.hp-case--kuznia-polska { --hp-accent: #BD0D0C; --hp-tint: #F2EEE7; --hp-tint-line: #E6E0D5; }
.hp-case--lakotech { --hp-accent: #1D5FAE; --hp-tint: #ECEEF1; --hp-tint-line: #DADDE2; }
.hp-case--humavit { --hp-accent: #16A34A; --hp-tint: #EEF3EC; --hp-tint-line: #DCE4DA; }
.hp-case--mostostal-zabrze { --hp-accent: #22408F; --hp-tint: #EEF1F6; --hp-tint-line: #DCE2EC; }
.hp-case--turlo { --hp-accent: #FF5533; --hp-tint: #F3E6D8; --hp-tint-line: #E6D5C3; }

.hp-cases { display: flex; flex-direction: column; gap: 24px; }
.hp-cases__lg { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.hp-cases__sm { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }

.hp-case {
  position: relative; display: flex; flex-direction: column; min-width: 0; padding-top: 4px;
  background: #FFFFFF; border: 1px solid var(--hp-line); border-radius: var(--hp-radius); overflow: hidden;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.hp-case::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: var(--hp-accent); }
.hp-case:hover { border-color: var(--rsm-line-strong); box-shadow: 0 22px 44px -32px rgba(16, 18, 21, 0.5); }
.hp-case__media {
  display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 24px 24px 14px;
  background: var(--hp-tint); border-bottom: 1px solid var(--hp-tint-line);
}
.hp .hp-case__frame { width: 100%; max-width: 535px; box-shadow: 0 1px 2px rgba(16, 18, 21, 0.05), 0 14px 30px -20px rgba(16, 18, 21, 0.35); }
.hp-case__caption { align-self: stretch; font-size: 11.5px; line-height: 1.4; }
/* Two even lines instead of "(09.2026)" alone on the second one. */
.hp-case--turlo .hp-case__caption { text-wrap: balance; }
/* Turlo card: a 16:10 window of the 1440 × 900 screen, 1128 × 705 px from x 18 — the nav up to and
   including "For organizers" (the cut falls before the language pill), the three result cards, and
   none of the dark band that starts at y 710. */
.hp-shot--zoom { aspect-ratio: 16 / 10; }
.hp .hp-shot--zoom img { width: 127.66%; max-width: none; height: auto; margin-left: -1.596%; }

.hp-case__body { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: space-between; gap: 22px; padding: 24px 28px 28px; }
.hp-case__main { display: flex; flex-direction: column; gap: 16px; }
.hp-case__brand { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.hp-case__logo { height: 48px; display: flex; align-items: center; }
.hp .hp-case__logo img { display: block; max-width: 100%; }
.hp .hp-case--kuznia-polska .hp-case__logo img { width: auto; height: 46px; }
.hp .hp-case--lakotech .hp-case__logo img { width: 150px; height: auto; }
.hp .hp-case--humavit .hp-case__logo img { width: auto; height: 44px; }
.hp .hp-case--mostostal-zabrze .hp-case__logo img { width: 150px; height: auto; }
.hp .hp-case--turlo .hp-case__logo img { width: auto; height: 40px; }
.hp-case__who { display: flex; align-items: center; gap: 8px; font-family: var(--rsm-f-mono); font-size: 12.5px; line-height: 1.4; color: var(--rsm-muted); }
.hp-case__who::before { content: ""; width: 10px; height: 10px; border-radius: 2px; background: var(--hp-accent); flex: none; }
.hp .hp-case__title { font-family: var(--rsm-f-display); font-weight: 700; font-size: clamp(21px, 1.75vw, 25px); line-height: 1.2; letter-spacing: -0.015em; color: var(--rsm-ink); text-wrap: balance; }
.hp-case__text { font-size: 16px; line-height: 1.6; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp-case__meta { align-self: flex-start; padding: 5px 10px; border: 1px solid var(--hp-line); border-radius: 6px; background: var(--hp-chip); font-family: var(--rsm-f-mono); font-size: 12px; line-height: 1.4; color: var(--rsm-ink-2); }
.hp-case__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 20px; padding-top: 18px; border-top: 1px solid var(--hp-line-soft); }
.hp-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.hp-chips li { padding: 7px 10px; border: 1px solid var(--hp-line); border-radius: 999px; background: var(--hp-chip); font-family: var(--rsm-f-mono); font-size: 12px; line-height: 1; color: var(--rsm-ink-2); }
.hp .hp-case__cta { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; line-height: 1.3; text-decoration: none; }
/* The whole card opens the case study. */
.hp .hp-case__cta::after { content: ""; position: absolute; inset: 0; z-index: 3; }
.hp .hp-case__cta svg { transition: transform .15s ease; }
.hp-case:hover .hp-case__cta { color: var(--rsm-blue-hover); }
.hp-case:hover .hp-case__cta svg { transform: translateX(3px); }

/* Keyboard focus: the ring goes around the whole card (only where :has() exists). */
@supports selector(:has(*)) {
  .hp-case:has(.hp-case__cta:focus-visible),
  .hp-post:has(.hp-post__title a:focus-visible) { outline: 3px solid var(--rsm-blue); outline-offset: 3px; }
  .hp .hp-case__cta:focus-visible,
  .hp .hp-post__title a:focus-visible { outline: none; }
}

/* Small cards (homepage second row) */
.hp-case--sm .hp-case__media { gap: 10px; padding: 18px 18px 12px; }
.hp .hp-case--sm .hp-case__frame { max-width: 345px; border-radius: 9px; }
.hp-case--sm .rsm-frame__bar { height: 24px; gap: 10px; padding: 0 10px; }
.hp-case--sm .rsm-frame__dots { gap: 5px; }
.hp-case--sm .rsm-frame__dots span { width: 6px; height: 6px; }
.hp-case--sm .rsm-frame__title { font-size: 10.5px; }
.hp-case--sm .hp-case__caption { font-size: 11px; }
.hp-case--sm .hp-case__body { gap: 20px; padding: 22px 24px 24px; }
.hp-case--sm .hp-case__main { gap: 14px; }
.hp-case--sm .hp-case__brand { gap: 8px 14px; }
.hp-case--sm .hp-case__logo { height: 44px; }
.hp-case--sm .hp-case__who { font-size: 12px; }
.hp .hp-case--sm .hp-case__title { font-size: clamp(19px, 1.45vw, 21px); line-height: 1.25; letter-spacing: -0.012em; }
.hp-case--sm .hp-case__foot { gap: 12px 16px; padding-top: 16px; }

/* CTA strip under the cards */
.hp-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px; padding: 24px 28px; background: #FFFFFF; border: 1px solid var(--hp-line); border-radius: var(--hp-radius); }
.hp-cta__text { flex: 1 1 420px; min-width: 0; font-family: var(--rsm-f-display); font-weight: 600; font-size: clamp(18px, 1.5vw, 21px); line-height: 1.3; letter-spacing: -0.01em; color: var(--rsm-ink); text-wrap: pretty; }

/* ---- What I build ------------------------------------------------------------------ */
.hp-services { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--hp-line); border: 1px solid var(--hp-line); border-radius: var(--hp-radius); overflow: hidden; }
.hp-service { display: flex; flex-direction: column; justify-content: space-between; gap: 20px; min-width: 0; padding: clamp(24px, 3vw, 36px); background: #FFFFFF; }
.hp-service__main { display: flex; flex-direction: column; gap: 14px; }
.hp-service__icon { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; border-radius: 10px; background: #EAF2FE; color: var(--rsm-blue-text); }
.hp-service__titles { display: flex; flex-direction: column; gap: 4px; }
.hp .hp-service__title { font-family: var(--rsm-f-display); font-weight: 700; font-size: clamp(21px, 1.7vw, 24px); line-height: 1.2; letter-spacing: -0.015em; color: var(--rsm-ink); }
.hp-service__sub { font-size: 16px; line-height: 1.5; font-weight: 600; color: var(--rsm-muted); }
.hp-service__text { font-size: 16px; line-height: 1.65; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp-service__refs { display: flex; flex-wrap: wrap; align-items: center; gap: 0 14px; padding-top: 14px; border-top: 1px solid var(--hp-line-soft); font-size: 15px; line-height: 1.4; }
.hp-service__refs span { font-family: var(--rsm-f-mono); font-size: 12px; color: var(--rsm-muted); }
.hp .hp-service__refs a { display: inline-block; padding-block: 11px; margin-block: -11px; font-weight: 600; text-decoration: none; }
.hp .hp-service__refs a:hover { text-decoration: underline; }

.hp-integr { display: flex; flex-direction: column; gap: 12px; }
.hp-integr__row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.hp-integr__label { min-width: min(244px, 100%); display: flex; align-items: center; gap: 8px; font-family: var(--rsm-f-mono); font-size: 13px; font-weight: 500; line-height: 1.4; color: var(--rsm-muted); }
.hp-integr__label svg { flex: none; color: var(--rsm-blue-text); }
.hp-integr__label--indent { padding-left: 26px; }
.hp-pills { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.hp-pills li { padding: 8px 12px; border: 1px solid var(--hp-line); border-radius: 999px; background: var(--hp-chip); font-size: 14px; font-weight: 500; line-height: 1.1; color: var(--rsm-ink); }

/* ---- How I work (dark band) -------------------------------------------------------- */
.hp-sec--dark .hp-kicker { color: var(--hp-on-dark); }
.hp-sec--dark .hp-kicker__n { color: var(--hp-on-dark-blue); }
.hp .hp-sec--dark .rsm-h2 { color: #FFFFFF; }
.hp-sec--dark .hp-head__intro { color: var(--hp-on-dark); }
.hp-steps { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px 28px; }
.hp-step { display: flex; flex-direction: column; justify-content: space-between; gap: 20px; min-width: 0; }
.hp-step__main { display: flex; flex-direction: column; gap: 14px; }
.hp-step__n { display: flex; align-items: center; gap: 12px; font-family: var(--rsm-f-mono); font-size: 14px; font-weight: 500; line-height: 1; color: var(--hp-on-dark-blue); }
.hp-step__n::after { content: ""; flex: 1 1 auto; height: 1px; background: #30353D; }
.hp .hp-step__title { font-family: var(--rsm-f-display); font-weight: 700; font-size: 22px; line-height: 1.25; letter-spacing: -0.012em; color: #FFFFFF; text-wrap: balance; }
.hp-step__text { font-size: 16px; line-height: 1.6; color: var(--hp-on-dark); text-wrap: pretty; }
.hp-step__chip { align-self: flex-start; max-width: 100%; padding: 7px 11px; border: 1px solid #3A3F48; border-radius: 6px; font-family: var(--rsm-f-mono); font-size: 13px; line-height: 1.4; color: #FFFFFF; }
.hp-steps__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 32px; padding-top: 28px; border-top: 1px solid #2A2E35; }
.hp-steps__note { flex: 1 1 360px; min-width: 0; font-size: 14.5px; line-height: 1.55; color: var(--hp-on-dark); }

/* ---- About -------------------------------------------------------------------------- */
.hp-about { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 40px 72px; }
.hp-about__fig { flex: 0 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.hp .hp-about__photo { display: block; width: 100%; height: auto; aspect-ratio: 7 / 8; object-fit: cover; object-position: 50% 30%; border: 1px solid var(--hp-line); border-radius: var(--hp-radius); background: #E9E7E2; }
.hp-about__text { flex: 1 1 520px; min-width: 0; max-width: 720px; display: flex; flex-direction: column; gap: 22px; }
.hp-about__copy { display: flex; flex-direction: column; gap: 14px; }
.hp-about__copy p { font-size: 17px; line-height: 1.65; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp-facts { display: grid; grid-template-columns: minmax(120px, max-content) minmax(0, 1fr); border-top: 1px solid var(--hp-line); }
.hp-facts dt { padding: 11px 24px 11px 0; border-bottom: 1px solid var(--hp-line); font-family: var(--rsm-f-mono); font-size: 12.5px; line-height: 1.7; color: var(--rsm-muted); }
.hp-facts dd { padding: 11px 0; border-bottom: 1px solid var(--hp-line); font-size: 15.5px; line-height: 1.55; color: var(--rsm-ink); }
.hp-about__links { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }

/* ---- Blog ---------------------------------------------------------------------------- */
.hp-posts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.hp-post { position: relative; display: flex; flex-direction: column; min-width: 0; background: var(--rsm-bg); border: 1px solid var(--hp-line); border-radius: var(--hp-radius); overflow: hidden; transition: border-color .15s ease, box-shadow .15s ease; }
.hp-post:hover { border-color: var(--rsm-line-strong); box-shadow: 0 18px 40px -30px rgba(16, 18, 21, 0.5); }
.hp-post__img { aspect-ratio: 16 / 9; overflow: hidden; background: #E9E7E2; border-bottom: 1px solid var(--hp-line); }
.hp .hp-post__img img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.hp-post__body { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: space-between; gap: 18px; padding: 26px 26px 24px; }
.hp-post__main { display: flex; flex-direction: column; gap: 12px; }
.hp-post__meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-family: var(--rsm-f-mono); font-size: 12px; line-height: 1.4; color: var(--rsm-muted); }
.hp .hp-post__title { font-family: var(--rsm-f-display); font-weight: 700; font-size: 21px; line-height: 1.25; letter-spacing: -0.012em; text-wrap: balance; }
.hp .hp-post__title a { color: var(--rsm-ink); text-decoration: none; }
.hp .hp-post__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.hp-post:hover .hp-post__title a { color: var(--rsm-ink); text-decoration: underline; text-decoration-thickness: 1px; }
.hp-post__excerpt { font-size: 15.5px; line-height: 1.6; color: var(--rsm-muted); text-wrap: pretty; }
.hp-post__more { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; font-size: 15px; font-weight: 600; line-height: 1.3; color: var(--rsm-blue-text); }
.hp-post__more svg { transition: transform .15s ease; }
.hp-post:hover .hp-post__more svg { transform: translateX(3px); }

/* ---- FAQ (rsm_faq, all answers open) -------------------------------------------------- */
.hp .hp-faq { border-bottom: 1px solid var(--hp-line); }
.hp .hp-faq .rsm-faq__item { border-top: 1px solid var(--hp-line); }
.hp .hp-faq .rsm-faq__q { gap: 16px; padding: 26px 0 12px; }
.hp .hp-faq .rsm-faq__item:not([open]) .rsm-faq__q { padding-bottom: 26px; }
.hp .hp-faq .rsm-faq__title { font-family: var(--rsm-f-display); font-weight: 700; font-size: clamp(19px, 1.5vw, 21px); line-height: 1.3; letter-spacing: -0.01em; color: var(--rsm-ink); text-wrap: balance; }
.hp .hp-faq .rsm-faq__a { padding: 0 0 26px; font-size: 16.5px; line-height: 1.65; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp .hp-faq .rsm-faq__a strong { font-weight: 600; color: var(--rsm-ink); }
@supports selector(::details-content) {
  @media (min-width: 900px) {
    /* Question left, answer right — the approved two-column layout. */
    .hp .hp-faq .rsm-faq__item { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.7fr); column-gap: 56px; }
    .hp .hp-faq .rsm-faq__q,
    .hp .hp-faq .rsm-faq__item:not([open]) .rsm-faq__q { padding: 26px 0; }
    .hp .hp-faq .rsm-faq__a { padding: 26px 0; }
    .hp .hp-faq .rsm-faq__item[open] .rsm-faq__icon { display: none; }
    .hp .hp-faq .rsm-faq__title { max-width: 460px; }
  }
}

/* ---- Contact ---------------------------------------------------------------------------- */
.hp-contact { background: #FFFFFF; border-top: 1px solid var(--hp-line); padding-block: clamp(56px, 7vw, 96px); }
.hp-contact__inner { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 40px 64px; }
.hp-contact__text { flex: 1 1 380px; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.hp-contact__lead { max-width: 480px; font-size: 17px; line-height: 1.6; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp-contact__list { list-style: none; display: flex; flex-direction: column; border-top: 1px solid var(--hp-line); }
.hp-contact__list li { display: flex; align-items: flex-start; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--hp-line); }
.hp-contact__list svg { flex: none; color: var(--rsm-blue-text); }
.hp-contact__item { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.hp-contact__k { font-family: var(--rsm-f-mono); font-size: 12px; line-height: 1.4; color: var(--rsm-muted); }
.hp-contact__v { display: flex; flex-wrap: wrap; gap: 0 14px; font-size: 16px; line-height: 1.5; }
.hp-contact__v--plain { font-weight: 500; color: var(--rsm-ink); }
.hp .hp-contact__v a { display: inline-block; padding-block: 10px; margin-block: -10px; font-weight: 600; text-decoration: none; }
.hp .hp-contact__v .hp-contact__tel { color: var(--rsm-ink); white-space: nowrap; }
.hp .hp-contact__v a:hover { text-decoration: underline; }

/* 534px = the approved 460px form + its padding (the mockup sized it content-box). */
.hp-contact__card { flex: 1 1 534px; min-width: 0; padding: clamp(22px, 3vw, 36px); background: var(--rsm-bg); border: 1px solid var(--hp-line); border-radius: var(--hp-radius); }
.hp .hp-contact__card .rsm-form { max-width: none; gap: 20px; }
.hp .hp-contact__card .rsm-form__field { gap: 8px; }
.hp .hp-contact__card .rsm-form__label { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--rsm-ink); }
.hp .hp-contact__card .rsm-form__req { margin-left: 0; font-size: 11.5px; font-weight: 400; color: var(--rsm-muted); opacity: 1; }
.hp .hp-contact__card .rsm-form input[type="tel"],
.hp .hp-contact__card .rsm-form input[type="text"],
.hp .hp-contact__card .rsm-form textarea { border-color: #BDB8AE; }
.hp .hp-contact__card .rsm-form__captcha { max-width: none; }
.hp .hp-contact__card .rsm-form__captcha input { max-width: 120px; }
.hp .hp-contact__card .rsm-form__actions .rsm-btn { min-height: 54px; padding: 12px 24px; text-align: center; }
.hp .hp-contact__card .rsm-form__status:empty { display: none; }
.hp .hp-contact__card .rsm-form__note { font-size: 13.5px; line-height: 1.55; color: var(--rsm-muted); opacity: 1; }

/* ---- /realizacje/ index ------------------------------------------------------------------- */
.hp-index__head { padding-block: clamp(44px, 6vw, 88px) clamp(36px, 4.5vw, 56px); }
.hp-index__head-inner { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px 64px; }
.hp-index__head-main { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.hp .hp-index__title { font-size: clamp(48px, 6.2vw, 88px); font-weight: 800; line-height: 1; color: var(--rsm-ink); }
.hp-index__intro { flex: 1 1 420px; min-width: 0; max-width: 560px; display: flex; flex-direction: column; gap: 12px; }
.hp-index__intro p { font-size: clamp(17px, 1.3vw, 19px); line-height: 1.6; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp-index__intro p + p { font-size: 16px; color: var(--rsm-muted); }
.hp-index__list { padding-bottom: clamp(56px, 7vw, 96px); }
.hp-index__cards { list-style: none; display: flex; flex-direction: column; gap: 28px; }
.hp-index__cards > li { min-width: 0; }

.hp-case--row .hp-case__frame { max-width: 600px; }
.hp-case--row .hp-case__caption { max-width: 600px; }
@media (min-width: 1000px) {
  .hp-case--row { flex-direction: row; }
  .hp-case--row .hp-case__media { flex: 0 0 52%; justify-content: center; padding: 36px 36px 22px; border-bottom: 0; border-right: 1px solid var(--hp-tint-line); }
  .hp-case--row .hp-case__body { justify-content: center; gap: 28px; padding: 36px 40px; }
  .hp-case--row .hp-case__main { gap: 18px; }
  .hp .hp-case--row .hp-case__title { font-size: clamp(24px, 2.2vw, 30px); line-height: 1.15; letter-spacing: -0.02em; }
}

.hp-index__cta-sec { padding-bottom: clamp(56px, 7vw, 96px); }
.hp-index__cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px 64px; padding: clamp(28px, 4vw, 48px); background: #FFFFFF; border: 1px solid var(--hp-line); border-radius: var(--hp-radius); }
.hp-index__cta-text { flex: 1 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.hp .hp-index__cta-text .rsm-h2 { font-size: clamp(26px, 2.6vw, 38px); line-height: 1.1; }
.hp-index__cta-text p { max-width: 620px; font-size: 17px; line-height: 1.6; color: var(--rsm-ink-2); text-wrap: pretty; }
.hp-index__cta-actions { flex: 0 1 360px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.hp-index__cta-actions .hp-ctas { flex-direction: column; }
.hp .hp-index__cta-actions .rsm-btn { width: 100%; }

/* ---- Large tablets / small laptops ------------------------------------------------------------ */
@media (max-width: 1099px) {
  .hp-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 40px; }
}
@media (max-width: 999px) {
  .hp-cases__lg { grid-template-columns: minmax(0, 1fr); }
  .hp-cases__sm { grid-template-columns: minmax(0, 1fr); }
  /* Small cards turn into horizontal rows: window on the left, text on the right. */
  .hp-case--sm { flex-direction: row; }
  .hp-case--sm .hp-case__media { flex: 0 0 46%; justify-content: center; border-bottom: 0; border-right: 1px solid var(--hp-tint-line); }
  .hp-posts { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  /* Post cards turn into rows: the whole 16:9 image as an inset thumbnail level with the date, text on the right. */
  .hp-post { flex-direction: row; }
  .hp-post__img { flex: 0 0 34%; align-self: flex-start; margin: 26px 0 26px 26px; border: 1px solid var(--hp-line); border-radius: 10px; }
  .hp-integr { gap: 18px; }
  .hp-integr__row { flex-direction: column; align-items: flex-start; gap: 10px; }
  .hp-about { gap: 40px 48px; }
  .hp-about__fig { flex-basis: 240px; }
  .hp-about__text { flex-basis: 400px; }
}

/* ---- Tablets ----------------------------------------------------------------------------------- */
@media (max-width: 760px) {
  .hp-logos__list { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .hp-logos__list li { grid-column: span 2; }
  .hp-logos__list li:nth-child(4), .hp-logos__list li:nth-child(5) { grid-column: span 3; }
}
@media (max-width: 699px) {
  .hp-services { grid-template-columns: minmax(0, 1fr); }
}

/* ---- Phones ------------------------------------------------------------------------------------- */
@media (max-width: 599px) {
  .hp .rsm-btn { width: 100%; text-align: center; }
  .hp-ctas { flex-direction: column; }
  .hp-hero__inner { gap: 40px; }
  .hp-hero__text { gap: 22px; }
  .hp .hp-hero__title { font-size: clamp(34px, 9.6vw, 40px); }
  .hp-stats { grid-template-columns: minmax(0, 1fr); gap: 0; padding-top: 6px; }
  .hp-stats > div { flex-direction: row; align-items: baseline; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--hp-line-soft); }
  .hp-stats > div:last-child { border-bottom: 0; }
  .hp-stats dt { flex: 0 0 96px; font-size: 22px; }

  /* Two windows instead of three, both fully visible. */
  .hp-stage { aspect-ratio: auto; max-width: none; display: flex; flex-direction: column; }
  .hp-stage__shot { position: relative; inset: auto; }
  .hp-stage__shot--a { width: 90%; }
  .hp-stage__shot--b, .hp-hero__cap-b { display: none; }
  .hp-stage__shot--c { width: 68%; align-self: flex-end; margin-top: -24%; }

  .hp-logos__inner { gap: 14px; padding-block: 22px; }
  .hp-logos__list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .hp-logos__list li, .hp-logos__list li:nth-child(4) { grid-column: auto; }
  .hp-logos__list li:nth-child(5) { grid-column: 1 / -1; }
  .hp .hp-logos__tile { min-height: 96px; }

  .hp-case--sm { flex-direction: column; }
  .hp-case--sm .hp-case__media { flex: none; border-right: 0; border-bottom: 1px solid var(--hp-tint-line); }
  .hp-case__media { padding: 16px 16px 12px; }
  .hp-case__body, .hp-case--sm .hp-case__body { padding: 20px 20px 22px; }
  .hp-case__foot { flex-direction: column; align-items: flex-start; }
  .hp-cta { padding: 22px 20px; }

  .hp-steps { grid-template-columns: minmax(0, 1fr); gap: 36px; }

  .hp-about { gap: 28px; }
  .hp-about__fig { flex: 1 1 100%; flex-direction: row; align-items: center; gap: 16px; }
  .hp .hp-about__photo { width: 132px; flex: none; }
  .hp-about__text { flex-basis: 100%; }
  .hp-facts { grid-template-columns: minmax(0, 1fr); }
  .hp-facts dt { padding: 12px 0 0; border-bottom: 0; line-height: 1.5; }
  .hp-facts dd { padding: 2px 0 12px; }
  .hp-about__links .rsm-btn { width: auto; }

  .hp-post { flex-direction: column; }
  .hp-post__img { flex: none; align-self: stretch; margin: 0; border: 0; border-bottom: 1px solid var(--hp-line); border-radius: 0; }
  .hp-post__body { padding: 22px 20px 20px; }

  .hp .hp-faq .rsm-faq__q { padding-top: 22px; }
  .hp .hp-faq .rsm-faq__a { padding-bottom: 22px; font-size: 16px; }

  .hp-contact__card { padding: 22px 18px; }
  .hp .hp-contact__card .rsm-form__actions .rsm-btn { width: 100%; }

  .hp-index__head-main { gap: 18px; }
  .hp-index__cta { padding: 24px 16px; }
  .hp .hp-index__cta .rsm-btn { padding-inline: 14px; text-align: center; }
}
