/*
 * IP shared chrome: site header, search bar (+ the phone sheets), homepage hero and stats band.
 * Handoff "IP - Global Header, Search, Hero & Results Page (Responsive)", 2026-10-05, built from the approved
 * boards (canvas "IP Homepage Header + Search - Options": A5 desktop / tablet / mobile + menu + sheets).
 *
 * Replaces the old header (#header .menu-nav ..., outlined Nav Tabs, flag toggle, dark surface-inverse search band,
 * "Popularne" row on desktop, in-place phone expansion) that used to live in web.css. Tokens only - every value comes
 * from public/css/tokens.css (the 2026-10-05 block at its end holds the new ones). Loaded on every public page after
 * web.css (web.layouts.header).
 *
 * Breakpoints (CSS variables cannot be used in @media): desktop >= 1024px, tablet 700-1023px, phone < 700px.
 * The header navigation never wraps: below 1024px the links are in the Menu panel.
 */

/* ===== Header ===== */
.ipc-header {
  position: sticky;
  top: 0;
  z-index: 9999;
  background: var(--surface);
  font-family: var(--font-sans);
  color: var(--ink);
}
.ipc-header__row { position: relative; background: var(--header-dark-bg); }
.ipc-header__inner {
  box-sizing: border-box;
  max-width: var(--header-max);
  margin: 0 auto;
  padding: var(--space-3) var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}
.ipc-logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 44px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
/* The logo image is the site's own file, never redrawn. Since the logo swap (owner 2026-11-26) its HEIGHT is the rule and the width follows the picture: 59.31px, and 41.73px on phones - exactly what the old file's 226px / 159px widths gave (owner 2026-10-06: "too large" is why they are this size). */
.ipc-logo__img { display: block; width: auto; max-width: 100%; height: 59.325px; }
/* Owner 2026-11-26: no hover dimming of the logo (it was opacity .6 with a .3s fade). */
.ipc-header__right { display: flex; align-items: center; gap: 28px; }

/* PL | EN - text only, no flags, at every width */
.ipc-lang {
  flex: none;
  display: flex;
  box-sizing: border-box;
  padding: 3px;
  gap: 2px;
  background: transparent;
  border: 1px solid var(--header-dark-border);
  border-radius: var(--radius-pill);
}
.ipc-lang__seg {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  min-height: 38px;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--header-dark-ink);
  font-family: var(--font-sans);
  font-weight: var(--body-weight, 400);   /* owner 2026-11-26: 400, was 700 */
  font-size: 15px;
  line-height: 1;
  text-decoration: none;
}
.ipc-lang__seg:hover { background: var(--header-dark-hover); color: var(--header-dark-ink); text-decoration: none; }
.ipc-lang__seg[aria-current="true"] { background: var(--surface); color: var(--brand-blue-dark); }
/* the small toggle at every width (owner 2026-10-06: it must be no bigger on tablet and phone than on desktop) */
.ipc-lang { padding: 2px; }
.ipc-lang__seg { min-width: 40px; min-height: 30px; font-size: 14px; }

/* Navigation: plain text links, no boxes */
.ipc-nav { display: flex; align-items: center; gap: 28px; }
.ipc-nav__link {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  color: var(--header-dark-ink);
  font-family: var(--font-sans);
  font-weight: var(--body-weight, 400);   /* owner 2026-11-26: 400, was 700 - the links, the Promocja Biznesu pill and the menu panel's rows */
  font-size: 16px;
  line-height: 1.3;
  text-decoration: none;
}
/* hover (and keyboard focus, and the current page) = a colour change only, no underline (owner 2026-10-07): the white
   links turn the light accent blue, and the accent-blue "+ Dodaj wpis" link turns white */
.ipc-nav__link:hover,
.ipc-nav__link:focus-visible,
.ipc-nav__link[aria-current="page"] {
  color: var(--header-dark-link-accent);
  text-decoration: none;
}
.ipc-nav__link--add { color: var(--header-dark-link-accent); }
.ipc-nav__link--add:hover,
.ipc-nav__link--add:focus-visible,
.ipc-nav__link--add[aria-current="page"] { color: var(--header-dark-ink); text-decoration: none; }
.ipc-nav__link i { font-size: 18px; line-height: 1; }

/* The add-listing link is the primary PILL button (owner 2026-11-25): the toggle's own pill shape, the Primary button fill and white bold text, at every width. From 1024px it
   sits in the header row as high as the language toggle (2px padding + 30px + 2px + the 1px borders = 36px, 14px text); below 1024px it is the last row of the Menu panel
   (below, in the max-width: 1023px block). */
.ipc-nav .ipc-nav__link--add {
  box-sizing: border-box;
  justify-content: center;
  padding: 0 var(--space-5);
  background: var(--button-primary-fill);
  border-radius: var(--radius-pill);
  color: var(--surface);
}
.ipc-nav .ipc-nav__link--add:hover,
.ipc-nav .ipc-nav__link--add:focus-visible,
.ipc-nav .ipc-nav__link--add[aria-current="page"] {
  background: var(--button-primary-hover);
  color: var(--surface);
}
@media (min-width: 1024px) {
  .ipc-nav .ipc-nav__link--add {
    min-height: 36px;
    font-size: 14px;
  }
}

/* Menu button: only below 1024px */
.ipc-menu-btn {
  display: none;
  flex: none;
  box-sizing: border-box;
  width: 40px;
  height: 40px;
  padding: 0;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--header-dark-border);
  border-radius: var(--radius-pill);
  color: var(--header-dark-ink);
  font-size: 22px;
  cursor: pointer;
}
.ipc-menu-btn:hover { background: var(--header-dark-hover); }
.ipc-menu-btn[aria-expanded="true"] { background: var(--header-dark-active); }
.ipc-menu-btn i { line-height: 1; }
.ipc-menu-btn__close { display: none; }
.ipc-menu-btn[aria-expanded="true"] .ipc-menu-btn__open { display: none; }
.ipc-menu-btn[aria-expanded="true"] .ipc-menu-btn__close { display: inline-block; }

.ipc-menu-btn:focus-visible,
.ipc-lang__seg:focus-visible,
.ipc-logo:focus-visible,
.ipc-nav__link:focus-visible {
  outline: 2px solid var(--header-dark-focus);
  outline-offset: 2px;
}

@media (max-width: 1023px) {
  .ipc-header__right { gap: 12px; }
  /* the toggle follows the links in the markup (it is last on the desktop header); here it stays before the Menu button, as it always was */
  .ipc-lang { order: -1; }
  .ipc-menu-btn { display: flex; }
  /* The four links become a panel under the header row, full width. The nav is positioned against .ipc-header__row
     (nothing between them is positioned). */
  .ipc-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 6;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--header-dark-bg);
    border-bottom: 1px solid var(--header-dark-separator);
    box-shadow: var(--header-dark-shadow);
  }
  .ipc-nav.is-open { display: flex; }
  .ipc-nav__link {
    min-height: 56px;
    padding: 0 var(--space-6);
    font-size: 18px;
    border-bottom: 1px solid var(--header-dark-separator);
  }
  .ipc-nav__link:last-child { border-bottom: 0; }
  /* the pill button is the panel's last row, with space around it (owner 2026-11-25) */
  .ipc-nav .ipc-nav__link--add { margin: var(--space-4); min-height: 48px; font-size: 16px; }
}
@media (max-width: 767px) {
  .ipc-logo__img { height: 41.7375px; }
}
@media (max-width: 699px) {
  .ipc-header__inner { padding: 10px var(--space-4); }
  .ipc-header__right { gap: var(--space-2); }
  .ipc-nav__link { min-height: 52px; padding: 0 var(--space-4); font-size: 17px; }
}

/* ===== Search bar: white pill (+ AI pill outside it) =====
   One markup (web/partials/search-bar.blade.php) in two homes: the white band under the header on inner pages
   (.ipc-band) and the hero on the homepage (.ipc-hero). Sizes: desktop 64px, tablet 56px, phone 48px. */
.ip-search-band { font-family: var(--font-sans); }
.ip-search-band__inner { box-sizing: border-box; max-width: var(--container-max); margin: 0 auto; }

/* Inner pages: white band, 1px divider on top (the line under the header), border + soft shadow under */
.ip-search-band.ipc-band {
  background: var(--surface-100); /* #f2f2f2 behind the white search bar (owner 2026-10-07); the homepage hero is untouched */
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--elevation-band);
  padding: calc(var(--space-4) + var(--space-2)) var(--space-6); /* +8px above and below (owner 2026-10-07) */
}

.ip-search-row { display: flex; align-items: center; gap: var(--space-5); }
.ip-search {
  --ipc-pill-shadow: var(--elevation-search-band);
  position: relative; /* containing block for #keyList and the location panel */
  flex: 1 1 0;
  min-width: 0;
  box-sizing: border-box;
  height: 64px;
  display: flex;
  align-items: center;
  padding: 5px 5px 5px var(--space-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  box-shadow: var(--ipc-pill-shadow);
}
.ipc-hero .ip-search { --ipc-pill-shadow: var(--elevation-search); }
/* Inner pages (owner 2026-10-07): no drop shadow behind the search bar or the AI button - the 1px border stays. The
   homepage hero keeps its shadow. A zero shadow, not `none`, so the focus ring below can still list it. */
.ipc-band .ip-search { --ipc-pill-shadow: 0 0 0 0 transparent; }
.ip-search:focus-within {
  box-shadow: 0 0 0 2px var(--focus-ring-inner), 0 0 0 4px var(--focus-ring), var(--ipc-pill-shadow);
}
.ip-search__card { display: contents; }
.ip-search__q-wrap { flex: 2 1 0; min-width: 0; height: 100%; display: flex; align-items: center; }
.ip-search__q {
  flex: 1 1 auto;
  min-width: 0;
  height: 100%;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font: 400 18px/24px var(--font-sans);
  color: var(--ink);
  -webkit-appearance: none;
  appearance: none;
  box-shadow: none;
}
.ip-search__q::placeholder { color: var(--ink-muted); opacity: 1; }
.ip-search__q::-webkit-search-cancel-button { -webkit-appearance: none; }
.ip-search__clear {
  flex: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border: 0;
  background: none;
  color: var(--ink-muted);
  font-size: 20px;
  line-height: 1;
  padding: 0;
  cursor: pointer;
}
/* jQuery .show() leaves display to the stylesheet; [hidden] must still win while the field is empty. */
.ip-search__clear:not([hidden]):not([style*="display: none"]) { display: inline-flex; }
.ip-search__clear[hidden] { display: none; }
.ip-search__clear:hover { color: var(--ink); }
.ip-search__divider { flex: none; width: 1px; height: 36px; margin: 0 14px; background: var(--border); }

.ip-search__loc { position: relative; flex: 1 1 0; min-width: 0; height: 100%; display: flex; align-items: center; }
.ip-search__loc-btn {
  flex: 1 1 auto;
  min-width: 0;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  background: transparent;
  font: 400 18px/24px var(--font-sans);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.ip-search__loc-btn i { flex: none; font-size: 22px; color: var(--ink-muted); }
.ip-search__loc-label {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink-muted);
}
.ip-ph-short { display: none; }
.location-picker-wrap.location-active .ip-search__loc-label { color: var(--ink); }
.ip-search__loc-clear {
  display: none;
  flex: none;
  margin-left: var(--space-1);
  border: 0;
  background: none;
  color: var(--ink-muted);
  font-size: 16px;
  line-height: 1;
  padding: 0 2px;
  cursor: pointer;
}
.ip-search__loc-clear:hover { color: var(--ink); }
.location-picker-wrap.location-active .ip-search__loc-clear { display: inline-flex; }

/* Szukaj: success green, inside the pill */
.ip-search__submit {
  flex: none;
  height: 52px;
  min-width: 152px;
  margin-left: var(--space-2);
  padding: 0 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--button-success-fill);
  color: var(--ink-inverse);
  font: 700 18px/1 var(--font-sans);
  cursor: pointer;
}
.ip-search__submit i { font-size: 22px; line-height: 1; }
.ip-search__submit:hover { background: var(--button-success-hover); }
.ip-search__submit:active { background: var(--button-success-active); }
.ip-search__loc-btn:focus-visible,
.ip-search__loc-clear:focus-visible,
.ip-search__clear:focus-visible,
.ip-search__submit:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

/* The Lokalizacja popup's header (title + close) only exists on phones */
.location-picker-head { display: none; }

/* AI button, outside the pill (desktop / tablet) and as the round pill button (phone) */
.ai-search-trigger--band {
  flex: none;
  height: 52px;
  min-width: 96px;
  padding: 0 var(--space-5);
  gap: 6px;
  border-radius: var(--radius-pill);
  background: var(--button-ai-fill);
  color: var(--brand-blue);
  font-size: 18px;
  line-height: 1;
  box-shadow: var(--ipc-pill-shadow, var(--elevation-search-band));
}
.ipc-hero .ai-search-trigger--band { box-shadow: var(--elevation-search); }
.ipc-band .ai-search-trigger--band { box-shadow: none; }
.ai-search-trigger--band:hover { background: var(--button-ai-hover); }
/* Inner pages (owner 2026-10-07): the AI button is a white hollow button like the search bar and the rest of the outline
   family - white fill, 1px border, the same light-blue hover; its blue text and icon stay. The homepage keeps the
   light-blue fill. */
.ipc-band .ai-search-trigger--band,
.ipc-band .ai-search-trigger--pill {
  background: var(--button-outline-fill);
  border: 1px solid var(--button-outline-border);
}
/* Hover and pressed follow the family (IP-Buttons-Color-Consistency.md, 2026-10-09): light-blue fill with the light-blue
   border on hover, the brand-blue border while pressed; the blue text and icon never change. */
.ipc-band .ai-search-trigger--band:hover,
.ipc-band .ai-search-trigger--pill:hover {
  background: var(--button-outline-hover);
  border-color: var(--button-outline-hover-border);
}
.ipc-band .ai-search-trigger--band:active,
.ipc-band .ai-search-trigger--pill:active {
  background: var(--button-outline-active);
  border-color: var(--button-outline-active-border);
}
.ai-search-trigger--band i { font-size: 24px; }
.ai-search-trigger__full { display: none; }
.ai-search-trigger__short { display: inline; }

/* ===== Location dropdown (desktop / tablet): under the location field ===== */
.location-picker-panel {
  display: none;
  position: absolute;
  top: calc(100% + var(--space-2));
  right: 0;
  min-width: 320px;
  z-index: 999;
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--elevation-2);
  overflow: hidden;
}
.location-picker-panel.open { display: block; }
.location-picker-search {
  width: 100% !important;
  height: 44px !important;
  padding: 0 var(--space-5) !important;
  border: 0 !important;
  border-bottom: 1px solid var(--border) !important;
  font: 15px/1.3 var(--font-sans) !important;
  color: var(--ink) !important;
}
.location-picker-search:focus { outline: none !important; box-shadow: inset 0 0 0 2px var(--focus-ring) !important; }
.location-picker-locate {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: 14px var(--space-5);
  border: 0;
  border-bottom: 1px solid var(--border);
  background: var(--surface-100);
  font: 14px/1.3 var(--font-sans);
  color: var(--ink);
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}
.location-picker-locate:hover { background: var(--button-secondary-hover); }
.location-picker-locate i { flex: none; color: var(--ink-muted); }
.location-picker-status {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  font-size: 12px;
  font-weight: normal;
  color: var(--ink-muted);
}
/* (The small grey wheel that spun here is gone - docs section CC: the status box holds the site's one loading look, four bars, coloured by
   public/css/ip-loading.css.) */
.location-picker-list { list-style: none; margin: 0; padding: 0; max-height: 280px; overflow-y: auto; }
.location-picker-list li {
  padding: 12px var(--space-5);
  font: 14px/1.3 var(--font-sans);
  color: var(--ink);
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.location-picker-list li:last-child { border-bottom: 0; }
.location-picker-list li:hover { background: var(--surface-100); }

/* ===== Tablet 700-1023 ===== */
@media (max-width: 1023px) {
  .ip-search-band.ipc-band { padding: calc(14px + var(--space-2)) var(--space-6); }
  .ip-search-row { gap: var(--space-4); }
  .ip-search { height: 56px; padding: 4px 4px 4px var(--space-5); }
  .ip-search__q-wrap { flex: 3 1 0; }
  .ip-search__loc { flex: 2 1 0; }
  .ip-search__q,
  .ip-search__loc-btn { font-size: 16px; }
  .ip-search__divider { height: 30px; margin: 0 12px; }
  .ip-search__loc-btn i { font-size: 20px; gap: var(--space-2); }
  .ip-search__loc-btn { gap: var(--space-2); }
  .ip-search__submit { height: 46px; min-width: 116px; padding: 0 var(--space-5); font-size: 16px; }
  .ip-search__submit i { font-size: 20px; }
  .ai-search-trigger--band { height: 46px; min-width: 84px; padding: 0 var(--space-4); font-size: 16px; }
  .ai-search-trigger--band i { font-size: 22px; }
}

/* ===== Inner pages: MEDIUM search bar (owner, 2026-10-05: "the search bar on every page except the homepage should be
   smaller, medium size buttons") =====
   The homepage hero keeps the large bar (64 / 56px, 52 / 46px buttons). Everywhere else - the white band under the
   header: category, subcategory, search results, listing, Kontakt, plans, login ... - the bar is 54px and Szukaj / AI
   are 42px (the compact sizes the owner approved earlier), on desktop and tablet alike. Phones are unchanged (48px pill
   with 40px round buttons, the same on every page). */
@media (min-width: 700px) {
  .ip-search-band.ipc-band { padding: calc(var(--space-3) + var(--space-2)) var(--space-6); }
  .ipc-band .ip-search { height: 54px; padding: 6px 6px 6px var(--space-5); }
  .ipc-band .ip-search__q,
  .ipc-band .ip-search__loc-btn { font-size: 16px; }
  .ipc-band .ip-search__divider { height: 30px; margin: 0 12px; }
  .ipc-band .ip-search__loc-btn i { font-size: 20px; }
  .ipc-band .ip-search__loc-btn { gap: var(--space-2); }
  .ipc-band .ip-search__submit { height: 42px; min-width: 0; padding: 0 var(--space-5); font-size: 16px; }
  .ipc-band .ip-search__submit i { font-size: 20px; }
  .ipc-band .ai-search-trigger--band { height: 42px; min-width: 0; padding: 0 var(--space-4); font-size: 16px; }
  .ipc-band .ai-search-trigger--band i { font-size: 20px; }
  .ipc-band .ip-search__clear { width: 36px; height: 36px; font-size: 18px; }
}

/* ===== Phone < 700: the search bar is a 48px pill with three round buttons; location and AI open POPUPS =====
   Owner request 2026-10-12: the keyword field is a real field right in the pill - a tap puts the cursor in it and the
   keyboard comes up, nothing opens (the "Szukaj" sheet and its "Popularne" chips are gone). The pin button opens the
   Lokalizacja popup, the sparkle button the AI popup (ai-search.css), the green circle searches: it is the desktop
   "Szukaj" button with its label hidden. */
:root { --ip-sheet-gap: 16px; }
@media (max-width: 699px) {
  .ip-search-band.ipc-band { padding: calc(10px + var(--space-2)) var(--space-4) calc(12px + var(--space-2)); }
  .ai-search-trigger--band { display: none; }

  /* the pill: the same white bar as above 700px, at 48px */
  .ip-search { height: 48px; gap: var(--space-2); padding: 3px 3px 3px var(--space-5); }
  .ip-search__q-wrap { flex: 1 1 0; }
  .ip-search__q { font-size: 16px; text-overflow: ellipsis; } /* 16px: with less, iOS zooms the page when the field is tapped */
  .ip-search__clear { width: 36px; height: 36px; font-size: 18px; }
  .ip-search__divider { display: none; }

  /* three 40px round buttons: location (outlined), AI (light blue), search (green) */
  .ip-search__loc { flex: none; width: 40px; height: 40px; }
  .ip-search__loc-btn {
    box-sizing: border-box;
    width: 40px;
    justify-content: center;
    gap: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius-pill);
    background: var(--surface);
    color: var(--ink-muted);
  }
  .ip-search__loc-btn:hover { background: var(--button-secondary-fill); }
  .ip-search__loc-btn i { font-size: 20px; }
  .ip-search__loc-label,
  .location-picker-wrap.location-active .ip-search__loc-clear { display: none; }
  .ai-search-trigger--pill,
  .ip-search__submit {
    flex: none;
    width: 40px;
    height: 40px;
    min-width: 0;
    margin: 0;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    border-radius: var(--radius-pill);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
  }
  .ai-search-trigger--pill { background: var(--button-ai-fill); color: var(--brand-blue); border: 0; }
  .ai-search-trigger--pill:hover { background: var(--button-ai-hover); }
  .ip-search__submit i { font-size: 20px; }
  .ip-search__submit-label { display: none; }

  /* ---- Popups: inset 16px from every edge, radius 28, padding 24, the page dimmed with the scrim and not scrolling.
     This is the Lokalizacja sheet; the AI popup does the same in ai-search.css. ---- */
  body.ip-modal-open { overflow: hidden; }
  .ip-search-band.is-locating::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: var(--scrim);
  }
  .location-picker-head {
    display: none;
    align-items: flex-start;
    justify-content: space-between;
    gap: var(--space-3);
    margin-bottom: var(--space-4);
  }
  .location-picker-head__title {
    margin: 0;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 26px;
    line-height: 32px;
    color: var(--ink);
  }
  .location-picker-head__title:focus { outline: none; }
  /* (The Lokalizacja sheet's close X is the shared round icon button now - 32px, public/css/ip-outline.css section 7 - not a 44px square of its own: owner 2026-11-27, "the same size for all".) */
  .ip-search-band .simple-modal-overlay { z-index: 10100; }

  /* ---- Lokalizacja sheet: stretches to the bottom gap, only the list scrolls ---- */
  .location-picker-panel,
  .ip-search__loc.location-active .location-picker-panel {
    position: fixed;
    top: calc(var(--ip-sheet-gap) + env(safe-area-inset-top, 0px));
    left: var(--ip-sheet-gap);
    right: var(--ip-sheet-gap);
    bottom: var(--ip-sheet-gap);
    z-index: 10002;
    box-sizing: border-box;
    min-width: 0;
    padding: var(--space-5);
    background: var(--surface);
    border-radius: 28px;
    box-shadow: var(--elevation-sheet);
    overflow: hidden;
  }
  .location-picker-panel.open { display: flex; flex-direction: column; }
  .location-picker-panel.open .location-picker-head { display: flex; }
  .location-picker-search {
    flex: none;
    height: 44px !important;
    padding: 0 var(--space-4) !important;
    border: 1px solid var(--border) !important;
    border-radius: 14px !important;
    font-size: 16px !important;
  }
  .location-picker-locate {
    flex: none;
    width: 100%;
    height: 44px;
    margin-top: var(--space-3);
    padding: 0 var(--space-4);
    border: 0;
    border-radius: 14px;
    background: var(--button-secondary-fill);
    color: var(--brand-blue-dark);
    font: 700 17px/1.2 var(--font-sans);
  }
  .location-picker-locate i { color: var(--brand-blue-dark); }
  .location-picker-list { flex: 1 1 auto; min-height: 0; max-height: none; margin-top: var(--space-3); -webkit-overflow-scrolling: touch; }
  .location-picker-list li { min-height: 44px; display: flex; align-items: center; font-size: 18px; }
}

/* ===== Type-ahead under the keyword field (unchanged behaviour) ===== */
.keySug { z-index: 999; }

/* ===== Phone back arrow (owner handoff 2026-11-20, docs/IP-Reference.md section CM, registry L34) =====
   A round button to the LEFT of the search pill (at every width since 2026-11-26; first only on a phone): [arrow] [gap] [pill]. web/partials/search-bar.blade.php prints it (inner pages only - never the
   homepage's hero) and web/layouts/header.blade.php decides in the head, before the first paint, whether the visitor has taken a step inside the site by putting
   .ip-has-back on <html>. Hidden at every width without that class, so the pill keeps its full width there, as it always had. The look is the outline family's round button - white fill, 1px border, the site's hover / pressed / focus
   from .ip-outline (ip-outline.css) - so only its shape is set here. The pill needs no rule of its own: it is already `flex: 1 1 0; min-width: 0`, so it takes the
   room that is left (44px and the gap narrower) and its placeholder is cut with an ellipsis; the arrow (44px) is shorter than the pill (48px), so the row - and the
   sticky header - keep their height. */
.ip-search-row .ip-back { display: none; }
/* Owner 2026-11-26: "add back button all views, not only mobile" - the arrow shows at every width (it was below 700px only); the same rule decides when (a step inside the site). */
html.ip-has-back .ip-search-row { gap: 10px; } /* the handoff's 10px between the arrow and the pill - no token (the scale is 8 / 12) */
html.ip-has-back .ip-search-row .ip-back {
  display: inline-flex;
  flex: none;
  box-sizing: border-box;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: var(--radius-pill);
}
html.ip-has-back .ip-search-row .ip-back i { font-size: 22px; line-height: 1; }
/* Owner 2026-11-26: on a PHONE only, the back arrow slides the page out to the right before the back navigation (the script in web/layouts/header.blade.php puts
   .ip-sliding on <html>; it does nothing for reduced motion). The bars that are fixed to the screen inside the page are hidden while it slides - they would otherwise be
   positioned against the moving page. */
@media (max-width: 699px) {
  /* The page slides sideways past the screen's edge, so what is outside it is clipped - on the page's own wrapper, with `clip` (not a scroll container: the sticky header keeps working),
     and NOT with overflow on <html>: switching that on and off made Safari on the iPhone resize its viewport and the top of the screen jumped (owner 2026-11-26). */
  html.ip-sliding #main-wrapper, html.ip-sliding-in #main-wrapper { overflow-x: clip; }
  /* Owner 2026-11-26 (third round: "keep the top sticky bar untouched ... the screen slides out to the right and the next screen slides in from the left without fading in and out"):
     going back on a phone, the page slides right in .3s and the page that arrives slides in from the left, side by side, no fade anywhere. Where the browser can do this between two
     documents (cross-document view transitions - Chrome, Edge, Safari 18.2) both move together, and only for a back navigation (the head script skips every other kind). Elsewhere the
     page slides out, and the page that arrives slides in from the left. The header stays still in both. */
  html.ip-sliding #main-wrapper > :not(#header) {
    transform: translateX(100%);
    transition: transform .3s ease-in-out;
  }
  html.ip-sliding .footer-nav { visibility: hidden; }
  html.ip-sliding-in #main-wrapper > :not(#header) { animation: ip-page-slide-in .3s ease-in-out; }
}
@media (max-width: 699px) and (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
  ::view-transition-old(root) { animation: ip-vt-slide-out .3s ease-in-out both; mix-blend-mode: normal; }
  ::view-transition-new(root) { animation: ip-vt-slide-in .3s ease-in-out both; mix-blend-mode: normal; }
  /* The sticky header bar (logo, PL | EN, menu) stays out of the animation: it is its own layer, shown as the new page has it from the first frame - not slid, not faded (the old bar's
     picture is not shown at all). The search band under it is part of the page and moves with it: the home page has no band, so a band held still would leave a gap. */
  /* z-index 1000: a view-transition-name makes the bar a stacking context of its own, and its Menu panel (z-index 6) was then painted UNDER the search band that follows it in the header - the search
     pill showed over "Kontakt" with the menu open (owner 2026-11-29, photos). The whole bar - and the panel in it - stays above everything in the band, the suggestion lists (999) included. */
  .ipc-header__row { view-transition-name: ip-header; z-index: 1000; }
  ::view-transition-group(ip-header) { animation: none; }
  ::view-transition-old(ip-header) { display: none; }
  ::view-transition-new(ip-header) { animation: none; }
}
@keyframes ip-vt-slide-out { to { transform: translateX(100%); } }
@keyframes ip-vt-slide-in { from { transform: translateX(-100%); } }
@keyframes ip-page-slide-in {
  from { transform: translateX(-100%); }
  to { transform: translateX(0); }
}

/* ===== Homepage hero + stats band ===== */
.ipc-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  /* no divider above the hero: the dark header band already separates them (dark header handoff, 2026-10-06) */
  background-color: var(--surface-page);
  background-image: url('../images/hero/chicago-skyline.jpg');
  background-image: image-set(url('../images/hero/chicago-skyline.webp') type('image/webp'), url('../images/hero/chicago-skyline.jpg') type('image/jpeg'));
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center 52%;
  font-family: var(--font-sans);
  color: var(--ink);
}
/* Decorative overlay. The bottom MUST stay 0% so the photo shows its original colours. */
.ipc-hero__overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(to bottom, var(--hero-overlay-top) 0%, var(--hero-overlay-mid) 50%, var(--hero-overlay-bottom) 100%);
}
.ipc-hero__content {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 40px var(--space-6) 168px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.ipc-hero__title {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: var(--body-weight); /* 400 - owner 2026-11-25: the home page's main title from 600 to 400 (this one title; the other h1 / h2 weights are untouched) */
  font-size: 40px;
  line-height: 48px;
  color: var(--ink);
}
.ipc-hero__intro { margin: var(--space-2) 0 0; font-size: 20px; line-height: 28px; color: var(--ink); }
.ipc-hero .ip-search-band { width: 100%; margin-top: var(--space-5); text-align: left; }
.ipc-hero .ip-search-band__inner { max-width: none; }

.ipc-stats { position: relative; margin-top: auto; background: var(--stats-band-bg); border-top: 1px solid var(--border); }
.ipc-stats__inner {
  box-sizing: border-box;
  max-width: var(--container-max);
  min-height: 52px;
  margin: 0 auto;
  padding: 6px var(--space-6);
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 28px;
}
.ipc-stats__sep { flex: none; width: 1px; height: 20px; background: var(--stats-divider); }
.ipc-stats__item { display: flex; align-items: baseline; gap: var(--space-2); white-space: nowrap; color: var(--ink); text-decoration: none; }
.ipc-stats__figure { font-family: var(--font-heading); font-weight: 600; font-size: 18px; line-height: 24px; }
/* The count-up must not move anything: the invisible sizer holds the final number's width, the live value sits on top of it in the same cell. */
.ipc-stats__figure { display: inline-grid; font-variant-numeric: tabular-nums; }
.ipc-stats__figure > * { grid-area: 1 / 1; }
.ipc-stats__sizer { visibility: hidden; }
.ipc-stats__value { justify-self: end; }
.ipc-stats__label { font-size: 15px; line-height: 20px; }
.ipc-stats a:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }

@media (max-width: 1023px) {
  .ipc-hero { background-position: center 60%; }
  .ipc-hero__content { padding: 44px var(--space-6) 80px; }
  .ipc-hero__title { font-size: 36px; line-height: 44px; max-width: 620px; }
  .ipc-hero__intro { margin-top: 10px; font-size: 19px; }
  .ipc-hero .ip-search-band { margin-top: 28px; }
  .ipc-stats__inner { min-height: 48px; padding: 4px var(--space-6); gap: var(--space-5); }
  .ipc-stats__sep { height: 18px; }
  .ipc-stats__item { gap: 6px; }
  .ipc-stats__figure { font-size: 16px; line-height: 20px; }
  .ipc-stats__label { font-size: 14px; line-height: 18px; }
}
@media (max-width: 699px) {
  .ipc-hero__content { padding: 28px var(--space-4) 40px; }
  .ipc-hero__title { font-size: 27px; line-height: 34px; max-width: none; }
  .ipc-hero__intro { font-size: 16px; line-height: 24px; }
  .ipc-hero .ip-search-band { margin-top: var(--space-4); }
  .ipc-hero .ip-search-band { margin-top: 20px; }
  /* phone: the three figures, as three columns (the figure over its label), separated by the same hairlines (owner 2026-11-25: the Promocja Biznesu link is gone from the band
     and the three figures show on a phone too) */
  .ipc-stats__inner { min-height: 52px; padding: 4px var(--space-4); gap: var(--space-2); justify-content: space-around; }
  .ipc-stats__item { flex: 0 1 auto; min-width: 0; flex-direction: column; align-items: center; gap: 0; white-space: normal; text-align: center; }
}
/* Phones: the suggestions under the keyword field hang below the field, and the hero only has about 90px under the bar -
   let them reach out of the hero (sideways it stays clipped, as before; where `overflow: clip` does not exist yet - iOS
   before 16 - they stay cut at the hero's edge). */
@supports (overflow: clip) {
  @media (max-width: 699px) {
    .ipc-hero { overflow-x: clip; overflow-y: visible; }
  }
}

/* ===== "Not found" dialog on the homepage (partials/not-found-modal.blade.php; the shell is .login-modal-dialog) ===== */
.notfound-text { margin: var(--space-3) 0 var(--space-5); line-height: 24px; }
.notfound-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }
.notfound-actions .btn { flex: 1 1 auto; justify-content: center; text-align: center; }
