﻿/* ==========================================================================
   GAMIN2 — HEADER / NAV / SEARCH / MEGAMENU (jednotný zdroj hlavičky)
   Soubor: css/header.css  (handle 'gamin-header', enqueue @10000, dep audit-sticky-nav)

   Přejmenováno z css/audit-fixes.css 2026-09-09 — po konsolidaci obsahuje už jen
   header/nav/search/megamenu/sticky + header-offset `body` pravidla (ostatní audit
   fixy rozpuštěny do komponentních souborů). Historicky: audit dev3.gamin.cz vs Figma (v15).

   Struktura (PŘED reorgem (c) — base-first restrukturalizace je naplánovaná,
   viz .md/REORG-BASELINE-PLAN-2026-09-09.md):
   - přední půlka: fragmentovaný mobil/tablet media state-machine (@≤767.98 / @768-921.98)
   - zadní půlka: desktop base (header struktura ~DOM-ordered) + desktop media (@≥922, @1240..992)
   ========================================================================== */

/* ===========================================================================
   DESKTOP BASE (reorg (c) R2a 2026-09-09) — FÁZE 2 header struktura přesunuta SEM
   z konce souboru (base-first, vzor footer.css). Move-safe: konkurenti jsou jinde
   (Astra/hp/custom/responsive — pořadí vůči header.css se nemění) nebo v grid-shrink
   media, které zůstávají ZA tímto blokem, nebo !important. Ověřeno rule-0 + 6-stav baseline.
   =========================================================================== */
/* ===========================================================================
   FÁZE 2 — DESKTOP HEADER BASE (above-header bar + primary header bar + breadcrumbs
   + menu-link barvy). Přesunuto z custom.css (551–713), render-safe (většina je už
   přebita vyšší specificitou Astra/audit/ab-hero — ověřeno rule-0). Konsolidace
   #4 2026-09-07 (verbatim move; případný cleanup mrtvých pravidel později).
   =========================================================================== */
.ast-above-header-bar {
  background-color: var(--background-primary);
  border: none;
}

.ast-above-header-bar .ast-builder-grid-row {

}

.ast-primary-header-bar {
  /* Homepage: žádná oddělovací čára (přes hero). Vítězná hodnota z audit-fixes #čára
     (dřív none!important tam). Obě border pravidla !important, aby subpage (níže, vyšší
     specificita) vyhrál. Konsolidace #4/běžné-def 2026-09-07. */
  border-bottom: none !important;
  background-color: transparent;
}

.ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
  gap: 0;
  grid-template-columns: 192.5px auto 382.5px;
}

body:not(.home) .ast-primary-header-bar {
  border-bottom: 1px solid var(--border-primary-solid, #E2E2E5) !important;
}

.ast-above-header-bar .site-above-header-wrap {
  height: 30px;
  min-height: inherit;
}

.ast-above-header-bar .site-above-header-wrap ul {
  display: flex;
  gap: 32px;
  padding: 0;
  margin: 0;
}

.ast-above-header-bar .site-above-header-wrap ul li {
  padding-left: 24px;
  margin: 0;
  list-style: none;
  background-repeat: no-repeat;
  background-position: 0 50%;
}

.ast-above-header-bar .site-above-header-wrap ul li a {
  font-weight: 600;
  font-style: SemiBold;
  font-size: .75rem;
  line-height: 100%;

  color: var(--text-negative-secondary, #D2D2D6);
}

.site-primary-header-wrap .site-primary-header-wrap {
  grid-column-gap: 0;
  gap: 0;
}

.main-header-bar {
  background-color: transparent;
  border: none;
}

.ast-header-break-point .main-header-bar.ast-header-breadcrumb {
  border: 0;
}

.ast-breadcrumbs {
  height: 54px;
  display: flex;
  align-items: center;
}

.ast-breadcrumbs .trail-items {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  white-space: nowrap;
  -webkit-overflow-scrolling: touch;
  
  /* Kosmetické úpravy */
  padding-right: 20px;
  scrollbar-width: none;
}

/* Skrytí posuvníku pro Chrome, Safari a Opera (aby design zůstal čistý) */
.ast-breadcrumbs .trail-items::-webkit-scrollbar {
  display: none;
}

.ast-breadcrumbs .trail-item {
  flex-shrink: 0;
  font-weight: 500;
  font-size: 14px;
  line-height: 160%;
  letter-spacing: 0%;
}

.ast-breadcrumbs .trail-item.trail-begin span {
  width: 20px;
  height: 20px;
  display: inline-block;
  text-indent: -9999em;
  background-image: url("data:image/svg+xml,%3csvg width='20' height='20' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M1.66699 6.66624L9.77672 2.61138C9.91748 2.541 10.0832 2.541 10.2239 2.61138L18.3337 6.66625M16.667 9.16624V15.8329C16.667 16.7534 15.9208 17.4996 15.0003 17.4996H5.00033C4.07985 17.4996 3.33366 16.7534 3.33366 15.8329V9.16624' stroke='%2352525B' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
}

.ast-breadcrumbs .trail-items li {
  font-weight: 450;
  font-style: Regular;
  font-size: 0.75rem;
  line-height: 160%;
  margin: 0 4px 0 0;
}

.ast-breadcrumbs .trail-items li::after {
  width: 20px;
  height: 20px;
  margin: 0 0 0 4px;
  display: inline-block;
  text-indent: -9999em;
  background-image: url("data:image/svg+xml,%3csvg width='20' height='20' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M8.33366 6.66699L11.667 10.0003L8.33366 13.3337' stroke='%23A1A1AA' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
}

.ast-breadcrumbs .trail-items li.trail-item.trail-end::after {
  content: '';
  display: none;
}

.ast-breadcrumbs .trail-items li a {
  font-weight: 450;
  font-style: Regular;
  font-size: 0.75rem;
  line-height: 160%;
  letter-spacing: 0%;
  color: var(--text-positive-secondary, #52525B);
}

.site-header {
  /*max-height: 96px;*/
}

.site-header-section {
  /*justify-content: flex-start;*/
}

.site-header-section.site-header-section-left,
.site-header-section.site-header-primary-section-left-center {
  justify-content: flex-start;
}

.site-header-section.site-header-primary-section-right-center  {
  justify-content: flex-end;
}

.main-header-menu > .menu-item > .menu-link {
  font-size: 0.875rem;
  color: var(--text-positive-primary, #022930);
}

body.home .main-header-menu > .menu-item > .menu-link {
  color: var(--text-white, #ffffff);
}

/* ===========================================================================
   C3 — Přepínač jazyka (desktop base) — přesun z konce souboru (reorg R2b 2026-09-09).
   Order-independent (unikátní selektory, bez konkurenta). =========================== */
/* ===========================================================================
   C3 — Přepínač jazyka v patičce ukazoval „Česky", horní lišta „CZ"
   ---------------------------------------------------------------------------
   Horní lišta používá WPML widget (řeší responsive.css), patička používá
   Astra builder switcher. Sjednoceno na dvoupísmenný kód podle Figmy.
   Jazyk se pozná z odkazu, aby to fungovalo i na slovenské mutaci.
   ========================================================================== */
.ast-builder-language-switcher .ast-builder-language-switcher-native-name {
    display: inline-block;
    font-size: 0 !important;
}

.ast-builder-language-switcher .ast-builder-language-switcher-native-name::before {
    display: inline-block;
    content: 'CZ';
    font-size: .75rem;
    font-weight: 600;
    letter-spacing: 0;
    line-height: 100%;
}

.ast-builder-language-switcher a[href*='/sk/'] .ast-builder-language-switcher-native-name::before {
    content: 'SK';
}

/* ===========================================================================
   SEARCH (desktop base) — přesun z konce souboru (reorg #6 2026-09-09). Order-independent:
   h3 řeší specificita+media (865 tablet 0,3,1 > base 0,2,1), chipy unikátní, B4/shadow !imp.
   =========================================================================== */
/* ===========================================================================
   B4 — Vyhledávací panel překrýval spodní hranu hlavičky (a tím i logo)
   ---------------------------------------------------------------------------
   Panel je position:fixed a žádný předek mu netvoří containing block, takže
   `top` se počítá od viewportu. Vazbu na reálnou výšku hlavičky drží
   --gamin-header-bottom, kterou nastavuje js/search.js na všech
   breakpointech (na rozdíl od --gamin-header-height, jež je jen pro desktop).
   ========================================================================== */
.gamin-search-results {
    top: calc(var(--gamin-header-bottom, 100px) + 8px) !important;

    /* Panel měl navíc margin-top: 52px, který ho posouval zpět pod hlavičku
       (naměřeno y=91 při hlavičce 100 px). S vazbou na `top` je nadbytečný. */
    margin-top: 0 !important;

    /* Figma 1320:14224 — Radius-L a Shadow/Elevation-1 (viz C5). */
    border-radius: var(--radius-l, 24px) !important;
}

/* ===========================================================================
   Vyhledávání (desktop) — panel pod inputem, špička uprostřed, ztmavené pozadí
   ---------------------------------------------------------------------------
   Figma 1317:10374. Přesnou pozici a šířku panelu (= šířka inputu) i přesun
   pod <body> řeší js/search.js (updateSearchPanel). Tady jen:
     1) ztmavené pozadí pod hlavičkou (body dostane .gamin-search-open),
     2) špička (trojúhelník) nahoře uprostřed panelu.
   Jen desktop — na ≤921px má vyhledávání vlastní statické rozvržení.
   ========================================================================== */
@media (min-width: 922px) {
    body.gamin-search-open::after {
        content: '';
        position: fixed;
        top: var(--gamin-header-bottom, 100px);
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(2, 41, 48, 0.50);
        z-index: 998;
        pointer-events: none;
    }

    /* Špička (trojúhelník) míří z panelu na input. NENÍ na panelu: ten má
       overflow:auto (scroll dlouhých výsledků), takže by špičku nad svou horní
       hranou oříznul (proto se předtím vůbec nezobrazovala). Kreslíme ji jako
       body::before nad panelem (z-index 1001). Souřadnice X (střed inputu) a Y
       (10px nad horní hranou panelu) nastavuje js/search.js. */
    .gamin-search-results::before {
        display: none !important;
    }

    body.gamin-search-open::before {
        content: '';
        position: fixed;
        left: var(--gamin-search-tri-x, 50%);
        top: var(--gamin-search-tri-y, 108px);
        width: 0;
        height: 0;
        border-left: 10px solid transparent;
        border-right: 10px solid transparent;
        border-bottom: 10px solid #fff;
        transform: translateX(-50%);
        z-index: 1001;
        pointer-events: none;
    }

    /* Bez vodorovného posuvníku — panel má šířku inputu, 2sloupcový grid produktů
       se vejde; overflow-x:hidden je pojistka (overflow-y zůstává auto). */
    .gamin-search-results {
        overflow-x: hidden !important;
    }
}

/* ===========================================================================
   B7 — Vyhledávání: kategorie / služby / novinky jako chipy, ne jako řádky
   ---------------------------------------------------------------------------
   Figma rozlišuje dva typy položek:
     Chip/Input               32 px, šířka podle textu, láme se do řádků
                              → Kategorie, Servis…, Novinky a články
     Chip/Product & category  476,5 × 60, 2 sloupce, s náhledem produktu
                              → jen Produkty
   Dev vykresloval všechny sekce stejně (řádky 592×56/60), takže kategorie
   a novinky zabíraly mnohonásobek prostoru.

   Markup sekce nemá modifikátor, rozlišení proto dělá js/search.js:
   položky s .gamin-search-icon => .is-chips, s .gamin-search-image => .is-products.
   ========================================================================== */
.gamin-search-section.is-chips .gamin-search-list {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: var(--spacing-8, 8px) !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.gamin-search-section.is-chips .gamin-search-list > li {
    width: auto !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
}

.gamin-search-section.is-chips .gamin-search-list > li > a {
    display: inline-flex !important;
    align-items: center !important;
    gap: var(--spacing-8, 8px) !important;
    min-height: 32px !important;
    padding: 4px 12px !important;
    border-radius: var(--radius-xs, 8px) !important;
    background: var(--chips-categories-fill-grey, #EEEEEF) !important;
    color: var(--text-positive-primary, #022930) !important;
    font-size: 14px !important;
    font-weight: 450 !important;
    line-height: 1.6 !important;
}

.gamin-search-section.is-chips .gamin-search-list > li > a > .gamin-search-icon {
    flex: 0 0 auto !important;
    width: 16px !important;
    height: 16px !important;
    color: var(--text-positive-secondary, #52525B) !important;
}

.gamin-search-section.is-chips .gamin-search-list > li > a > .gamin-search-icon svg {
    width: 16px !important;
    height: 16px !important;
}

.gamin-search-section.is-chips .gamin-search-list > li > a > .gamin-search-title {
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

/* Produktová sekce zůstává dvousloupcová — jen sjednocení výšky a radiusu. */
.gamin-search-section.is-products .gamin-search-list > li > a {
    min-height: 60px !important;
    border-radius: var(--radius-s, 12px) !important;
}

/* Nadpisy sekcí: Figma P4 Regular 12/1.6, letter-spacing 2, Text/Positive/Secondary,
   plus vodorovná linka doprava. Dev měl 12/500 v #022930 a bez linky. */
.gamin-search-results .gamin-search-section > h3 {
    display: flex !important;
    align-items: center !important;
    gap: var(--spacing-16, 16px) !important;
    margin: 0 0 var(--spacing-16, 16px) !important;
    color: var(--text-positive-secondary, #52525B) !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    letter-spacing: 2px !important;
    line-height: 1.6 !important;
    text-transform: none !important;
}

.gamin-search-results .gamin-search-section > h3::after {
    flex: 1 1 auto !important;
    height: 1px !important;
    background: var(--border-primary-solid, #E2E2E5) !important;
    content: '' !important;
}

.gamin-search-results,
#ast-desktop-header .astra-full-megamenu-wrapper .wrapper,
#ast-desktop-header .megamenu-content .wrapper,
.astra-megamenu-wrapper .wrapper {
    box-shadow: var(--shadow-elevation-1) !important;
}

/* ==========================================================================
   11. MOBILE — SMALL (max-width: 767.98px)
   ========================================================================== */

@media (max-width: 767.98px) {

    /* #52 — Mobile: vyhledávací komponenta: search results top: 140px
       Figma: dropdown pod search barem | Dev: top 140px (překrývá obsah)
       Závažnost: Střední */
    .gamin-search-results {
        top: calc(100% + 8px);
        position: absolute;
    }

}

/* ===========================================================================
   12. TABLET — 768–921px
   ---------------------------------------------------------------------------
   Figma má pro tablet samostatné obrazovky o šířce 768px. Tento blok je
   záměrně až za mobilem: `max-width: 768px` totiž platí i přesně na 768px a
   bez tohoto přepisu by se zde omylem použil telefonní layout.
   ========================================================================== */

@media (min-width: 768px) and (max-width: 921.98px) {

    /* Na tabletu je viditelná jen mobilní hlavička (70px), nikoli desktopová
       lišta. --gamin-header-height by jinak zůstalo na 140px (desktop+mobile
       stacked) a body by mělo zbytečných 70px padding-top navíc. */
    body {
        --gamin-header-height: 0px;
        padding-top: 0 !important;
    }

/* ===========================================================================
   19. TABLET MENU — use the same full-screen mobile navigation (Figma 208:6378)
   ========================================================================== */

    body.ast-main-header-nav-open {
        overflow: hidden;
    }

    body.ast-main-header-nav-open #ast-mobile-header .ast-mobile-header-content {
        position: fixed !important;
        z-index: 100000 !important;
        top: 70px !important;
        right: 0 !important;
        bottom: 0 !important;
        left: 0 !important;
        display: block !important;
        width: 100vw !important;
        max-width: none !important;
        min-height: calc(100vh - 70px) !important;
        padding: 0 32px !important;
        overflow-y: auto;
        background: #f7f7f7 !important;
        box-sizing: border-box;
    }

    body.ast-main-header-nav-open #ast-mobile-header .ast-mobile-header-content .mobile-lang-switch {
        margin: 24px 0 16px;
    }

    body.ast-main-header-nav-open #primary-site-navigation-mobile,
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile {
        width: 100% !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile {
        display: flex !important;
        flex-direction: column;
        margin: 0 !important;
        border-top: 1px solid var(--border-primary-solid, #e2e2e5);
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li {
        position: relative;
        width: 100%;
        min-height: 64px;
        margin: 0 !important;
        border-bottom: 1px solid var(--border-primary-solid, #e2e2e5);
    }

    /* Figma order: products, service, training, about, contacts, news. */
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li:nth-child(5) {
        order: 4;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li:nth-child(4) {
        order: 5;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li.gamin-tablet-menu-news {
        order: 6;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li > a {
        display: flex !important;
        align-items: center;
        min-height: 64px;
        padding: 16px 40px 16px 0 !important;
        color: var(--text-positive-primary, #022930) !important;
        font-size: 16px;
        font-weight: 600;
        line-height: 24px;
    }

    /* C1 — jednotný chevron pro VŠECHNY položky (right:16px, opticky ~20px od
       kraje). Položky s podmenu měly chevron z Astra `link::after` (přes
       space-between, ~32px od kraje) — jiné zarovnání než ostatní. Proto teď
       dáváme border-chevron všem přes li::after a `link::after` u položek
       s podmenu níže skryjeme. (Původně mířeno jen na :not(.menu-item-has-children).) */
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li::after {
        position: absolute;
        top: 25px;
        right: 16px;
        width: 8px;
        height: 8px;
        border-right: 1.5px solid #022930;
        border-bottom: 1.5px solid #022930;
        content: '';
        pointer-events: none;
        transform: rotate(45deg);
    }

    /* Skryj původní (posunutý) chevron u položek s podmenu, ať nejsou dva. */
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li.menu-item-has-children > a::after {
        content: none !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li > .ast-menu-toggle {
        right: 0;
        width: 40px;
        height: 64px;
        color: var(--text-positive-primary, #022930);
    }
}

/* Otevřené mobilní/tablet menu: horní lišta (header wrap) má být šedá #F7F7F7
   jako obsah menu i stránka pod ní — ne bílá, aby nevyčnívala. navigation.css
   i custom.css ji dávají na `white`; přebíjíme tady (načítá se po nich). */
body.ast-main-header-nav-open .ast-main-header-wrap,
body.ast-main-header-nav-open .main-header-bar-wrap,
body.ast-main-header-nav-open .main-header-bar {
    background-color: #F7F7F7 !important;
}

/* Tablet .sluzby 6-col grid (stary design) SMAZANO — hp.css rozcestnik (2col flex @921) prebiji. 2026-09-08. */

/* ===========================================================================
   13. TABLET HEADER / SEARCH — final cascade override
   ========================================================================== */
@media (min-width: 768px) and (max-width: 921.98px) {
    #ast-desktop-header {
        display: none !important;
    }

    /* ===================================================================
       TABLET SEARCH (#gamin-tablet-search) — KONSOLIDACE (jediné místo)
       search.js injektuje vyhledávání pod mobilní hlavičku. Dřív byl styl
       roztříštěný do několika @media bloků a postupně přepisovaný — teď je tu.
         (1) layout společný všem,
         (2) PODSTRÁNKY: světlý panel background-primary + pole
             background-secondary; vodorovné odsazení nese jediné pravidlo
             `#masthead .gamin-search-container` (padding 0 32px), panel proto nemá
             vlastní vodorovný padding → nikde bílá ani šedé odsazení po stranách,
         (3) HOMEPAGE: pole leží na hero — řeší blok „18" (body.home) níže +
             design B (hp.css).
       =================================================================== */

    /* (1) layout — společný */
    #gamin-tablet-search .gamin-search-container,
    #gamin-tablet-search .gamin-search-form,
    #gamin-tablet-search .gamin-search-input-container {
        position: relative !important;
        inset: auto !important;
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        height: auto !important;
        margin: 0 !important;
        opacity: 1 !important;
        overflow: visible !important;
    }

    #gamin-tablet-search .gamin-search-input-container {
        display: flex !important;
        align-items: center;
        min-height: 40px;
        padding: 0 !important;
        border: 0 !important;
        border-radius: var(--radius-xs, 8px);
    }

    #gamin-tablet-search input.gamin-search-input[type=search] {
        display: block !important;
        width: 100% !important;
        min-height: 40px !important;
        padding: 8px 12px 8px 40px !important;
    }

    /* V KLIDU skryté; v rozbaleném stavu je zobrazí overlay (tlačítko „Zrušit"
       + výsledky, dle Figmy). Scope `:not(.is-expanded)`, jinak by tento hide
       (vyšší specificita) přebil rozbalený stav a „Zrušit" by chybělo. */
    #gamin-tablet-search .gamin-search-container:not(.is-expanded) .gamin-search-cancel,
    #gamin-tablet-search .gamin-search-container:not(.is-expanded) .gamin-search-results {
        display: none !important;
    }

    /* (2) PODSTRÁNKY — světlý panel background-primary, pole background-secondary.
       Vodorovné odsazení pole řeší jediné pravidlo `#masthead .gamin-search-container`
       (padding 0 32px); panel proto nemá vlastní vodorovný padding (jinak by se
       odsazení sčítalo → dřívější 62px). */
    body:not(.home) #gamin-tablet-search {
        display: block;
        padding: 10px 0;
        background: var(--background-primary, #F7F7F7);
        border-bottom: 1px solid var(--border-primary-solid, #E2E2E5);
    }

    body:not(.home) #gamin-tablet-search .gamin-search-container {
        /* Odsazení pole řeší JEDINÉ pravidlo `#masthead .gamin-search-container`
           (padding 0 32px) v tomtéž tablet bloku níže — sem už žádné odsazení
           nepřidáváme (žádné přepisování). Tady jen barva panelu, ať pole nemá
           bílý box ani šedý pruh po stranách. */
        background: var(--background-primary, #F7F7F7) !important;
    }

    /* Šedý obal (background-secondary) je v KLIDU na celém poli. V ROZBALENÉM
       stavu nese šeď jen INPUT (řeší overlay), aby „Zrušit" bylo mimo obal na
       panelu → proto scope :not(.is-expanded). */
    body:not(.home) #gamin-tablet-search .gamin-search-container:not(.is-expanded) .gamin-search-input-container {
        background: var(--background-secondary, #EEEEEF) !important;
    }

    body:not(.home) #gamin-tablet-search .gamin-search-container:not(.is-expanded) input.gamin-search-input[type=search] {
        background-color: transparent !important;
    }

    body:not(.home) #gamin-tablet-search input.gamin-search-input[type=search] {
        color: var(--text-positive-primary, #022930) !important;
    }

    body:not(.home) #gamin-tablet-search .gamin-search-results {
        background: transparent !important;   /* leží na background-primary panelu */
    }

/* 17. .sluzby .wp-block-columns padding=0 SMAZANO — redundant (hp.css flex default 0). 2026-09-08. */

/* ===========================================================================
   18. TABLET HOMEPAGE HEADER — final Figma search override (7014:36666)
   Kept at EOF because the search node is injected by search.js after the
   mobile header and inherited Astra/mobile rules otherwise hide it.
   ========================================================================== */

    body.home #gamin-tablet-search {
        position: absolute !important;
        z-index: 20;
        top: 72px !important;
        right: 0;
        left: 0;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        /* Vodorovný gutter (32px) nese JEDINÝ zdroj `#masthead .gamin-search-container`
           (stejně jako podstránky). Zde proto BEZ vlastního 0 32px — dřív se odsazení
           sčítalo (32+32) → pole začínalo na 64px místo 32px. */
        padding: 0 !important;
        background: transparent !important;
        border: 0 !important;
    }

    body.home #gamin-tablet-search .gamin-search-container,
    body.home #gamin-tablet-search .gamin-search-form {
        display: block !important;
        width: 100% !important;
    }

    body.home #gamin-tablet-search .gamin-search-input-container {
        display: flex !important;
        min-height: 40px !important;
        padding: 0 !important;
        background: rgba(87, 126, 133, .78) !important;
        border: 0 !important;
        border-radius: 12px !important;
    }

    body.home #gamin-tablet-search input.gamin-search-input[type=search] {
        display: block !important;
        min-height: 40px !important;
        padding: 8px 16px 8px 44px !important;
        color: #fff !important;
        font-size: 16px !important;
        line-height: 24px !important;
    }

    body.home #gamin-tablet-search input.gamin-search-input[type=search]::placeholder {
        color: rgba(255, 255, 255, .76) !important;
    }
}

/* SS27 ABOUT PAGES tablet content raster -> css/content.css (konsolidace 2026-09-08) */

/* ===========================================================================
   29. MOBILE / TABLET NAV + SEARCH — Figma navigation/search states
   Figma nodes: 989:4337, 673:6430, 752:10494, 989:5382, 1318:12827
   ========================================================================== */

/* Mobile menu: same fullscreen white sheet behavior as tablet.
   The previous phone layout stopped after the last menu item, leaving the hero
   visible below the menu. */
@media (max-width: 767.98px) {
    body.ast-main-header-nav-open {
        overflow: hidden;
    }

    body.ast-main-header-nav-open #masthead,
    body.ast-main-header-nav-open #ast-mobile-header {
        position: fixed !important;
        z-index: 100001 !important;
        top: 0 !important;
        right: 0 !important;
        left: 0 !important;
        width: 100vw !important;
        background: #fff !important;
    }

    body.ast-main-header-nav-open #masthead {
        height: 70px !important;
    }

    body.ast-main-header-nav-open #ast-desktop-header,
    body.ast-main-header-nav-open #masthead #ast-desktop-header {
        display: none !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .ast-mobile-header-content {
        position: fixed !important;
        z-index: 100000 !important;
        top: 70px !important;
        right: 0 !important;
        bottom: 0 !important;
        left: 0 !important;
        display: block !important;
        width: 100vw !important;
        max-width: none !important;
        min-height: calc(100vh - 70px) !important;
        padding: 0 16px !important;
        overflow-y: auto;
        background: #f7f7f7 !important;
        box-sizing: border-box;
    }

    body.ast-main-header-nav-open #ast-mobile-header .ast-mobile-header-content .mobile-lang-switch {
        margin: 24px 0 16px;
    }

    body.ast-main-header-nav-open #primary-site-navigation-mobile,
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile {
        width: 100% !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile {
        display: flex !important;
        flex-direction: column;
        margin: 0 !important;
        border-top: 1px solid var(--border-primary-solid, #e2e2e5);
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li {
        position: relative;
        width: 100%;
        min-height: 64px;
        margin: 0 !important;
        border-bottom: 1px solid var(--border-primary-solid, #e2e2e5);
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li > a {
        display: flex !important;
        align-items: center;
        min-height: 64px;
        padding: 16px 40px 16px 0 !important;
        color: var(--text-positive-primary, #022930) !important;
        font-size: 16px;
        font-weight: 600;
        line-height: 24px;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li > .ast-menu-toggle {
        right: 0;
        width: 40px;
        height: 64px;
        color: var(--text-positive-primary, #022930);
    }
}

/* Search overlay for phone/tablet: the default desktop search is intentionally
   compact in the header. Once focused/expanded below 922px, Figma uses a
   standalone white search layer with input and cancel in the first row. */
@media (max-width: 921.98px) {
    /* Když je search aktivní, zrušíme na #masthead backdrop-filter (blur, který
       Astra dává sticky hlavičce po scrollu) i jeho transition. `backdrop-filter`
       s ne-none hodnotou vytváří containing block pro position:fixed potomky —
       fixed overlay searche by se pak počítal vůči hlavičce (výška ~112px) místo
       viewportu a výsledky by se ořízly. transition:none je nutné, aby se blur
       vypnul okamžitě, ne přes 0.4s (během přechodu by CB stále existoval). */
    body.gamin-search-active #masthead {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        transition: none !important;
        transform: none !important;
        filter: none !important;
        will-change: auto !important;
    }

    .gamin-search-container.is-expanded,
    .gamin-search-container.expanded {
        position: fixed !important;
        z-index: 100002 !important;
        /* Overlay začíná POD lištou s logem — --gamin-search-top nastaví JS
           (search.js) na skutečnou default pozici searche, takže input zůstane
           na svém místě a zavírací „Zrušit" už nekoliduje s hamburgerem v řádku
           s logem. getBoundingClientRect je viewport-relativní → sedí i s WP
           admin barem a sticky hlavičkou. Fallback 0 = původní chování. */
        top: var(--gamin-search-top, 0) !important;
        right: 0 !important;
        bottom: 0 !important;
        left: 0 !important;
        display: block !important;
        width: 100% !important;
        max-width: none !important;
        /* výšku určí top + bottom:0 (od offsetu dolů), ne 100dvh od vršku */
        height: auto !important;
        margin: 0 !important;
        padding: 0 16px 0 !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
        background: #fff !important;
        box-sizing: border-box !important;
        touch-action: pan-y !important;
    }

    .gamin-search-container.is-expanded .gamin-search-form,
    .gamin-search-container.expanded .gamin-search-form {
        display: block !important;
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .gamin-search-container.is-expanded .gamin-search-input-container,
    .gamin-search-container.expanded .gamin-search-input-container {
        position: relative !important;
        inset: auto !important;
        display: flex !important;
        align-items: center !important;
        gap: 16px !important;
        width: 100% !important;
        max-width: none !important;
        min-width: 0 !important;
        height: 44px !important;
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
        background: transparent !important;
        box-sizing: border-box !important;
        isolation: isolate !important;
    }

    .gamin-search-container.is-expanded input.gamin-search-input[type=search],
    .gamin-search-container.expanded input.gamin-search-input[type=search] {
        flex: 1 1 auto !important;
        width: auto !important;
        max-width: 100% !important;
        min-width: 0 !important;
        height: 44px !important;
        min-height: 44px !important;
        padding: 10px 12px 10px 40px !important;
        border: 1px solid var(--button-primary-primary-hover, #57FFF8) !important;
        border-radius: 8px !important;
        color: var(--text-positive-primary, #022930) !important;
        background-color: var(--background-secondary, #EEEEEF) !important;
        background-image: url(../img/ikona-lupa-modra.svg) !important;
        background-position: 12px 50% !important;
        background-repeat: no-repeat !important;
        background-size: 20px 20px !important;
        box-sizing: border-box !important;
        font-size: 14px !important;
        line-height: 24px !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
    }

    .gamin-search-container.is-expanded .gamin-search-cancel,
    .gamin-search-container.expanded .gamin-search-cancel {
        position: static !important;
        z-index: 3 !important;
        display: inline-flex !important;
        flex: 0 0 auto !important;
        align-items: center !important;
        justify-content: center !important;
        height: 44px !important;
        margin: 0 !important;
        padding: 0 !important;
        color: var(--text-positive-primary, #022930) !important;
        background: transparent !important;
        border: 0 !important;
        font-size: 14px !important;
        font-weight: 450 !important;
        line-height: 24px !important;
        pointer-events: auto !important;
        cursor: pointer !important;
    }

    .gamin-search-container.is-expanded .gamin-search-results,
    .gamin-search-container.expanded .gamin-search-results,
    #gamin-tablet-search .gamin-search-container.is-expanded .gamin-search-results,
    #gamin-tablet-search .gamin-search-container.expanded .gamin-search-results {
        position: static !important;
        display: block !important;
        width: 100% !important;
        max-width: none !important;
        max-height: none !important;
        margin: 32px 0 0 !important;
        padding: 0 !important;
        overflow-x: hidden !important;
        overflow-y: visible !important;
        background: transparent !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        box-sizing: border-box !important;
    }

    .gamin-search-container.is-expanded .gamin-search-results:before,
    .gamin-search-container.expanded .gamin-search-results:before {
        display: none !important;
    }

    .gamin-search-container.is-expanded .gamin-search-section,
    .gamin-search-container.expanded .gamin-search-section {
        margin-bottom: 32px !important;
    }

    .gamin-search-container.is-expanded .gamin-search-section h3,
    .gamin-search-container.expanded .gamin-search-section h3 {
        margin: 0 0 12px !important;
        color: var(--text-positive-secondary, #52525B) !important;
        font-size: 12px !important;
        font-weight: 450 !important;
        line-height: 16px !important;
        letter-spacing: 0 !important;
        text-transform: none !important;
    }

    .gamin-search-container.is-expanded .gamin-search-recommended,
    .gamin-search-container.expanded .gamin-search-recommended,
    .gamin-search-container.is-expanded .gamin-search-list,
    .gamin-search-container.expanded .gamin-search-list {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        list-style: none !important;
        overflow-x: hidden !important;
        box-sizing: border-box !important;
    }

    .gamin-search-container.is-expanded .gamin-search-recommended-item,
    .gamin-search-container.expanded .gamin-search-recommended-item,
    .gamin-search-container.is-expanded .gamin-search-list li,
    .gamin-search-container.expanded .gamin-search-list li {
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }

    .gamin-search-container.is-expanded .gamin-search-list li a,
    .gamin-search-container.expanded .gamin-search-list li a {
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        min-height: 32px !important;
        padding: 4px 12px !important;
        color: var(--text-positive-secondary, #52525B) !important;
        background: var(--chips-categories-fill-grey, #EEEEEF) !important;
        border-radius: 8px !important;
        text-decoration: none !important;
        box-sizing: border-box !important;
        font-size: 14px !important;
        line-height: 20px !important;
        overflow: hidden !important;
    }

    .gamin-search-container.is-expanded .gamin-search-image,
    .gamin-search-container.expanded .gamin-search-image {
        flex: 0 0 32px !important;
        width: 32px !important;
        height: 32px !important;
        overflow: hidden !important;
        border-radius: 6px !important;
        background: #fff !important;
    }

    .gamin-search-container.is-expanded .gamin-search-image img,
    .gamin-search-container.expanded .gamin-search-image img {
        width: 100% !important;
        height: 100% !important;
        object-fit: contain !important;
    }

    .gamin-search-container.is-expanded .gamin-search-title,
    .gamin-search-container.expanded .gamin-search-title {
        display: block !important;
        flex: 1 1 auto !important;
        min-width: 0 !important;
        max-width: 100% !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
    }

    .gamin-search-container.is-expanded .gamin-search-list *,
    .gamin-search-container.expanded .gamin-search-list * {
        min-width: 0 !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
}

/* ===========================================================================
   30. MOBILE HOMEPAGE — base pass against Figma 208:6000
   ---------------------------------------------------------------------------
   Phone homepage must not create a horizontal document canvas. Wide animated
   logo tracks and Owl carousel stages are intentionally wider than the viewport,
   but they have to be clipped by their component containers.
   ========================================================================== */

@media (max-width: 767.98px) {
    /* HP mobile header is a special transparent-on-hero composition:
       mobile logo/menu row (64px) + search row (48px) = Figma nav 112px. */
    body.home.ast-header-break-point {
        padding-top: 0 !important;
    }

    body.home #content,
    body.home .site-content {
        padding-top: 112px !important;
    }

    body.home #masthead {
        position: fixed !important;
        top: 0 !important;
        right: 0 !important;
        left: 0 !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        height: 112px !important;
        min-height: 112px !important;
        padding: 12px 0 !important;
        background: transparent !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
        box-shadow: none !important;
        box-sizing: border-box !important;
    }

    body.home #ast-mobile-header {
        height: 36px !important;
        min-height: 36px !important;
    }

    body.home #ast-mobile-header .ast-primary-header-bar {
        min-height: 36px !important;
        height: 36px !important;
        padding-right: 16px !important;
        padding-left: 16px !important;
        background: transparent !important;
    }

    body.home #ast-mobile-header .site-logo-img,
    body.home #ast-mobile-header .ast-site-identity {
        width: 120px !important;
        height: 24px !important;
        padding: 0 !important;
    }

    body.home #ast-mobile-header .ast-logo-title-inline .ast-site-identity a,
    body.home #ast-mobile-header .site-logo-img .custom-logo-link {
        width: 120px !important;
        height: 24px !important;
        background-size: 120px 24px !important;
    }

    body.home [data-section="section-header-mobile-trigger"] .ast-button-wrap .menu-toggle {
        min-height: 36px !important;
        padding: 4px 8px !important;
        border-radius: 12px !important;
    }

    body.home [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon {
        gap: 8px !important;
        font-size: 12px !important;
        font-weight: 500 !important;
        line-height: 1.6 !important;
        letter-spacing: 0.02em !important;
    }

    body.home [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon::before {
        margin-right: 0 !important;
    }

    body.home [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon .ast-mobile-svg {
        width: 28px !important;
        height: 28px !important;
    }

    /* Po odscrollování (sticky hlavička) byl hamburger překreslený jiným prvkem
       a „mizel" (prvek má pointer-events:none, takže hit-test ho neodhalil).
       Zvednutím do vlastního stacking kontextu zůstane navrchu. Jen se zavřeným
       menu — otevřený křížek (X) řeší pravidla ast-main-header-nav-open. */
    body:not(.ast-main-header-nav-open) #masthead .menu-toggle {
        position: relative !important;
        z-index: 5 !important;
    }

    body.home #ast-desktop-header {
        display: block !important;
        height: 40px !important;
        min-height: 40px !important;
        margin-top: -12px !important;
        background: transparent !important;
    }

    body.home #ast-desktop-header .ast-primary-header-bar,
    body.home #ast-desktop-header .site-primary-header-wrap,
    body.home #ast-desktop-header .ast-builder-grid-row {
        min-height: 40px !important;
        height: 40px !important;
        padding: 0 !important;
        background: transparent !important;
    }

    body.home #ast-desktop-header .ast-builder-grid-row-container,
    body.home #ast-desktop-header .ast-builder-grid-row {
        display: block !important;
        width: 100% !important;
        max-width: none !important;
    }

    body.home #ast-desktop-header .site-header-primary-section-left,
    body.home #ast-desktop-header .site-header-primary-section-center {
        display: none !important;
    }

    body.home #ast-desktop-header .site-header-primary-section-right {
        display: flex !important;
        flex: 0 0 calc(100% - 32px) !important;
        width: calc(100% - 32px) !important;
        max-width: calc(100% - 32px) !important;
        justify-content: center !important;
        margin-right: 16px !important;
        margin-left: 16px !important;
    }

    body.home #ast-desktop-header .header-widget-area,
    body.home #ast-desktop-header .header-widget-area-inner {
        display: block !important;
        width: 100% !important;
        max-width: none !important;
    }

    body.home #ast-desktop-header .gamin-search-container,
    body.home #ast-desktop-header .gamin-search-form,
    body.home #ast-desktop-header .gamin-search-input-container {
        width: 100% !important;
        max-width: none !important;
        height: 40px !important;
        margin: 0 auto !important;
    }

    body.home #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded),
    body.home #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded) .gamin-search-form,
    body.home #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded) .gamin-search-input-container {
        position: relative !important;
        top: auto !important;
        right: auto !important;
        bottom: auto !important;
        left: auto !important;
        min-width: 0 !important;
        overflow: visible !important;
    }

    body.home #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded) {
        transform: translateY(-5px) !important;
    }

    /* Mobil (Figma 3953:38752 = Type Solid): search sedí na světlé liště, ne na
       tmavém heru jako na desktopu. 12% bílá + bílý text = neviditelné pole,
       proto světle šedé pozadí, tmavá lupa i text, bez blur. */
    body.home #ast-desktop-header input.gamin-search-input[type=search] {
        height: 40px !important;
        min-height: 40px !important;
        padding-top: 8px !important;
        padding-bottom: 8px !important;
        padding-left: 40px !important;
        padding-right: 12px !important;
        border-radius: 8px !important;
        background-color: var(--background-secondary, #EEEEEF) !important;
        background-image: url(../img/ikona-lupa-modra.svg) !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        color: var(--text-positive-primary, #022930) !important;
        font-size: 14px !important;
        font-weight: 450 !important;
        line-height: 1.6 !important;
        background-size: 20px 20px !important;
        background-position: 12px 50% !important;
    }

    body.home #ast-desktop-header input.gamin-search-input[type=search]::placeholder {
        color: var(--text-negative-dummy, #A1A1AA) !important;
        opacity: 1 !important;
    }

    body.home #ast-desktop-header .gamin-search-container.is-expanded,
    body.home #ast-desktop-header .gamin-search-container.expanded {
        /* Overlay pod lištou s logem — viz --gamin-search-top (search.js).
           Homepage má vyšší specifičnost, proto stejná úprava i zde. */
        top: var(--gamin-search-top, 0) !important;
        right: 0 !important;
        bottom: 0 !important;
        left: 0 !important;
        width: 100% !important;
        max-width: none !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 16px 0 !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
    }

    body.home #ast-desktop-header .gamin-search-container.is-expanded .gamin-search-form,
    body.home #ast-desktop-header .gamin-search-container.expanded .gamin-search-form,
    body.home #ast-desktop-header .gamin-search-container.is-expanded .gamin-search-input-container,
    body.home #ast-desktop-header .gamin-search-container.expanded .gamin-search-input-container {
        width: 100% !important;
        max-width: none !important;
        height: auto !important;
        margin: 0 !important;
    }

    body.home #ast-desktop-header .gamin-search-container.is-expanded .gamin-search-input-container,
    body.home #ast-desktop-header .gamin-search-container.expanded .gamin-search-input-container {
        height: 44px !important;
    }

    body.home #ast-desktop-header .gamin-search-container.is-expanded input.gamin-search-input[type=search],
    body.home #ast-desktop-header .gamin-search-container.expanded input.gamin-search-input[type=search] {
        background-color: var(--background-secondary, #EEEEEF) !important;
        color: var(--text-positive-primary, #022930) !important;
        -webkit-text-fill-color: var(--text-positive-primary, #022930) !important;
        background-image: url(../img/ikona-lupa-modra.svg) !important;
    }

    body.home #ast-desktop-header .gamin-search-container.is-expanded input.gamin-search-input[type=search]::placeholder,
    body.home #ast-desktop-header .gamin-search-container.expanded input.gamin-search-input[type=search]::placeholder {
        color: var(--text-negative-dummy, #A1A1AA) !important;
        opacity: 1 !important;
    }

    /* Restore the original homepage logo behavior: white on hero, blue once
       navigation.js adds #masthead.scrolled after scrolling. */
    body.home #masthead:not(.scrolled) .ast-logo-title-inline .ast-site-identity a {
        background-image: url(../img/logo-gamin-bile.svg) !important;
    }

    body.home #masthead.scrolled .ast-logo-title-inline .ast-site-identity a {
        background-image: url(../img/logo-gamin-modre.svg) !important;
    }

    body.home #masthead.scrolled .site-logo-img .custom-logo-link,
    body.home #masthead.scrolled .ast-site-identity .custom-logo-link {
        background-image: url(../img/logo-gamin-modre.svg) !important;
    }

    body.home #masthead.scrolled {
        background: rgba(255, 255, 255, 1) !important;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08) !important;
    }

    body.home #masthead.scrolled #ast-mobile-header,
    body.home #masthead.scrolled #ast-mobile-header .ast-primary-header-bar,
    body.home #masthead.scrolled #ast-desktop-header,
    body.home #masthead.scrolled #ast-desktop-header .ast-primary-header-bar,
    body.home #masthead.scrolled #ast-desktop-header .site-primary-header-wrap,
    body.home #masthead.scrolled #ast-desktop-header .ast-builder-grid-row {
        background: rgba(255, 255, 255, 0.96) !important;
    }

    body.home #masthead.scrolled #ast-desktop-header {
        /*border-top: 1px solid var(--border-primary-solid, #E2E2E5) !important;*/
    }

    body.home #masthead.scrolled #ast-desktop-header input.gamin-search-input[type=search] {
        background-color: var(--background-secondary, #EEEEEF) !important;
        color: var(--text-positive-primary, #022930) !important;
        -webkit-text-fill-color: var(--text-positive-primary, #022930) !important;
        border-color: transparent !important;
        background-image: url(../img/ikona-lupa-modra.svg) !important;
    }

    body.home #masthead.scrolled #ast-desktop-header input.gamin-search-input[type=search]::placeholder {
        color: var(--text-negative-dummy, #A1A1AA) !important;
        opacity: 1 !important;
    }

/* Mobile homepage menu-open final override.
   The closed HP header is 112px because it contains logo row + search row.
   When hamburger menu is open, search row must disappear and the menu sheet
   has to start immediately under the 70px white header. */

    body.home.ast-main-header-nav-open #masthead {
        height: 70px !important;
        min-height: 70px !important;
        padding: 0 !important;
        gap: 0 !important;
        background: #fff !important;
        border-bottom: 0 !important;
    }

    body.home.ast-main-header-nav-open #ast-mobile-header,
    body.home.ast-main-header-nav-open #ast-mobile-header .ast-primary-header-bar {
        height: 70px !important;
        min-height: 70px !important;
        background: #fff !important;
    }

    body.home.ast-main-header-nav-open #ast-desktop-header {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        overflow: hidden !important;
    }

    body.home.ast-main-header-nav-open #ast-mobile-header .ast-mobile-header-content {
        top: 70px !important;
    }

    /* Mobile homepage menu trigger — keep the open state visually identical to
       the default Figma trigger (Navigation bar/Mobile 208:6231):
       label 12/1.6, gap 8px, icon 28px, trigger padding 4px 8px. */
    body.home.ast-main-header-nav-open #ast-mobile-header .ast-primary-header-bar {
        padding-right: 16px !important;
        padding-left: 16px !important;
    }

    body.home.ast-main-header-nav-open #ast-mobile-header .site-primary-header-wrap,
    body.home.ast-main-header-nav-open #ast-mobile-header .ast-builder-grid-row {
        width: 100% !important;
        max-width: none !important;
        padding-right: 0 !important;
        padding-left: 0 !important;
        box-sizing: border-box !important;
    }

    body.home.ast-main-header-nav-open #ast-mobile-header .site-header-primary-section-right,
    body.home.ast-main-header-nav-open #ast-mobile-header .site-header-primary-section-right-center {
        display: flex !important;
        justify-content: flex-end !important;
        padding-right: 0 !important;
        margin-right: 0 !important;
    }

    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
        margin-right: 0 !important;
    }

    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .menu-toggle {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-width: 0 !important;
        min-height: 36px !important;
        height: 36px !important;
        padding: 4px 8px !important;
        gap: 8px !important;
        border-radius: 12px !important;
        color: #022930 !important;
        background: transparent !important;
        line-height: 1 !important;
    }

    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        color: #022930 !important;
        font-family: "Plus Jakarta Sans", sans-serif !important;
        font-size: 12px !important;
        font-weight: 500 !important;
        line-height: 1.6 !important;
        letter-spacing: 0.02em !important;
        white-space: nowrap !important;
    }

    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon::before,
    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon::after {
        margin: 0 !important;
        color: #022930 !important;
        font-family: "Plus Jakarta Sans", sans-serif !important;
        font-size: 12px !important;
        font-weight: 500 !important;
        line-height: 1.6 !important;
        letter-spacing: 0.02em !important;
    }

    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon .ast-mobile-svg,
    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon svg {
        display: block !important;
        width: 28px !important;
        height: 28px !important;
        margin: 0 !important;
        flex: 0 0 28px !important;
        color: #022930 !important;
    }

    /* Srovnání pozic na zavřený (default) stav.
       Zavřená hlavička má řádek s logem vysoký 36 px (obsah vycentrovaný na
       y=30), otevřená je 70 px (viz height:70 výše), takže se logo i trigger
       vycentrují o 5–7 px níž. Výšku 70 px neměníme (drží pozadí popupu bez
       mezery) — jen posuneme logo a trigger zpět na pozice zavřeného stavu:
       logo top 18 px, trigger top 12 px (ověřeno měřením na dev3). */
    body.home.ast-main-header-nav-open #ast-mobile-header .site-header-primary-section-left .site-branding {
        transform: translateY(-5px) !important;
    }
    body.home.ast-main-header-nav-open #ast-mobile-header [data-section="section-header-mobile-trigger"] .ast-button-wrap {
        transform: translateY(-7px) !important;
    }

    /* Vypnout transition na těchto prvcích v OBOU stavech.
       .ast-primary-header-bar má `transition: all .2s` (animuje růst výšky
       36→70) a .site-branding / .ast-button-wrap animují náš transform výše.
       Bez tohoto logo i trigger při otevírání viditelně „poskočí" a při
       zavírání se animují zpět. Musí být mimo `.ast-main-header-nav-open`,
       jinak se transition po zavření zase zapne a close se animuje.
       Sticky scroll výšku mobilního baru nemění (zůstává 36 px), takže
       vypnutí transition nemá vedlejší efekt. */
    body.home #ast-mobile-header .ast-primary-header-bar,
    body.home #ast-mobile-header .site-header-primary-section-left .site-branding,
    body.home #ast-mobile-header [data-section="section-header-mobile-trigger"] .ast-button-wrap {
        transition: none !important;
    }
}

/* Sticky-offset guard.
   The old audit-sticky-nav fallback moved the whole document by 100px when
   --gamin-header-height was not set. That visibly broke mobile/subpage
   headers and duplicates the browser/WP admin-bar handling, so body offset is
   disabled completely. */
body {
    --gamin-header-height: 0px !important;
    padding-top: 0 !important;
}

/* 921px desktop-megamenu guard.
   At Astra's inclusive 921px breakpoint the desktop header can still keep
   desktop menu/megamenu DOM visible while the mobile trigger is already active.
   That paints the white megamenu ("Řekli o nás") over the homepage hero and
   its Owl carousel expands document width to ~3900px. Below/equal 921px the
   desktop header may only provide the search row; navigation belongs to the
   mobile menu. */
@media (max-width: 921.98px) {
    #ast-desktop-header #ast-hf-menu-1,
    #ast-desktop-header .main-header-menu,
    #ast-desktop-header .main-navigation,
    #ast-desktop-header .ast-builder-menu,
    #ast-desktop-header .sub-menu,
    #ast-desktop-header .sub-wrapper,
    #ast-desktop-header .megamenu-content,
    #ast-desktop-header .astra-full-megamenu-wrapper,
    #ast-desktop-header .ast-mm-custom-content,
    #ast-desktop-header .reference-list.owl-carousel,
    #ast-desktop-header .reference-list .owl-stage-outer,
    #ast-desktop-header .reference-list .owl-stage {
        display: none !important;
        width: 0 !important;
        max-width: 0 !important;
        height: 0 !important;
        max-height: 0 !important;
        overflow: hidden !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }
}

/* 921px breakpoint guard.
   Astra still treats 921px as the mobile header breakpoint. At the exact edge
   the mobile menu content can remain visible even while the menu is logically
   closed, which paints a white menu layer over the homepage hero. Closed
   mobile/tablet menu content must always be collapsed. */
@media (min-width: 768px) and (max-width: 921.98px) {
    body:not(.ast-main-header-nav-open) #ast-mobile-header .ast-mobile-header-content {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
        overflow: hidden !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }

    body:not(.ast-main-header-nav-open) #primary-site-navigation-mobile,
    body:not(.ast-main-header-nav-open) #ast-hf-menu-1-mobile {
        display: none !important;
    }
}

/* Mobile menu focused/open trigger — Figma node 178:6197.
   Astra already renders the "Zavřít" label as a pseudo element, but older
   homepage-transparent rules leave it white on the white focused header.
   Normalise the focused trigger for all mobile pages. */
@media (max-width: 767.98px) {
    body.ast-main-header-nav-open #ast-mobile-header .ast-primary-header-bar {
        padding-right: 31px !important;
        padding-left: 16px !important;
        background: #fff !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .site-logo-img,
    body.ast-main-header-nav-open #ast-mobile-header .ast-site-identity {
        width: 120px !important;
        height: 24px !important;
        padding: 0 !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .ast-logo-title-inline .ast-site-identity a,
    body.ast-main-header-nav-open #ast-mobile-header .site-logo-img .custom-logo-link {
        width: 120px !important;
        height: 24px !important;
        background-size: 120px 24px !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .menu-toggle {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: auto !important;
        min-width: 0 !important;
        height: 36px !important;
        min-height: 36px !important;
        padding: 4px 8px !important;
        gap: 8px !important;
        border-radius: 12px !important;
        color: #022930 !important;
        background: transparent !important;
        line-height: 1 !important;
        box-sizing: border-box !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        width: auto !important;
        height: 28px !important;
        color: #022930 !important;
        font-family: "Plus Jakarta Sans", sans-serif !important;
        font-size: 12px !important;
        font-weight: 500 !important;
        line-height: 1.6 !important;
        letter-spacing: 0.02em !important;
        white-space: nowrap !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon::before {
        content: "Zav\0159\00EDt" !important;
        display: block !important;
        margin: 0 !important;
        color: #022930 !important;
        font-family: "Plus Jakarta Sans", sans-serif !important;
        font-size: 12px !important;
        font-weight: 500 !important;
        line-height: 1.6 !important;
        letter-spacing: 0.02em !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon .ast-close-svg {
        display: block !important;
        width: 28px !important;
        height: 28px !important;
        margin: 0 !important;
        flex: 0 0 28px !important;
        color: #022930 !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon .ast-menu-svg {
        display: none !important;
    }

/* Mobile subpage search row.
   Below Astra's 921px breakpoint the desktop header is reused only as a search
   row. Its desktop grid/wrapper widths must be neutralised; otherwise the
   search input collapses to a partial-width desktop column on category/product
   pages. */

    body:not(.home).ast-header-break-point #ast-desktop-header {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        background: #fff !important;
    }

    body:not(.home).ast-header-break-point #ast-desktop-header .ast-primary-header-bar {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-height: 72px !important;
        height: 72px !important;
        padding: 16px !important;
        background: #fff !important;
        border-top: 1px solid var(--border-primary-solid, #e2e2e5) !important;
        border-bottom: 1px solid var(--border-primary-solid, #e2e2e5) !important;
        box-sizing: border-box !important;
    }

    body:not(.home).ast-header-break-point #ast-desktop-header .site-primary-header-wrap,
    body:not(.home).ast-header-break-point #ast-desktop-header .ast-builder-grid-row-container,
    body:not(.home).ast-header-break-point #ast-desktop-header .ast-builder-grid-row,
    body:not(.home).ast-header-break-point #ast-desktop-header .site-header-primary-section-right,
    body:not(.home).ast-header-break-point #ast-desktop-header .site-header-primary-section-right-center,
    body:not(.home).ast-header-break-point #ast-desktop-header .header-widget-area,
    body:not(.home).ast-header-break-point #ast-desktop-header .header-widget-area-inner {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        height: auto !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }

    body:not(.home).ast-header-break-point #ast-desktop-header .site-header-primary-section-left,
    body:not(.home).ast-header-break-point #ast-desktop-header .site-header-primary-section-left-center,
    body:not(.home).ast-header-break-point #ast-desktop-header .site-header-primary-section-center {
        display: none !important;
    }

    body:not(.home).ast-header-break-point #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded),
    body:not(.home).ast-header-break-point #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded) .gamin-search-form,
    body:not(.home).ast-header-break-point #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded) .gamin-search-input-container {
        position: relative !important;
        inset: auto !important;
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        height: 40px !important;
        min-height: 40px !important;
        margin: 0 !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }

    body:not(.home).ast-header-break-point #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded) input.gamin-search-input[type=search] {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        height: 40px !important;
        min-height: 40px !important;
        padding: 8px 12px 8px 40px !important;
        border: 0 !important;
        border-radius: 8px !important;
        background-color: var(--container-surface-secondary, #eeeeef) !important;
        background-position: 12px 50% !important;
        color: var(--text-positive-primary, #022930) !important;
        box-sizing: border-box !important;
    }

    body:not(.home).ast-header-break-point #ast-desktop-header .gamin-search-container:not(.is-expanded):not(.expanded) .gamin-search-cancel {
        display: none !important;
    }

/* Mobile open-menu trigger polish.
   Real interaction after scroll keeps the header fixed at 100vw, while the
   document client width is narrower because of the browser scrollbar. Add a
   right offset to keep the close label/icon aligned with the closed Menu
   trigger, and use CSS escapes for Czech text to avoid mojibake in generated
   content. */

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] {
        margin-right: 31px !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon::before {
        content: "Zav\0159\00EDt" !important;
    }

/* Android mobile footer/menu stabilisation.
   Fixes real Chrome/Android rendering where the open menu kept both hamburger
   and close icons, and where footer CTA/menu inherited older flex/footer rules. */

    body.ast-main-header-nav-open #ast-mobile-header .ast-primary-header-bar {
        padding-right: 16px !important;
        padding-left: 16px !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .site-primary-header-wrap,
    body.ast-main-header-nav-open #ast-mobile-header .ast-builder-grid-row {
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .site-header-primary-section-left {
        padding-left: 16px !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .site-header-primary-section-right,
    body.ast-main-header-nav-open #ast-mobile-header .site-header-primary-section-right-center {
        padding-right: 0 !important;
    }

    body.home.ast-main-header-nav-open [data-section="section-header-mobile-trigger"],
    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] {
        margin-right: 16px !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon::before {
        content: "Zav\0159\00EDt" !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .menu-toggle .ast-mobile-svg:not(.ast-close-svg),
    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .menu-toggle .ast-menu-svg,
    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon .ast-mobile-svg:not(.ast-close-svg),
    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon .ast-menu-svg {
        display: none !important;
        visibility: hidden !important;
    }

    body.ast-main-header-nav-open [data-section="section-header-mobile-trigger"] .ast-button-wrap .mobile-menu-toggle-icon .ast-close-svg {
        display: block !important;
        visibility: visible !important;
        width: 28px !important;
        height: 28px !important;
        flex: 0 0 28px !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .ast-mobile-header-content {
        box-sizing: border-box !important;
        padding: 12px 16px 32px !important;
        background: #f7f7f7 !important;
    }

    body.ast-main-header-nav-open #ast-mobile-header .ast-mobile-header-content .mobile-lang-switch {
        width: 100% !important;
        margin: 0 0 32px !important;
    }

    body.ast-main-header-nav-open #primary-site-navigation-mobile,
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile {
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0 !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li {
        box-sizing: border-box !important;
        width: 100% !important;
        min-height: 64px !important;
        margin: 0 !important;
        padding: 0 !important;
        border-top: 1px solid #e2e2e5 !important;
        border-bottom: 0 !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li:last-child {
        border-bottom: 1px solid #e2e2e5 !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li > a,
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li > .menu-link {
        box-sizing: border-box !important;
        display: flex !important;
        align-items: center !important;
        min-height: 64px !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 20px 0 !important;
        color: #022930 !important;
        font-size: 16px !important;
        font-weight: 650 !important;
        line-height: 1.6 !important;
        text-align: left !important;
    }

    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li > .ast-menu-toggle {
        right: 0 !important;
        width: 40px !important;
        height: 64px !important;
    }

    /* C1 — viz komentář výše: sjednocení s `.ast-menu-toggle` (opticky 20 px). */
    body.ast-main-header-nav-open #ast-hf-menu-1-mobile > li:not(.menu-item-has-children)::after {
        right: 16px !important;
    }
}

/* Final 921px edge guard — must stay at EOF. Guard mobile-header contentu na
   homepage tabletu (skryté dokud není menu otevřené). [Dřívější #ast-desktop-header
   .child guard smazán 2026-09-09: #ast-desktop-header je na tabletu display:none (§13),
   děti se nerenderují.] */
@media (min-width: 768px) and (max-width: 921.98px) {

    body.home:not(.ast-main-header-nav-open) #ast-mobile-header .ast-mobile-header-content,
    body.home:not(.ast-main-header-nav-open) #ast-mobile-header .mobile-lang-switch,
    body.home:not(.ast-main-header-nav-open) #ast-mobile-header #ast-hf-menu-1-mobile {
        display: none !important;
        height: 0 !important;
        max-height: 0 !important;
        overflow: hidden !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }

/* ===========================================================================
   A5 — Tablet 768–921: hlavička byla 70 px a vyhledávací řádek z ní vypadával
   ---------------------------------------------------------------------------
   #masthead je flex kontejner; .gamin-search-container je jeho třetí dítě,
   ale nedostal se do výšky hlavičky — vykresloval se na y=72 přes hero.
   Figma 7014:36859: celá lišta 112 px = 12 + 36 (logo/menu) + 12 + 40 (search)
   + 12. Pod 768 px už to takto funguje, chyběl jen pás 768–921.
   ========================================================================== */

    /* `gap: 0` + margin na search řádku je záměr: #masthead má i skryté/prázdné
       flex položky, které by při `gap` přidaly mezery navíc (naměřeno 136 px
       místo 112). Padding dole = 0: na podstránkách je posledním prvkem světlý
       search panel (#F7F7F7) a spodní bílý padding hlavičky pod ním dělal bílý
       pruh; bez něj panel lícuje s obsahem. Homepage má vlastní `body.home
       #masthead` (padding 12px 0) → tam se to neprojeví. */
    #masthead {
        display: flex !important;
        flex-direction: column !important;
        gap: 0 !important;
        padding: 12px 0 0 !important;
    }

    /* Řádek s logem a tlačítkem Menu: Figma 654:17258 = 36 px (dev měl 70 px
       z megamenu.css `height: 70px` + Astra dynamic CSS `min-height: 70px`). */
    #masthead .ast-mobile-header-wrap .ast-primary-header-bar,
    #ast-mobile-header .ast-primary-header-bar {
        min-height: 36px !important;
        height: 36px !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
    }

    #masthead .ast-mobile-header-wrap .ast-primary-header-bar .ast-builder-grid-row,
    #masthead .ast-mobile-header-wrap .site-header-primary-section-left,
    #masthead .ast-mobile-header-wrap .site-header-primary-section-right {
        min-height: 36px !important;
        align-items: center !important;
    }

    #masthead .ast-mobile-header-wrap .site-logo-img img,
    #masthead .ast-mobile-header-wrap .custom-logo-link {
        height: 24px !important;
    }

    /* KLÍČOVÉ: search není přímé dítě #masthead — je zabalený v nepojmenovaném
       <div>, který byl position:absolute, a proto se nezapočítal do výšky
       hlavičky. Vyhledávání se pak vykreslovalo přes hero. */
    #masthead > div:has(> .gamin-search-container) {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        width: 100% !important;
        margin-top: 12px !important;
    }

    #masthead .gamin-search-container {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        /* Vodorovný gutter 20px = lícuje s LOGEM a HAMBURGEREM v hlavičce (grid row
           má 20px gutter). Dřív 32px (obsahový gutter) → search nelícoval s hlavičkou.
           Svislé odsazení dodá panel #gamin-tablet-search: 10px. */
        padding: 0 20px !important;
    }

    #masthead .gamin-search-form,
    #masthead .gamin-search-input-container {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        width: 100% !important;
        max-width: none !important;
    }

    /* Tlačítko Menu má na tabletu jiný tvar než na mobilu (91×50 / radius 2).
       Figma 654:17551: 85×36, radius 12 na obou. */
    #masthead .menu-toggle {
        min-height: 36px !important;
        padding: 4px 8px !important;
        border-radius: var(--radius-s, 12px) !important;
        font-size: 14px !important;
    }
}

/* ===========================================================================
   25. Header „open" stavy — sjednocení motivu (background-primary, NIKDY bílá)
   ---------------------------------------------------------------------------
   Dle Figmy (podstránka 1359:10607, rozbalený search 752:10494) je motiv vždy
   background-primary (#F7F7F7) nebo dark — nikde čistá bílá; bílá byla chyba.
   Tyto stavy jsou SVĚTLÉ ve všech kontextech (homepage A/B i podstránka), takže
   jsou page-agnostic (bez `body.home`), čímž se ruší dřívější
   kolize homepage vs. podstránka:
     - otevřené fullscreen menu: lišta #masthead = background-primary (byla bílá
       rgba 255/.96), popisek „Zavřít" tmavý (byl bílý → neviditelný),
     - rozbalený tablet search: panel = background-primary bez bílého vnitřního
       boxu (mizí „šedé odsazení" po stranách), pole zůstává #EEEEEF.
   ========================================================================== */

/* Otevřené menu — lišta i „Zavřít" jsou vždy na světlé liště (všechny kontexty).
   Barvení „Menu" (zavřený stav) NEřešíme — to je kontextové (na var. A bílé). */
body.ast-main-header-nav-open #masthead {
    background-color: var(--background-primary, #F7F7F7) !important;
}

body.ast-main-header-nav-open .mobile-menu-toggle-icon::before {
    color: var(--text-positive-primary, #022930) !important;
}

/* Rozbalení podmenu ve fullscreen menu (mobil + tablet) po kliknutí na šipku.
   JS (megamenu.js) přidá `.ast-submenu-expanded` na <li>, ale `.sub-menu` má
   jinde `display:none !important` (frontend.min.css / .hidden), takže původní
   pravidlo v responsive.css (`display:block` bez !important) neúčinkovalo. Zde
   s !important a vyšší specificitou. V audit-fixes (cache-busted `1.0.time()`),
   protože responsive.css je enqueue bez verze → prohlížeč ho drží v cache. */
body.ast-main-header-nav-open .main-header-bar-navigation .menu-item-has-children.ast-submenu-expanded > .sub-wrapper .sub-menu,
body.ast-main-header-nav-open .main-header-bar-navigation .menu-item-has-children.ast-submenu-expanded > .sub-menu {
    display: block !important;
}

/* ###########################################################################
   HEADER.CSS SLOUČENO 2026-09-08 (merge krok b) — append na konec audit-fixes.
   Přesun z css/header.css (bylo enqueue @10003) → sem (@10000). Kaskáda zachována:
   audit header rules PRVNÍ, tento (dřív header.css) blok DRUHÝ = shodné pořadí jako
   audit(10000) < header(10003). Flip-check ověřen: header selektory disjunktní od
   content/page-scoped/footer; jediný překryv .main-header-menu je ve footer.css jako
   .site-footer .main-header-menu (specificita 0,4,0 > 0,3,0 → safe). Enqueue
   gamin_header_styles ODSTRANĚN, css/header.css archivováno v _old/.
   ########################################################################### */
/* ===========================================================================
   HEADER — komponentní soubor (konsolidace, roadmapa bod 4)
   ===========================================================================
   Cíl: jediný pozdě-načítaný zdroj pro override vrstvu hlavičky (priorita 10003
   ve functions.php, po audit-enqueue 10000 / page-scoped 10002), aby header
   overridy vyhrávaly POZICÍ, ne slepým !important → order-independent (bezpečné
   pro CSS agregaci).

   Strategie (potvrzeno 2026-09-06): Astra HEADER BUILDER zůstává (header.php volá
   astra_header()); tady jen konsolidujeme override CSS. Sem se po podkomponentech
   (s live baseline + verifikací) rozpouští header scatter z:
   - audit-fixes.css (~394 zásahů: §13/18/19/25/29/30 — tablet/mobil nav + search stavy)
   - custom.css (~37), responsive.css (~47)
   Koherentní single-source soubory zatím ZŮSTÁVAJÍ vlastní: navigation.css (lang
   switcher + mobile toggle), search.css (search overlay), megamenu.css, audit-sticky-nav.css.

   DOM (Astra builder): header#masthead > #ast-desktop-header (.ast-above-header-bar
   + .ast-primary-header-bar) | #ast-mobile-header (.ast-primary-header-bar +
   .ast-mobile-header-content off-canvas).

   Struktura souboru (pořadí = kaskáda uvnitř header.css): base/desktop → @tablet
   → @mobil → stavy (nav-open / search). Base vždy první.

   Postup: Fáze 1 plumbing (hotovo) → Fáze 2 desktop base → mobil/tablet → stavy → search.
   =========================================================================== */

/* ===========================================================================
   FÁZE 3 — Responsive desktop header grid (shrink center/right sloupce).
   Přesunuto z responsive.css (@1240/1160/1120/1020/992). MUSÍ být zde za base
   gridem (192.5/auto/382.5): base je teď v header.css (10003) bez media, takže
   responsive (9999, @media, stejná specificita) by prohrál pozicí → shrink se
   nezmenšoval. Tady za base = order-independent. Konsolidace #4 2026-09-07.
   =========================================================================== */
@media (max-width: 1240px) {
    .ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
        grid-template-columns: 172px auto 336px;
    }
}

@media (max-width: 1160px) {
    .ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
        grid-template-columns: 172px auto 240px;
    }
}

@media (max-width: 1120px) {
    .ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
        grid-template-columns: 172px auto 220px;
    }
}

@media (max-width: 1020px) {
    .ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
        grid-template-columns: 160px auto 180px;
    }
}

@media (max-width: 992px) {
    .ast-primary-header-bar .ast-builder-grid-row.ast-grid-center-col-layout {
        grid-template-columns: 160px auto 140px;
    }
}
