/*
 * Podstrona "Szpitale" - bloki acf/acf-block-szp-* + szablon page-szpitale.php.
 * Projekt: design/Szpitale BCM.html.
 *
 * Ladowany tylko na stronach z tymi blokami (functions/szpitale-dane.php) i w edytorze
 * (editorStyle w block.json). Wszystkie klasy maja prefiks .szp-.
 *
 * Jednostki: html ma font-size 62.5%, wiec 1rem = 10px. Rozmiary pisma sa w rem,
 * zeby powiekszenie tekstu w przegladarce (WCAG 1.4.4) skalowalo cala strone.
 *
 * ZALOZENIA DOSTEPNOSCI (WCAG 2.1 AA) - do powtorzenia na kolejnych podstronach:
 *  - kontrast tekstu >= 4.5:1, duzego tekstu i granic kontrolek >= 3:1. Wzgledem projektu
 *    zmienione: #6A7890 -> #5A6B85, zielony #1E8A5A -> #177A4E, ramki filtrow
 *    #D5DCE8 -> #7A879C, kreska "brak" #C4CCDA -> #5A6B85;
 *  - widoczny fokus na wszystkim, co klikalne: 3px obrys, jasny na ciemnym tle;
 *  - cele dotyku min. 44 px (przyciski, filtry, linki-kafelki);
 *  - kotwice nie chowaja sie pod stalym naglowkiem (scroll-padding-top), a element
 *    z fokusem pod mobilnym paskiem akcji (scroll-padding-bottom) - WCAG 2.4.11;
 *  - prefers-reduced-motion wylacza animacje i plynne przewijanie;
 *  - forced-colors (tryb wysokiego kontrastu Windows) - przyciski i filtry maja
 *    przezroczyste ramki, ktore system zamienia na widoczne;
 *  - siatki oparte o minmax(min(100%, X), 1fr): przy 320 px szerokosci i 400 %
 *    powiekszenia nic nie wymaga przewijania w poziomie (1.4.10) poza tabela danych;
 *  - zadnych stalych wysokosci pod tekstem - tylko min-height (odstepy tekstu, 1.4.12).
 */

/* ============================================================ BAZA */

html:has(.szp-strona) {
    scroll-padding-top: 104px; /* naglowek 80 px + zapas */
}

.szp-strona {
    --szp-granat: #12336B;
    --szp-granat-ciemny: #0B2350;
    --szp-czerwien: #C8102E;
    --szp-czerwien-ciemna: #A80D26;
    --szp-tekst: #16233A;
    --szp-tekst-2: #3A4A66;
    --szp-tekst-3: #4A5A75;
    --szp-tekst-4: #5A6B85;
    --szp-ramka: #E1E6EF;
    --szp-ramka-kontrolki: #7A879C;
    --szp-tlo-jasne: #F4F6FA;
    --szp-tlo-szare: #E3E8F0;
    --szp-fokus: #2E6BD6;
    --szp-gutter: clamp(20px, 4vw, 40px);
    --szp-odstep: clamp(56px, 8vw, 104px);

    display: block;
    /*
     * Motyw ma globalne `main { max-width: 1170px; margin: 0 auto }` (dist/assets/index.css).
     * Projekt ma tla sekcji od krawedzi do krawedzi i tresc do 1400 px - szerokosc tresci
     * trzyma .szp-wrap, wiec <main> musi byc na cala szerokosc.
     */
    width: 100%;
    max-width: none;
    margin: 0;
    /*
     * Miejsce pod staly naglowek motywu (header#header.header-fixed). Jego wysokosc
     * wyznacza wewnetrzny pasek z klasami h-32 2xl:h-40 (header.php): 80 px, a od
     * 1170 px - 100 px. Globalne `div#main {padding-top: 80px}` pomija ten drugi
     * prog, dlatego tu jest wlasna para wartosci.
     */
    padding-top: 80px;
    background: #fff;
    color: var(--szp-tekst);
    font-family: "Figtree-Regular", sans-serif;
}

@media (min-width: 1170px) {
    .szp-strona {
        padding-top: 100px;
    }

    html:has(.szp-strona) {
        scroll-padding-top: 130px;
    }
}

.szp-strona:focus {
    outline: none;
}

.szp-wrap {
    max-width: calc(1400px + 2 * var(--szp-gutter));
    margin: 0 auto;
    padding-left: var(--szp-gutter);
    padding-right: var(--szp-gutter);
}

/* Motyw stylizuje listy, naglowki, akapity i tabele globalnie - tu wszystko od zera. */
.szp-strona ul,
.szp-strona ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

.szp-strona ul li,
.szp-strona ol li {
    margin: 0;
    padding: 0;
}

.szp-strona ul li::before,
.szp-strona ol li::before {
    content: none;
}

.szp-strona h1,
.szp-strona h2,
.szp-strona h3,
.szp-strona h4,
.szp-strona p,
.szp-strona address {
    margin: 0;
    letter-spacing: normal;
}

.szp-strona img {
    max-width: 100%;
}

.szp-sekcja {
    padding-top: var(--szp-odstep);
}

/* Ukryte wizualnie, dostepne dla czytnika ekranu. */
.szp-sr {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.szp-pusto {
    padding: 24px;
    border: 1px dashed var(--szp-ramka-kontrolki);
    border-radius: 12px;
    font-size: 1.5rem;
    line-height: 1.6;
    color: var(--szp-tekst-3);
}

/* ============================================================ FOKUS */

.szp-strona a:focus-visible,
.szp-strona button:focus-visible,
.szp-strona [tabindex="0"]:focus-visible,
.szp-pasek-mobilny a:focus-visible {
    outline: 3px solid var(--szp-fokus);
    outline-offset: 3px;
    border-radius: 4px;
}

.szp-strona .szp-ciemna a:focus-visible,
.szp-strona .szp-ciemna button:focus-visible,
.szp-strona .szp-ciemna [tabindex="0"]:focus-visible {
    outline-color: #fff;
}

/* ============================================================ NAGLOWEK SEKCJI */

.szp-glowa {
    margin-bottom: 36px;
}

.szp-glowa--obok {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
    gap: 20px 48px;
    align-items: end;
}

.szp-glowa--pod .szp-lead {
    margin-top: 16px;
}

.szp-nadtytul {
    margin-bottom: 14px;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.3rem;
    line-height: 1.4;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--szp-czerwien);
}

.szp-nadtytul--kreska {
    display: flex;
    align-items: center;
    gap: 10px;
}

.szp-nadtytul--kreska::before {
    content: "";
    display: block;
    width: 28px;
    height: 2px;
    flex-shrink: 0;
    background: var(--szp-czerwien);
}

.szp-strona .szp-tytul {
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: clamp(3rem, 3.4vw, 4.2rem);
    line-height: 1.1;
    color: var(--szp-granat);
    text-wrap: balance;
}

.szp-lead {
    max-width: 560px;
    font-size: 1.6rem;
    line-height: 1.6;
    color: var(--szp-tekst-3);
    text-wrap: pretty;
}

.szp-ciemna .szp-nadtytul {
    color: #AFC4E6;
}

.szp-ciemna .szp-tytul {
    color: #fff;
}

.szp-ciemna .szp-lead {
    color: #D2DEF1;
}

.szp-strzalka {
    display: inline-block;
}

/* ============================================================ PRZYCISKI */

.szp-strona .szp-btn,
.szp-pasek-mobilny .szp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 12px 24px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.5rem;
    line-height: 1.3;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

.szp-btn--czerwony,
.szp-btn--czerwony:visited {
    background: var(--szp-czerwien);
    color: #fff;
}

.szp-btn--czerwony:hover {
    background: var(--szp-czerwien-ciemna);
    color: #fff;
}

.szp-btn--granat,
.szp-btn--granat:visited {
    background: var(--szp-granat);
    color: #fff;
}

.szp-btn--granat:hover {
    background: var(--szp-granat-ciemny);
    color: #fff;
}

.szp-strona .szp-btn--obrys-jasny {
    border-color: rgba(255, 255, 255, .55);
    color: #fff;
}

.szp-btn--obrys-jasny:hover {
    background: rgba(255, 255, 255, .1);
    color: #fff;
}

.szp-strona .szp-btn--obrys {
    border-color: var(--szp-ramka-kontrolki);
    background: #fff;
    color: var(--szp-granat);
    font-size: 1.4rem;
}

.szp-btn--obrys:hover {
    border-color: var(--szp-granat);
}

.szp-przyciski {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

/* ============================================================ FILTRY */

.szp-filtry {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.szp-filtry[hidden] {
    display: none;
}

.szp-strona .szp-chip {
    min-height: 44px;
    padding: 0 18px;
    border: 1px solid var(--szp-ramka-kontrolki);
    border-radius: 8px;
    background: #fff;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.4rem;
    line-height: 1.2;
    color: var(--szp-granat);
    cursor: pointer;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.szp-strona .szp-chip:hover {
    border-color: var(--szp-granat);
}

.szp-strona .szp-chip[aria-pressed="true"] {
    border-color: var(--szp-granat);
    background: var(--szp-granat);
    color: #fff;
}

.szp-strona .szp-filtry--ciemne .szp-chip {
    min-height: 40px;
    padding: 0 14px;
    border-color: rgba(255, 255, 255, .55);
    background: transparent;
    font-size: 1.3rem;
    color: #fff;
}

.szp-strona .szp-filtry--ciemne .szp-chip[aria-pressed="true"] {
    border-color: #fff;
    background: #fff;
    color: var(--szp-granat);
}

/* ============================================================ HERO */

.szp-hero {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    padding-top: 0;
    color: #fff;
    background:
        radial-gradient(900px 620px at 8% 18%, rgba(37, 86, 168, .55) 0%, rgba(37, 86, 168, 0) 62%),
        radial-gradient(680px 520px at 62% 100%, rgba(200, 16, 46, .30) 0%, rgba(200, 16, 46, 0) 60%),
        linear-gradient(160deg, #123566 0%, #0E2A57 46%, #0A1F45 100%);
}

.szp-hero-zdjecie {
    position: absolute;
    inset: 0;
    z-index: -2;
    background-position: center 40%;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: .3;
    mix-blend-mode: luminosity;
    -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, .1) 0%, rgba(0, 0, 0, .5) 45%, #000 80%), linear-gradient(0deg, transparent 0%, #000 35%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(90deg, rgba(0, 0, 0, .1) 0%, rgba(0, 0, 0, .5) 45%, #000 80%), linear-gradient(0deg, transparent 0%, #000 35%);
    mask-composite: intersect;
}

.szp-hero-cien {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(90deg, rgba(10, 31, 69, .85) 0%, rgba(10, 31, 69, .35) 55%, rgba(10, 31, 69, .15) 100%);
}

.szp-hero-wnetrze {
    padding-top: clamp(28px, 4vw, 40px);
    padding-bottom: clamp(48px, 7vw, 88px);
}

.szp-okruszki {
    margin-bottom: clamp(28px, 4vw, 48px);
    font-size: 1.4rem;
    line-height: 1.5;
    color: #C7D6EE;
}

.szp-okruszki ol {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
}

.szp-strona .szp-okruszki li + li::before {
    content: "/" / "";
    display: inline;
    position: static;
    min-width: 0;
    min-height: 0;
    margin: 0 8px 0 0;
    background: none;
    border-radius: 0;
    font-size: inherit;
    line-height: inherit;
    color: #AFC4E6;
}

.szp-strona .szp-okruszki a {
    color: #C7D6EE;
    text-decoration: underline;
    text-decoration-color: rgba(199, 214, 238, .45);
    text-underline-offset: 3px;
}

.szp-strona .szp-okruszki a:hover {
    color: #fff;
    text-decoration-color: #fff;
}

.szp-okruszki [aria-current="page"] {
    color: #fff;
}

.szp-hero-siatka {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr));
    gap: clamp(32px, 5vw, 72px);
    align-items: center;
    margin-bottom: 40px;
}

.szp-hero-marka {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px 20px;
    margin-bottom: 26px;
}

.szp-hero-logo {
    display: block;
    width: auto;
    height: 44px;
}

.szp-hero-marka-kreska {
    display: block;
    width: 1px;
    height: 32px;
    background: rgba(255, 255, 255, .35);
}

.szp-hero-podpis {
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.4rem;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #fff;
}

.szp-strona .szp-hero-tytul {
    margin: 0 0 24px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: clamp(3.6rem, 4.6vw, 6.2rem);
    line-height: 1.05;
    letter-spacing: -.015em;
    color: #fff;
    text-wrap: balance;
}

.szp-hero-lead {
    max-width: 580px;
    margin: 0 0 34px !important;
    font-size: clamp(1.6rem, 1.4vw, 1.8rem);
    line-height: 1.65;
    color: #D2DEF1;
    text-wrap: pretty;
}

.szp-hero-lista {
    padding: clamp(20px, 2.4vw, 28px);
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 20px;
    background: rgba(255, 255, 255, .08);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
}

.szp-hero-lista-tytul {
    margin: 0 0 8px 4px;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.3rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #AFC4E6;
}

.szp-strona .szp-hero-lista a {
    display: grid;
    grid-template-columns: 44px 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 16px 4px;
    border-top: 1px solid rgba(255, 255, 255, .14);
    color: #fff;
    text-decoration: none;
    transition: background-color .2s ease;
}

.szp-strona .szp-hero-lista a:hover {
    background: rgba(255, 255, 255, .06);
    color: #fff;
}

.szp-strona .szp-hero-lista a:hover .szp-hero-lista-miasto {
    text-decoration: underline;
}

.szp-hero-lista-nr {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .12);
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.4rem;
    color: #FF8A9B;
}

.szp-hero-lista-miasto {
    display: block;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.8rem;
    line-height: 1.3;
}

.szp-hero-lista-profil {
    display: block;
    font-size: 1.4rem;
    line-height: 1.45;
    color: #C7D6EE;
}

.szp-hero-lista .szp-strzalka {
    font-size: 1.8rem;
}

/*
 * Pasek liczb - wyglad 1:1 z hero strony glownej (.hero-v2-stats w
 * acf-blocks/acf-block-hero/acf-block-hero.css): 4 kolumny, kreski 22 % bieli,
 * 30 px odstepu tresci od kreski, liczba 4rem z jednostka w tej samej linii.
 *
 * Selektory z ".szp-strona ... li" celowo: reset list na gorze pliku
 * (.szp-strona ul li {padding: 0}) ma wyzsza specyficznosc niz sama klasa
 * i wczesniej zjadal odstep od kreski.
 */
.szp-liczby {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-top: 60px;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, .22);
}

.szp-strona .szp-liczby li.szp-liczby-pozycja {
    padding: 20px 30px;
    border-left: 1px solid rgba(255, 255, 255, .22);
}

.szp-strona .szp-liczby li.szp-liczby-pozycja:first-child {
    padding-left: 0;
    border-left: 0;
}

.szp-strona .szp-liczby-wartosc {
    margin: 0 0 14px 0;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 4rem;
    line-height: 1.1;
    color: #fff;
}

.szp-liczby-jednostka {
    margin-left: 4px;
    font-size: 1.8rem;
    color: #a8c0e8;
}

.szp-strona .szp-liczby-opis {
    margin: 0;
    font-size: 1.4rem;
    line-height: 1.55;
    color: #b7c9e8;
    text-wrap: pretty;
}

@media (max-width: 1024px) {
    .szp-liczby {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 32px;
    }

    .szp-strona .szp-liczby li.szp-liczby-pozycja:nth-child(odd) {
        padding-left: 0;
        border-left: 0;
    }
}

@media (max-width: 640px) {
    .szp-liczby {
        grid-template-columns: minmax(0, 1fr);
    }

    .szp-strona .szp-liczby li.szp-liczby-pozycja {
        padding: 0;
        border-left: 0;
    }

    .szp-strona .szp-liczby-wartosc {
        font-size: 3.4rem;
    }
}

/* ============================================================ O SZPITALACH */

.szp-on-siatka {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr));
    gap: clamp(32px, 5vw, 72px);
    align-items: center;
}

.szp-on-kolaz {
    order: -1; /* wizualnie po lewej, w kodzie po tekscie */
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(2, minmax(160px, 1fr));
    gap: 12px;
    aspect-ratio: 4 / 3;
}

.szp-on-kolaz-pole {
    overflow: hidden;
    border-radius: 18px;
    background: var(--szp-tlo-szare);
}

.szp-on-kolaz-pole:first-child {
    grid-row: span 2;
}

.szp-on-kolaz--1 {
    grid-template-columns: 1fr;
}

.szp-on-kolaz--2 .szp-on-kolaz-pole:first-child {
    grid-row: auto;
}

.szp-on-kolaz--2 {
    grid-template-rows: 1fr;
}

.szp-on-kolaz-pole img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.szp-on-tresc p {
    margin: 0 0 16px;
    font-size: 1.5rem;
    line-height: 1.6;
    color: var(--szp-tekst-3);
    text-wrap: pretty;
}

.szp-on-tresc p:first-child {
    font-size: 1.7rem;
    line-height: 1.65;
    color: var(--szp-tekst-2);
}

.szp-on-tresc a {
    color: var(--szp-granat);
    text-decoration: underline;
}

.szp-on-fakty {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: 22px 28px;
    margin-top: 28px !important;
}

.szp-on-fakt {
    padding-top: 14px !important;
    border-top: 2px solid var(--szp-granat);
}

.szp-on-fakt--czerwien {
    border-top-color: var(--szp-czerwien);
}

.szp-strona .szp-on-fakt-tytul {
    margin-bottom: 6px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: 1.7rem;
    line-height: 1.35;
    color: var(--szp-granat);
}

.szp-on-fakt-opis {
    font-size: 1.4rem;
    line-height: 1.55;
    color: var(--szp-tekst-3);
}

/* ============================================================ KARTY SZPITALI */

.szp-kr-lista {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 400px), 1fr));
    gap: 20px;
}

.szp-kr-pozycja {
    display: flex;
}

.szp-kr-karta {
    display: flex;
    flex-direction: column;
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--szp-ramka);
    border-radius: 18px;
    background: #fff;
}

.szp-kr-zdjecie {
    position: relative;
    aspect-ratio: 16 / 9;
    background: var(--szp-tlo-szare);
}

.szp-kr-zdjecie-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.szp-kr-typ {
    position: absolute;
    left: 16px;
    top: 16px;
    max-width: calc(100% - 32px);
    padding: 7px 12px;
    border-radius: 999px;
    background: #fff;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.2rem;
    line-height: 1.3;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--szp-granat);
}

.szp-kr-tresc {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: clamp(22px, 2.4vw, 30px);
}

.szp-kr-miasto {
    margin-bottom: 10px !important;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.3rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--szp-czerwien);
}

.szp-strona .szp-kr-tytul {
    margin-bottom: 12px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: 2.1rem;
    line-height: 1.3;
    color: var(--szp-granat);
    text-wrap: balance;
}

.szp-kr-opis {
    margin-bottom: 18px !important;
    font-size: 1.5rem;
    line-height: 1.6;
    color: var(--szp-tekst-3);
    text-wrap: pretty;
}

.szp-tagi {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px !important;
}

.szp-strona .szp-tagi li {
    padding: 6px 12px;
    border-radius: 999px;
    background: #F1F4F9;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.3rem;
    line-height: 1.4;
    color: var(--szp-granat);
}

.szp-kr-stopka {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 20px;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid #E6EAF2;
}

.szp-kr-dane {
    font-size: 1.4rem;
    line-height: 1.5;
    color: var(--szp-tekst-2);
}

.szp-kr-adres {
    font-style: normal;
}

.szp-strona .szp-kr-telefon {
    display: inline-block;
    padding: 4px 0;
    font-family: "Figtree-Medium", sans-serif;
    color: var(--szp-granat);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.szp-strona .szp-kr-stopka .szp-btn {
    min-height: 46px;
    padding: 0 20px;
    font-size: 1.4rem;
    white-space: nowrap;
}

/* ============================================================ NOWOCZESNA MEDYCYNA */

.szp-nw-siatka {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-auto-flow: dense;
    gap: 16px;
}

@media (min-width: 760px) {
    .szp-nw-siatka {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .szp-nw-pozycja--wyrozniony {
        grid-column: span 2;
        grid-row: span 2;
    }

    .szp-nw-siatka:not(.is-filtrowane) .szp-nw-pozycja--szeroki {
        grid-column: span 2;
    }
}

@media (min-width: 1200px) {
    .szp-nw-siatka {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

.szp-nw-pozycja {
    display: flex;
}

.szp-nw-pozycja[hidden] {
    display: none;
}

.szp-nw-karta {
    display: flex;
    flex-direction: column;
    width: 100%;
    border-radius: 18px;
}

.szp-nw-karta--zdjecie {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    justify-content: flex-end;
    min-height: 300px;
    padding: clamp(22px, 2.6vw, 36px);
    background: #0A1F45;
    color: #fff;
}

@media (min-width: 760px) {
    .szp-nw-pozycja--wyrozniony .szp-nw-karta--zdjecie {
        min-height: 560px;
    }
}

.szp-nw-tlo {
    position: absolute;
    inset: 0;
    z-index: -2;
    background-position: center;
    background-size: cover;
}

.szp-nw-cien {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(0deg, rgba(10, 31, 69, .96) 0%, rgba(10, 31, 69, .8) 45%, rgba(10, 31, 69, .2) 100%);
}

.szp-nw-karta--tekst {
    padding: clamp(22px, 2.4vw, 28px);
    background: var(--szp-tlo-jasne);
}

.szp-nw-etykiety {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px !important;
}

.szp-nw-kategoria {
    padding: 6px 12px;
    border-radius: 999px;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.2rem;
    line-height: 1.3;
    letter-spacing: .06em;
    text-transform: uppercase;
    background: var(--szp-granat);
    color: #fff;
}

.szp-nw-karta--zdjecie .szp-nw-kategoria {
    background: #fff;
    color: var(--szp-granat);
}

.szp-nw-miejsce {
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.3rem;
    line-height: 1.3;
    color: var(--szp-czerwien);
}

.szp-nw-karta--zdjecie .szp-nw-miejsce {
    padding: 5px 12px;
    border: 1px solid rgba(255, 255, 255, .6);
    border-radius: 999px;
    font-size: 1.2rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: #fff;
}

.szp-strona .szp-nw-tytul {
    margin-bottom: 10px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: 1.9rem;
    line-height: 1.3;
    color: var(--szp-granat);
    text-wrap: balance;
}

.szp-strona .szp-nw-karta--zdjecie .szp-nw-tytul {
    margin-bottom: 12px;
    font-size: 2.1rem;
    line-height: 1.15;
    color: #fff;
}

@media (min-width: 760px) {
    .szp-strona .szp-nw-pozycja--wyrozniony .szp-nw-tytul {
        font-size: clamp(2.8rem, 2.8vw, 3.8rem);
    }
}

.szp-nw-opis {
    flex: 1;
    max-width: 620px;
    margin-bottom: 18px !important;
    font-size: 1.4rem;
    line-height: 1.6;
    color: var(--szp-tekst-3);
    text-wrap: pretty;
}

.szp-nw-karta--zdjecie .szp-nw-opis {
    flex: 0 0 auto;
    font-size: 1.5rem;
    color: #D2DEF1;
}

.szp-strona .szp-nw-link {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.4rem;
    color: var(--szp-czerwien);
    text-decoration: underline;
    text-decoration-color: transparent;
    text-underline-offset: 4px;
    transition: text-decoration-color .2s ease;
}

.szp-strona .szp-nw-link:hover {
    text-decoration-color: currentColor;
}

.szp-strona .szp-nw-karta--zdjecie .szp-nw-link {
    color: #fff;
}

/* ============================================================ GDZIE LECZYMY */

.szp-mx-przewijanie {
    overflow-x: auto;
    border: 1px solid var(--szp-ramka);
    border-radius: 18px;
}

.szp-strona .szp-mx-tabela {
    width: 100%;
    min-width: 860px;
    border-collapse: collapse;
    font-size: 1.5rem;
}

.szp-strona .szp-mx-tabela th,
.szp-strona .szp-mx-tabela td {
    font-size: inherit;
    line-height: 1.4;
}

.szp-strona .szp-mx-tabela thead tr {
    background: var(--szp-tlo-jasne);
}

.szp-strona .szp-mx-tabela thead th {
    width: 13%;
    padding: 18px 12px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: 1.5rem;
    text-align: center;
    color: var(--szp-granat);
}

.szp-strona .szp-mx-tabela thead .szp-mx-obszar-naglowek {
    width: auto;
    padding: 18px 24px;
    font-size: 1.3rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    text-align: left;
    color: var(--szp-tekst-3);
}

.szp-strona .szp-mx-tabela tbody tr {
    border-top: 1px solid #E6EAF2;
}

.szp-strona .szp-mx-tabela tbody tr[hidden] {
    display: none;
}

.szp-strona .szp-mx-tabela tbody th {
    padding: 16px 24px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    text-align: left;
    color: var(--szp-granat);
}

.szp-mx-nazwa,
.szp-mx-grupa {
    display: block;
}

.szp-mx-grupa {
    margin-top: 2px;
    font-family: "Figtree-Regular", sans-serif;
    font-size: 1.3rem;
    color: var(--szp-tekst-4);
}

.szp-strona .szp-mx-tabela td {
    padding: 12px;
    text-align: center;
}

.szp-strona .szp-mx-tak {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    background: #177A4E;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.6rem;
    color: #fff;
    text-decoration: none;
    transition: background-color .2s ease;
}

.szp-strona .szp-mx-tak:hover {
    background: #0F5A39;
    color: #fff;
}

.szp-mx-nie {
    color: var(--szp-tekst-4);
}

.szp-mx-wiecej {
    margin-top: 16px;
}

.szp-mx-wiecej[hidden] {
    display: none !important;
}

.szp-przypis {
    margin-top: 16px !important;
    font-size: 1.4rem;
    line-height: 1.6;
    color: var(--szp-tekst-4);
}

/* ============================================================ STANDARDY */

.szp-st-karta {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 560px;
    padding: clamp(28px, 5vw, 64px);
    border-radius: 24px;
    background: #0A1F45;
    color: #fff;
}

.szp-st-tlo {
    position: absolute;
    inset: 0;
    z-index: -2;
    background-position: center;
    background-size: cover;
}

.szp-st-cien {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(90deg, rgba(10, 31, 69, .95) 0%, rgba(10, 31, 69, .85) 45%, rgba(10, 31, 69, .6) 100%);
}

.szp-st-siatka {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr));
    gap: clamp(32px, 5vw, 72px);
    align-items: center;
}

.szp-st-tekst {
    max-width: 620px;
}

.szp-st-tekst .szp-nadtytul {
    margin-bottom: 18px;
}

.szp-strona .szp-st-tytul {
    margin-bottom: 22px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: clamp(3.4rem, 4.2vw, 5.6rem);
    line-height: 1.05;
    letter-spacing: -.015em;
    color: #fff;
    text-wrap: balance;
}

.szp-st-lead {
    font-size: 1.7rem;
    line-height: 1.65;
    color: #D2DEF1;
    text-wrap: pretty;
}

.szp-st-wartosci {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
    gap: 16px;
}

.szp-st-wartosc {
    display: flex;
    flex-direction: column;
    min-height: 200px;
    padding: clamp(24px, 2.6vw, 34px) !important;
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 18px;
    background: rgba(10, 31, 69, .55);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
}

.szp-st-nr {
    margin-bottom: auto;
    padding-bottom: 28px;
    font-family: "Figtree-Medium", sans-serif;
    font-size: clamp(3.4rem, 3.4vw, 4.4rem);
    line-height: 1;
    color: #FF8A9B;
}

.szp-strona .szp-st-wartosc-tytul {
    margin-bottom: 8px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: 2rem;
    line-height: 1.3;
    color: #fff;
}

.szp-st-wartosc-opis {
    font-size: 1.5rem;
    line-height: 1.55;
    color: #D2DEF1;
    text-wrap: pretty;
}

/* ============================================================ LINKI DLA PACJENTA */

.szp-ln .szp-glowa {
    margin-bottom: 28px;
}

.szp-ln-lista {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
    gap: 12px;
}

.szp-strona .szp-ln-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 76px;
    height: 100%;
    padding: 18px 24px;
    border: 1px solid var(--szp-ramka);
    border-radius: 14px;
    background: #fff;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.6rem;
    line-height: 1.4;
    color: var(--szp-granat);
    text-decoration: none;
    transition: border-color .2s ease, background-color .2s ease;
}

.szp-strona .szp-ln-link:hover {
    border-color: var(--szp-granat);
    background: #F7F9FC;
    color: var(--szp-granat);
}

.szp-ln-ikona {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: #F1F4F9;
    color: var(--szp-czerwien);
}

/* ============================================================ KONTAKT */

.szp-kt {
    margin-top: var(--szp-odstep);
    padding-top: clamp(56px, 7vw, 96px);
    padding-bottom: clamp(56px, 7vw, 96px);
    color: #fff;
    background:
        radial-gradient(800px 520px at 6% 0%, rgba(37, 86, 168, .5) 0%, rgba(37, 86, 168, 0) 62%),
        radial-gradient(640px 480px at 96% 100%, rgba(200, 16, 46, .22) 0%, rgba(200, 16, 46, 0) 60%),
        linear-gradient(160deg, #123566 0%, #0E2A57 50%, #0A1F45 100%);
}

.szp-kt-siatka {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 520px), 1fr));
    gap: 40px 56px;
    align-items: start;
}

.szp-kt-mapa {
    position: relative;
}

.szp-kt-mapa svg {
    display: block;
    width: 100%;
    height: auto;
    overflow: visible;
}

.szp-kt-kontur {
    fill: rgba(255, 255, 255, .06);
    stroke: rgba(175, 196, 230, .6);
    stroke-width: 1.5;
    stroke-linejoin: round;
}

.szp-kt-punkt {
    transition: opacity .25s ease;
}

.szp-kt-punkt-halo {
    fill: rgba(255, 255, 255, .18);
    opacity: 0;
    transition: opacity .25s ease;
}

.szp-kt-punkt-kropka {
    fill: #AFC4E6;
    stroke: #fff;
    stroke-width: 2;
}

.szp-kt-punkt--szpital .szp-kt-punkt-kropka {
    fill: var(--szp-czerwien);
}

.szp-kt-punkt.is-przygaszony,
.szp-kt-podpis.is-przygaszony {
    opacity: .22;
}

.szp-kt-punkt.is-wyrozniony .szp-kt-punkt-halo {
    opacity: 1;
}

.szp-kt-podpis {
    position: absolute;
    transform: translate(0, -50%);
    font-family: "Figtree-Medium", sans-serif;
    font-size: clamp(1.2rem, 1.1vw, 1.5rem);
    line-height: 1.2;
    color: #fff;
    white-space: nowrap;
    pointer-events: none;
    text-shadow: 0 1px 6px rgba(10, 31, 69, .9);
    transition: opacity .25s ease;
}

.szp-kt-podpis--lewo {
    transform: translate(-100%, -50%);
}

.szp-kt-legenda {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 24px;
    margin-top: 16px !important;
    font-size: 1.4rem;
    line-height: 1.4;
    color: #D2DEF1;
}

.szp-strona .szp-kt-legenda li {
    display: flex;
    align-items: center;
    gap: 8px;
}

.szp-kt-legenda-znak {
    display: block;
    width: 12px;
    height: 12px;
    flex-shrink: 0;
    border: 2px solid #fff;
    border-radius: 999px;
    background: #AFC4E6;
}

.szp-kt-legenda-znak--szpital {
    width: 14px;
    height: 14px;
    background: var(--szp-czerwien);
}

.szp-strona .szp-kt-podtytul {
    margin-bottom: 16px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: 1.4rem;
    line-height: 1.4;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #AFC4E6;
}

.szp-kt-adresy-lista {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
    gap: 12px;
}

.szp-kt-szpital {
    display: flex;
    flex-direction: column;
    padding: 20px !important;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 14px;
    background: rgba(255, 255, 255, .07);
}

.szp-strona .szp-kt-szpital-miasto {
    margin-bottom: 6px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: 1.9rem;
    line-height: 1.3;
    color: #fff;
}

.szp-kt-szpital-adres {
    margin-bottom: 10px !important;
    font-style: normal;
    font-size: 1.4rem;
    line-height: 1.55;
    color: #D2DEF1;
}

.szp-strona .szp-kt-telefony a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 6px 0;
    border-top: 1px solid rgba(255, 255, 255, .14);
    color: #fff;
    text-decoration: none;
}

.szp-strona .szp-kt-telefony a:hover .szp-kt-telefon-numer {
    text-decoration: underline;
}

.szp-kt-telefon-etykieta {
    font-size: 1.3rem;
    color: #C7D6EE;
}

.szp-kt-telefon-numer {
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.4rem;
    white-space: nowrap;
}

.szp-kt-szpital-linki {
    display: flex;
    flex-wrap: wrap;
    gap: 0 16px;
    margin-top: auto !important;
    padding-top: 8px;
}

.szp-strona .szp-kt-szpital-linki a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.3rem;
    color: #fff;
    text-decoration: underline;
    text-decoration-color: rgba(255, 255, 255, .4);
    text-underline-offset: 3px;
}

.szp-strona .szp-kt-szpital-linki a:hover {
    color: #FF8A9B;
    text-decoration-color: currentColor;
}

.szp-kt-profile {
    margin-top: clamp(40px, 5vw, 64px);
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, .16);
}

.szp-strona .szp-kt-profile-tytul {
    margin-bottom: 20px;
    font-family: "Figtree-Medium", sans-serif;
    font-weight: 500;
    font-size: clamp(2.2rem, 2vw, 2.6rem);
    line-height: 1.25;
    color: #fff;
}

.szp-kt-profile-lista {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
    gap: 12px;
}

.szp-strona .szp-kt-profil {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 200px;
    height: 100%;
    padding: 24px;
    border-radius: 14px;
    background: #fff;
    color: var(--szp-granat);
    text-decoration: none;
    transition: background-color .2s ease;
}

.szp-strona a.szp-kt-profil:hover {
    background: #EEF3FA;
    color: var(--szp-granat);
}

.szp-strona .szp-kt .szp-kt-profil:focus-visible {
    outline-color: #fff;
    outline-offset: 4px;
}

.szp-kt-profil-tytul {
    font-family: "Figtree-Medium", sans-serif;
    font-size: 2.1rem;
    line-height: 1.25;
    text-wrap: balance;
}

.szp-kt-profil-miasta {
    flex: 1;
    font-size: 1.4rem;
    line-height: 1.55;
    color: var(--szp-tekst-3);
}

.szp-kt-profil-notka {
    display: block;
    margin-top: 6px;
    font-family: "Figtree-Medium", sans-serif;
    color: var(--szp-granat);
}

.szp-kt-profil-cta {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 0 16px;
    border-radius: 8px;
    background: var(--szp-granat);
    font-family: "Figtree-Medium", sans-serif;
    font-size: 1.4rem;
    color: #fff;
}

/* ============================================================ SEKCJE WSPOLNE NA TEJ STRONIE */

/*
 * Aktualnosci i FAQ to wspolne bloki motywu. Na tej stronie dostaja szerokosci
 * z projektu: tresc 1400 px (FAQ: kolumna 920 px) i te same boczne marginesy
 * co sekcje szp-*. Ich wlasny .container ma 1170 px, a .akt-placowki na telefonie
 * ujemne marginesy -15 px (zakladaja rodzica z paddingiem, ktorego tu nie ma).
 */
.szp-strona .akt-placowki {
    margin-left: 0;
    margin-right: 0;
    padding: var(--szp-odstep) 0 0;
}

.szp-strona .faq {
    padding: var(--szp-odstep) 0 clamp(64px, 8vw, 104px);
}

.szp-strona .akt-placowki > .container,
.szp-strona .faq > .container {
    width: 100%;
    max-width: calc(1400px + 2 * var(--szp-gutter));
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--szp-gutter);
    padding-right: var(--szp-gutter);
}

.szp-strona .faq .faq-inner {
    max-width: 920px;
}

/* ============================================================ PASEK MOBILNY */

.szp-pasek-mobilny {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--szp-ramka, #E1E6EF);
    background: #fff;
    box-shadow: 0 -6px 20px rgba(11, 35, 80, .08);
}

.szp-pasek-mobilny .szp-btn {
    min-height: 48px;
    padding: 0 12px;
    font-size: 1.5rem;
}

.szp-pasek-mobilny .szp-btn--czerwony { background: #C8102E; color: #fff; }
.szp-pasek-mobilny .szp-btn--granat { background: #12336B; color: #fff; }

.szp-pasek-mobilny a:focus-visible {
    outline: 3px solid #2E6BD6;
    outline-offset: 2px;
}

@media (max-width: 1199px) {
    body:has(.szp-pasek-mobilny) {
        padding-bottom: 72px;
    }

    html:has(.szp-pasek-mobilny) {
        scroll-padding-bottom: 90px;
    }
}

@media (min-width: 1200px) {
    .szp-pasek-mobilny {
        display: none;
    }
}

/* ============================================================ TRYB CIEMNY MOTYWU */

.dark .szp-strona {
    --szp-granat: #DCE6F7;
    --szp-tekst: #fff;
    --szp-tekst-2: #D2DEF1;
    --szp-tekst-3: #C3C8D8;
    --szp-tekst-4: #AEB6C8;
    --szp-ramka: rgba(255, 255, 255, .14);
    --szp-ramka-kontrolki: rgba(255, 255, 255, .55);
    --szp-tlo-jasne: #282d3d;
    --szp-tlo-szare: #343a4d;
    --szp-fokus: #8DB4FF;
    background: #1c1f2a;
}

.dark .szp-strona .szp-nadtytul { color: #FF8A9B; }
.dark .szp-strona .szp-ciemna .szp-nadtytul { color: #AFC4E6; }
.dark .szp-strona .szp-nadtytul--kreska::before { background: #FF8A9B; }

.dark .szp-kr-karta,
.dark .szp-strona .szp-ln-link,
.dark .szp-strona .szp-chip,
.dark .szp-strona .szp-btn--obrys {
    background: #282d3d;
}

.dark .szp-strona .szp-chip[aria-pressed="true"] {
    background: #DCE6F7;
    color: #12336B;
}

.dark .szp-strona .szp-tagi li,
.dark .szp-ln-ikona {
    background: #343a4d;
}

.dark .szp-strona .szp-kr-miasto,
.dark .szp-strona .szp-nw-miejsce,
.dark .szp-ln-ikona {
    color: #FF8A9B;
}

.dark .szp-strona .szp-btn--granat {
    background: #DCE6F7;
    color: #12336B;
}

.dark .szp-strona .szp-kr-typ {
    background: #1c1f2a;
    color: #fff;
}

.dark .szp-strona .szp-nw-karta--tekst .szp-nw-kategoria {
    background: #DCE6F7;
    color: #12336B;
}

.dark .szp-strona .szp-nw-karta--tekst .szp-nw-link {
    color: #FF8A9B;
}

.dark .szp-strona .szp-ln-link:hover {
    background: #343a4d;
}

/* Kafelki profili zostaja jasne na ciemnym tle sekcji - kolory na sztywno. */
.dark .szp-strona .szp-kt-profil { color: #12336B; }
.dark .szp-strona .szp-kt-profil-miasta { color: #4A5A75; }
.dark .szp-strona .szp-kt-profil-notka { color: #12336B; }
.dark .szp-strona .szp-kt-profil-cta { background: #12336B; }

/* ============================================================ PREFERENCJE UZYTKOWNIKA */

@media (prefers-reduced-motion: reduce) {
    html:has(.szp-strona) {
        scroll-behavior: auto;
    }

    .szp-strona *,
    .szp-pasek-mobilny * {
        transition: none !important;
        animation: none !important;
    }
}

@media (forced-colors: active) {
    .szp-strona .szp-chip,
    .szp-strona .szp-btn,
    .szp-strona .szp-ln-link,
    .szp-strona .szp-kt-profil,
    .szp-strona .szp-mx-tak {
        border: 2px solid ButtonText;
    }

    .szp-strona .szp-chip[aria-pressed="true"] {
        background: Highlight;
        color: HighlightText;
        forced-color-adjust: none;
    }

    .szp-hero-zdjecie,
    .szp-nw-tlo,
    .szp-st-tlo {
        display: none;
    }
}

/* ============================================================ EDYTOR */

/* Podglad bloku w edytorze jest owiniety w .szp-strona--podglad (szablony blokow). */
.szp-strona--podglad {
    padding-top: 0;
}
