/* Ustawienia podstawowe */


* {
    box-sizing: border-box;

}


*,
*::before,
*::after {
    box-sizing: border-box;
}


:root {
    --primary: #347f84;
    --primary-dark: #286e73;
    --text: #171717;
    --white: #ffffff;
}


html {
    scroll-behavior: smooth;
}


@media (prefers-reduced-motion: no-preference) {

    html {
        interpolate-size: allow-keywords;
    }

}


body {
    margin: 0;

    /*font-family: "Inter", sans-serif !important;*/


    color: var(--text);
    background: var(--white);
}


button,
a {
    -webkit-tap-highlight-color: transparent;
}


a:focus-visible,
button:focus-visible {
    outline: 3px solid #f2b544;
    outline-offset: 3px;
}


/* Shared keyboard skip link. Keep it above the fixed site header. */


.skip-link {
    position: fixed;
    top: max(8px, env(safe-area-inset-top, 0px));
    left: max(16px, env(safe-area-inset-left, 0px));
    z-index: 1200;
    box-sizing: border-box;
    max-width: calc(100vw - max(16px, env(safe-area-inset-left, 0px)) - max(16px, env(safe-area-inset-right, 0px)));
    padding: 12px 20px;
    color: #174b50;
    background: #fbfdfc;
    transform: translateY(-200%);
}


.skip-link:focus {
    transform: none;
    color: #174b50;
}


/* #3 and #4: sticky, independently styled homepage header and disclosure.
   The document's later typography stylesheet has global anchor rules, so every
   interactive navbar state is explicitly component-scoped here. */


:root {
    --nav-teal: #286e73;
    --nav-teal-dark: #175358;
    --nav-ink: #17383c;
    --header-height: 10rem;
    /* No-JS reserve clears the tested 320px header; navbar.js measures the live height. */
}


html {
    scroll-padding-top: calc(var(--header-height) + 0.75rem);
}


/* A sticky element may exit its containing block at the page bottom. A fixed
   header stays present across the entire document; body padding below replaces
   the removed normal-flow height using ResizeObserver's measured value. */


/* Accesibility section - sekcja przyjazna pacjenta */


/* Dostępność i komfort pacjentów */


/* =========================================
   DOSTĘPNOŚĆ — WERSJA TEKSTOWA
   Zachowujemy turkusowo-białą kolorystykę
========================================= */


.accessibility {
    --accessibility-ink: #17383c;
    --accessibility-muted: #4b5d5f;
    --accessibility-line: #d9e8e7;
    width: 100%;
    padding: clamp(36px, 5vw, 68px) 20px clamp(16px, 2vw, 24px);
    background: #f3f8f7;
    color: var(--text, #263638);
}


.accessibility__inner {
    width: 100%;
    max-width: 1180px;
    margin-inline: auto;
}


.accessibility__header {
    max-width: 820px;
    margin: 0 auto 20px;

}


.accessibility__title {
    margin: 0 auto 12px;
    color: var(--accessibility-ink);


}


.accessibility__lead {
    max-width: 720px;
    margin: 0 auto;
    color: var(--accessibility-muted);


}


.accessibility__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
    gap: 14px;
}


.accessibility-card {
    min-width: 0;
    padding: 20px;
    border: 1px solid var(--accessibility-line);
    border-radius: 15px;
    background: var(--white, #fff);
    box-shadow: 0 4px 16px rgba(23, 56, 60, 0.045);
}


.accessibility-card h3 {
    margin: 0 0 8px;
    color: var(--accessibility-ink);


}


.accessibility-card p {
    margin: 0;
    color: var(--accessibility-muted);


}


@media (max-width: 599px) {

    .accessibility {
        padding: 32px 16px 16px;
    }


    .accessibility__header {
        margin-bottom: 22px;
    }


    .accessibility__lead,
    .accessibility-card p {}


    .accessibility__grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
    }


    .accessibility-card {
        padding: 18px;
        border-radius: 12px;
    }

}


/* Tablety */


@media (min-width: 900px) {

    .medical-services__grid {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }


    .medical-service-card {
        grid-column: span 3;
    }


    .medical-service-card--featured {
        grid-column: 2 / span 4;
    }

}


/* Telefony */


@media (max-width: 599px) {

    .medical-services {
        padding: 34px 16px;
    }


    .medical-services__header {
        margin-bottom: 24px;

    }


    .medical-services__eyebrow {}


    .medical-services__intro,
    .medical-service-card p,
    .medical-services__note p {

        /*line-height: 1.75;*/
    }


    .medical-services__grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }


    .medical-service-card,
    .medical-service-card--featured {
        grid-column: auto;
        padding: 22px;
    }


    .medical-services__note {
        padding: 18px;
    }

}


@media (prefers-reduced-motion: reduce) {

    .medical-service-card__link {
        transition: none;
    }


    .medical-service-card__link:hover {
        transform: none;
    }

}


/* Treść poniżej pierwszego ekranu */


.page-content {
    padding: 32px 20px;

}


/* B46: Even a normal-height phone or tablet can have a taller-than-screen
   navbar at 400% root text. Cap only widths up to 1100px, preserving the
   native accessible vertical scrollport for complete controls and brand. */


/* 
███████╗ ██████╗  ██████╗ ████████╗███████╗██████╗ 
██╔════╝██╔═══██╗██╔═══██╗╚══██╔══╝██╔════╝██╔══██╗
█████╗  ██║   ██║██║   ██║   ██║   █████╗  ██████╔╝
██╔══╝  ██║   ██║██║   ██║   ██║   ██╔══╝  ██╔══██╗
██║     ╚██████╔╝╚██████╔╝   ██║   ███████╗██║  ██║
╚═╝      ╚═════╝  ╚═════╝    ╚═╝   ╚══════╝╚═╝  ╚═╝ */


/* ========================================
   STOPKA — PRZYCHODNIA LINIEWO
======================================== */


.site-footer {
    --footer-bg: #252b2d;
    --footer-text: #e1e8e8;
    --footer-muted: #aebcbd;
    --footer-accent: #83c6c7;
    --footer-divider: #465154;

    width: 100%;
    background: var(--footer-bg);
    color: var(--footer-text);


}


.site-footer *,
.site-footer *::before,
.site-footer *::after {
    box-sizing: border-box;
}


.site-footer__inner {
    /* Keep the two information columns aligned with the three link columns below. */
    --footer-column-gap: 28px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-areas: "brand info info" "links links links" "bottom bottom bottom";
    gap: 16px var(--footer-column-gap);
    width: 100%;
    max-width: 1200px;
    margin-inline: auto;
    padding: 24px 24px 16px;
}


/* Marka */


.site-footer__brand {
    grid-area: brand;
    display: flex;
    align-items: center;
    gap: 12px;
    align-self: start;
    margin: 0;
}

.site-footer .site-footer__brand-link {
    justify-self: start;
    text-decoration: none;
}

.site-footer .site-footer__brand-link:hover h2 {
    text-decoration: underline;
    text-underline-offset: 0.18em;
}

.site-footer .site-footer__brand-link:focus-visible {
    outline: 3px solid #f2b544;
    outline-offset: 4px;
}


.site-footer__brand-icon {
    --brand-mark-size: 52px;

    border-radius: 12px;
}


.site-footer__brand-text h2 {
    margin: 0 0 3px;
    color: #fff;


}


.site-footer__brand-text p {
    margin: 0;
    color: #c7d7d7;

}


/* Separatory */


.site-footer__divider {
    display: none;
    /* Decorative separators must not occupy full grid rows. */
}


/* Kontakt i godziny */


.site-footer__info {
    grid-area: info;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px clamp(24px, 4vw, 56px);
}


.site-footer__column {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
}


.site-footer__column h3 {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 0 0 10px;
    color: #fff;


}


.site-footer__icon {
    display: inline-flex;
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    color: var(--footer-accent);
}


.site-footer__icon svg {
    width: 100%;
    height: 100%;
}


.site-footer__column p {
    margin: 0;
    color: var(--footer-text);

}


.site-footer__column a {
    color: var(--footer-text);
    text-decoration: none;

    transition: color 0.2s ease;
}


.site-footer__column a:hover {
    color: var(--footer-accent);
}


/* Przydatne informacje */


.site-footer__links {
    grid-area: links;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
}


.site-footer__links>a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 0;
    color: var(--footer-text);
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    transition: color 0.2s ease;
}


.site-footer__links>a:last-child {
    border-bottom: 0;
}


.site-footer__links>a:hover {
    color: var(--footer-accent);
}


.site-footer__arrow {
    color: var(--footer-accent);


}


/* Prawa autorskie i branding */


.site-footer__bottom {
    grid-area: bottom;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px 24px;
    margin: 0;
    padding-top: 12px;
    border-top: 0;
}


.site-footer__copyright {
    margin: 0;
    color: var(--footer-muted);

}


.site-footer__branding {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px 12px;
}


.site-footer__branding-label {
    color: var(--footer-muted);

}


.site-footer__branding-partners {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px 20px;
}


.site-footer .site-footer__branding-logo {
    color: var(--footer-text);


}


.site-footer .site-footer__branding-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    max-width: 180px;
    text-decoration: none;
}


.site-footer .site-footer__branding-logo[href]:hover {
    color: var(--footer-accent);
}


.site-footer__branding-logo img {
    display: block;
    flex: none;
    width: 28px;
    height: 32px;
    padding: 4px;
    border-radius: 6px;
    background: #f4f8f5;
    object-fit: contain;
}


.site-footer a:focus-visible {
    outline: 2px solid var(--footer-accent);
    outline-offset: 4px;
    border-radius: 2px;
}


/* Two-column information and link lists on tablets; single column on phones. */


@media (max-width: 800px) {

    .site-footer__inner {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas: "brand" "info" "links" "bottom";
        gap: 14px;
        padding: 22px 20px 16px;
    }


    .site-footer__info {
        gap: 16px;
    }


    .site-footer__bottom {
        flex-direction: column;

    }


    .site-footer__brand-text h2 {}

}


/* Małe telefony */


@media (max-width: 380px) {

    .site-footer__inner {
        padding-inline: 16px;
    }


    .site-footer__brand-icon {
        --brand-mark-size: 54px;
    }


    .site-footer__brand-text h2 {}


    .site-footer__info {
        gap: 12px;
    }


    .site-footer {}


    .site-footer__column h3 {}

}


/* Ograniczenie animacji zgodnie z ustawieniami użytkownika */


@media (prefers-reduced-motion: reduce) {

    .site-footer a {
        transition: none;
    }

}


/* 
███████╗██████╗ ███████╗ ██████╗██╗ █████╗ ██╗  ████████╗██╗███████╗███████╗
██╔════╝██╔══██╗██╔════╝██╔════╝██║██╔══██╗██║  ╚══██╔══╝██║██╔════╝██╔════╝
███████╗██████╔╝█████╗  ██║     ██║███████║██║     ██║   ██║█████╗  ███████╗
╚════██║██╔═══╝ ██╔══╝  ██║     ██║██╔══██║██║     ██║   ██║██╔══╝  ╚════██║
███████║██║     ███████╗╚██████╗██║██║  ██║███████╗██║   ██║███████╗███████║
╚══════╝╚═╝     ╚══════╝ ╚═════╝╚═╝╚═╝  ╚═╝╚══════╝╚═╝   ╚═╝╚══════╝╚══════╝
                                                                             */


/* 
 █████╗ ███╗   ██╗██╗███╗   ███╗ █████╗ ████████╗██╗ ██████╗ ███╗   ██╗███████╗
██╔══██╗████╗  ██║██║████╗ ████║██╔══██╗╚══██╔══╝██║██╔═══██╗████╗  ██║██╔════╝
███████║██╔██╗ ██║██║██╔████╔██║███████║   ██║   ██║██║   ██║██╔██╗ ██║███████╗
██╔══██║██║╚██╗██║██║██║╚██╔╝██║██╔══██║   ██║   ██║██║   ██║██║╚██╗██║╚════██║
██║  ██║██║ ╚████║██║██║ ╚═╝ ██║██║  ██║   ██║   ██║╚██████╔╝██║ ╚████║███████║
╚═╝  ╚═╝╚═╝  ╚═══╝╚═╝╚═╝     ╚═╝╚═╝  ╚═╝   ╚═╝   ╚═╝ ╚═════╝ ╚═╝  ╚═══╝╚══════╝
                                                                                */


/* B47B: shared footer information grid, including transparent pending legal status. */


.site-footer__list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0 var(--footer-column-gap);
    list-style: none;
    padding: 0;
    margin: 0;
}


.site-footer__entry {
    min-width: 0;
    border-bottom: 1px solid rgba(255, 255, 255, .12);
}


.site-footer__entry>a,
.site-footer__pending {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .75rem;
    padding: .42rem 0;
    min-width: 0;
    color: var(--footer-text);
    text-decoration: none;
}


.site-footer__entry>a {
    min-height: 44px;
    align-items: center;
}


.site-footer__entry>a:hover {
    color: var(--footer-accent);
    text-decoration: underline;
}


.site-footer__pending {
    flex-wrap: wrap;
}


.site-footer__status {
    color: var(--footer-muted);
}


.site-footer__hours-status {
    color: var(--footer-muted);
}


.site-footer__entry a:focus-visible {
    outline: 2px solid var(--footer-accent);
    outline-offset: 3px;
}


@media (max-width:800px) {
    .site-footer__list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}


@media (max-width:550px) {

    .site-footer__info,
    .site-footer__list {
        grid-template-columns: minmax(0, 1fr);
    }
}


/* At 400% root text, long Polish words in flex children must contribute
   break opportunities to the intrinsic min-content width (320px phones). */


.site-footer :is(h2, h3, p, a, li, span) {
    min-width: 0;
}


/* Programy — autorskie przyciski wektorowe przygotowane z dostarczonych PDF-ów. */


/* Przycisk Moje Zdrowie — te same ustawienia marginesów i wyrównania
   co przycisk Moja Rodzina. */
.pricing-ui__category--health .program-art-button--health {
    margin-left: 0;
    margin-right: auto;
    justify-self: start;
    align-self: start;
}


.program-art-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    max-width: 100%;
    margin-top: 1.15rem;
    margin-left: auto;
    border-radius: 8px;

    vertical-align: middle;
    transition: transform 180ms ease, filter 180ms ease;
}


.program-art-button img {
    display: block;
    width: clamp(132px, 22vw, 176px);
    max-width: 100%;
    height: auto;
}


.program-art-button:hover {
    transform: translateY(-2px);
    filter: drop-shadow(0 5px 9px rgba(13, 55, 91, .2));
}


.program-art-button:focus-visible {
    outline: 3px solid #f2b544;
    outline-offset: 5px;
}


@media (prefers-reduced-motion: reduce) {

    .program-art-button {
        transition: none;
    }


    .program-art-button:hover {
        transform: none;
    }

}


/* =========================================
   LOGO PRZYCHODNI — STOPKA
   ========================================= */


.site-footer .site-footer__brand-avatar {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;

    width: 52px;
    height: 52px;
    min-width: 52px;
    flex: 0 0 52px;

    object-fit: contain;
    object-position: center;

    background: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 12px;
}


/* =========================================
   LOGO PRZYCHODNI — NAWIGACJA
   ========================================= */


.brand .brand-avatar {
    display: block;
    width: 64px;
    height: 64px;
    flex: 0 0 64px;
    object-fit: contain;
    object-position: center;

    background: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 12px;
    box-sizing: border-box;
}

/* Przycisk programu „Moja Rodzina” wyrównany do lewej,
   tak jak przycisk w sekcji „Moje Zdrowie”. */
.program-art-button--family {
    margin-left: 0;
    margin-right: auto;
    justify-self: start;
    align-self: start;
}

/* Footer partner marks: equal icon sizing and matching labels. */
.site-footer__branding-partners {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px 22px;
}

.site-footer .site-footer__branding-logo {
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    min-height: 44px;
    max-width: none;
    color: #fff;
    text-decoration: none;
}

.site-footer .site-footer__branding-logo:hover,
.site-footer .site-footer__branding-logo:focus-visible {
    color: #fff;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.site-footer .site-footer__branding-logo img {
    display: block;
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    padding: 3px;
    border-radius: 8px;
    object-fit: contain;
}

.site-footer .site-footer__branding-logo--branding img {
    background: #0C3A5C;
}

.site-footer .site-footer__branding-logo:not(.site-footer__branding-logo--branding) img {
    background: #f5faf8;
}

.site-footer .site-footer__branding-logo span {
    display: inline-block;
    color: #fff;
    white-space: nowrap;
}

@media (max-width: 420px) {
    .site-footer__branding-partners {
        gap: 10px 16px;
    }

    .site-footer .site-footer__branding-logo {
        gap: 7px;
    }

    .site-footer .site-footer__branding-logo img {
        flex-basis: 34px;
        width: 34px;
        height: 34px;
    }
}


/* Branding Studio partner link mirrors the Kodaworm logo + name treatment. */
.site-footer .site-footer__branding-logo--branding {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    max-width: 180px;
    color: #fff;
    text-decoration: none;
}

.site-footer .site-footer__branding-logo--branding img {
    display: block;
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    padding: 3px;
    border-radius: 8px;
    background: #0C3A5C;
    object-fit: contain;
}

.site-footer .site-footer__branding-logo--branding span {
    display: inline-block;
    color: #fff;
    white-space: nowrap;
}

.site-footer .site-footer__branding-logo--branding:hover {
    color: var(--footer-accent);
}

@media (max-width: 420px) {
    .site-footer .site-footer__branding-logo--branding {
        gap: 7px;
    }

    .site-footer .site-footer__branding-logo--branding img {
        flex-basis: 34px;
        width: 34px;
        height: 34px;
    }
}


/* ========================================
   SZYBKIE USŁUGI DLA PACJENTÓW
======================================== */


/* Floating patient quick-links panel — CTA sizing and footer anchoring. */
.patient-services {
    position: fixed;
    right: clamp(12px, 5.6vw, 94px);
    bottom: 24px;
    z-index: 1000;
    display: grid;
    gap: 8px;
    width: 220px;
}

.patient-services[hidden] {
    display: none;
}

/* When the footer enters the viewport, the panel follows its top edge
   and keeps the same breathing room instead of covering footer content. */
.patient-services.is-footer-anchored {
    bottom: var(--patient-services-footer-bottom, 24px);
}

.patient-services__title {
    grid-column: 1 / -1;
    color: #174b50;
    font-weight: 700;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.patient-services a {
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 12px 16px;
    box-sizing: border-box;
    border-radius: 8px;
    color: #fff;
    background: #347f84;
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.25;
    text-decoration: none;
    transition: background-color 160ms ease;
}

.patient-services a:hover {
    background: #286e73;
}

.patient-services a:focus-visible {
    outline: 3px solid #f2b544;
    outline-offset: 3px;
}

@media (max-width: 760px) {
    .patient-services {
        right: 10px;
        bottom: 16px;
        width: min(190px, calc(100vw - 20px));
        gap: 7px;
    }

    .patient-services a {
        min-height: 46px;
        padding: 11px 14px;
        font-size: 15px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .patient-services a {
        transition: none;
    }
}

/* Patient panel: switch to a content-width CTA row when its right edge
   reaches the centered content boundary. */
.patient-services.is-horizontal {
    left: var(--patient-services-content-left, 12px);
    right: var(--patient-services-content-right, 12px);
    width: auto;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.patient-services.is-horizontal a {
    justify-content: center;
    text-align: center;
    min-width: 0;
    overflow-wrap: anywhere;
}

/* Keep a clear viewport band beneath the horizontal panel while the page
   scrolls. The panel itself sits above this layer; footer anchoring disables it. */
body::after {
    content: "";
    position: fixed;
    inset: auto 0 0;
    height: var(--patient-services-reserve, 0px);
    background: transparent;
    pointer-events: none;
    z-index: 999;
}

/* Only the horizontal layout gets the opaque clearance band. */
body:has(.patient-services.is-horizontal)::after {
    background: var(--white);
}

body:has(.patient-services.is-footer-anchored)::after {
    display: none;
}

main {
    padding-bottom: var(--patient-services-reserve, 0px);
}

@media (max-width: 760px) {
    .patient-services.is-horizontal {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
    }
}


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