/*
 * EM5 UI consistency layer.
 * Small cross-page rules shared by the modernized views.
 */

.about-history-breadcrumb,
.office-location-breadcrumb,
.agent-profile-breadcrumb,
.team-breadcrumb,
.property-offer-breadcrumb,
.services-modern-breadcrumb,
.career-breadcrumb,
.blog-breadcrumb,
.service-detail-breadcrumb,
.special-project-breadcrumb,
.opinion-breadcrumb,
.em5-breadcrumb {
    font-size: .8rem !important;
    line-height: 1.5;
}

.em5-breadcrumb {
    color: #6d7379;
}

.em5-breadcrumb .breadcrumb {
    --bs-breadcrumb-margin-bottom: 0;
    font-size: inherit;
}

.em5-breadcrumb .breadcrumb-item,
.em5-breadcrumb .breadcrumb-item a {
    color: inherit;
}

.em5-breadcrumb .breadcrumb-item a {
    text-decoration: none;
}

.em5-breadcrumb .breadcrumb-item a:hover {
    color: #b72619;
}

/* Hub „Wyjątkowe nieruchomości”: taki sam rytm kart jak 4-kolumnowe sekcje homepage. */
@media (min-width: 1200px) {
    .special-curated__grid > .col-xl-3 {
        width: 25%;
    }
}

.special-curated__footer .btn {
    min-height: 42px;
}

/*
 * Homepage section headings.
 * One shared visual hierarchy for offers, reviews, blog, local market and offices.
 */
.home-section-heading {
    max-width: 760px;
    margin: 0 0 1.75rem;
}

.home-section-kicker {
    margin-bottom: .6rem;
    color: #b72619;
    font-size: .76rem;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: .09em;
    text-transform: uppercase;
}

.home-section-heading h2 {
    max-width: 720px;
    margin: 0;
    color: #20252b;
    font-size: clamp(1.7rem, 2.35vw, 2.5rem);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -.025em;
    white-space: normal;
}

.home-section-block {
    padding-top: 2.5rem;
}

.home-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 1.75rem;
}

.home-section-head .home-section-heading {
    margin-bottom: 0;
}

.home-section-cta {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: .55rem 0;
    border: 0;
    border-bottom: 1px solid rgba(183, 38, 25, .30);
    border-radius: 0;
    background: transparent;
    color: #b72619;
    font-size: .86rem;
    font-weight: 750;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    transition: color .18s ease, border-color .18s ease, transform .18s ease;
}

.home-section-cta:hover,
.home-section-cta:focus-visible {
    border-color: #20252b;
    background: transparent;
    color: #20252b;
    transform: translateX(2px);
}

/* Office section uses its own legacy text-link class: align it with the same homepage CTA language. */
.home-offices__all-link {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: .55rem 0;
    border-bottom: 1px solid rgba(183, 38, 25, .30);
    color: #b72619;
    font-size: .86rem;
    font-weight: 750;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    transition: color .18s ease, border-color .18s ease, transform .18s ease;
}

.home-offices__all-link:hover,
.home-offices__all-link:focus-visible {
    border-color: #20252b;
    color: #20252b;
    transform: translateX(2px);
}

@media (max-width: 767.98px) {
    .home-section-heading {
        margin-bottom: 1.2rem;
    }

    .home-section-head {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: end;
        gap: .8rem;
        margin-bottom: 1.2rem;
    }

    .home-section-head .home-section-heading {
        margin-bottom: 0;
    }

    .home-section-cta {
        min-height: 44px;
        padding: .25rem 0;
        border: 0;
        border-bottom: 0;
        border-radius: 0;
        background: transparent;
        color: #b72619;
        font-size: .8rem;
        line-height: 1.25;
        white-space: nowrap;
    }

    .home-section-cta:hover,
    .home-section-cta:focus-visible {
        border-color: transparent;
        background: transparent;
        color: #20252b;
        transform: none;
    }

    .home-offices__all-link {
        padding: .25rem 0;
        border-bottom: 0;
        font-size: .8rem;
    }

    .home-offices__all-link:hover,
    .home-offices__all-link:focus-visible {
        transform: none;
    }

    .home-section-block {
        padding-top: 2rem;
    }
}

@media (max-width: 420px) {
    .home-section-head {
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        gap: .35rem;
    }

    .home-section-cta {
        justify-content: flex-start;
        width: fit-content;
    }
}

/* The office header is part of a flex row and should not add its own bottom margin. */
.home-offices__heading.home-section-heading {
    margin-bottom: 0;
}

/*
 * Curated offers: labels describe facts visible in the offer.
 * Recommendation is editorial, media labels come from actual offer media.
 */
.special-curated-offer__badges .special-curated-offer__badge {
    border-color: #dedede;
    background: #fff;
    color: #50555a;
}

.special-curated-offer__badges .special-curated-offer__badge--recommended {
    border-color: rgba(183, 38, 25, .22);
    background: #fff3f1;
    color: #b72619;
}

.special-curated-offer__badges .special-curated-offer__badge--new {
    border-color: rgba(183, 38, 25, .16);
    background: #fff;
    color: #b72619;
}

.special-curated-offer__badges .special-curated-offer__badge--media {
    border-color: #dcdedb;
    background: #f5f5f3;
    color: #4d5358;
}

/* Same compact CTA rhythm on special-project landings and the contact form. */
.special-project-actions .btn,
.contact-modern-form .btn {
    min-height: 42px;
    line-height: 1.25;
}

/*
 * Homepage neighborhoods: the name itself remains the SEO landing link.
 * The arrow is deliberately subtle – no additional competing CTA.
 */
.home-neighborhood-link {
    display: inline-flex;
    align-items: center;
    gap: .42rem;
    color: #20252b;
    text-decoration: none;
    transition: color .18s ease;
}

.home-neighborhood-link__arrow {
    color: #b72619;
    font-size: .9em;
    opacity: .42;
    transform: translateX(0);
    transition: opacity .18s ease, transform .18s ease;
}

.home-neighborhood-link:hover,
.home-neighborhood-link:focus-visible {
    color: #b72619;
}

.home-neighborhood-link:hover .home-neighborhood-link__arrow,
.home-neighborhood-link:focus-visible .home-neighborhood-link__arrow {
    opacity: 1;
    transform: translateX(3px);
}

/*
 * Offer contact: before interaction render only the reveal action.
 * The telephone itself is hidden with the native `hidden` attribute, so no
 * part of a long number can leak out or wrap behind an overlay.
 */
.property-offer-sidebar .offer-phone-reveal {
    min-height: 42px;
    display: flex;
    align-items: center;
}

.property-offer-sidebar .offer-phone-reveal__button,
.property-offer-sidebar .offer-phone-reveal__number {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    max-width: 100%;
    min-height: 38px;
    padding: .3rem 0;
    border: 0;
    background: transparent;
    color: #b72619;
    font-size: .93rem;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
}

.property-offer-sidebar .offer-phone-reveal__button {
    cursor: pointer;
}

.property-offer-sidebar .offer-phone-reveal__button:hover,
.property-offer-sidebar .offer-phone-reveal__button:focus-visible,
.property-offer-sidebar .offer-phone-reveal__number:hover,
.property-offer-sidebar .offer-phone-reveal__number:focus-visible {
    color: #8f1d14;
    text-decoration: none;
}

.property-offer-sidebar .offer-phone-reveal__button[hidden],
.property-offer-sidebar .offer-phone-reveal__number[hidden] {
    display: none !important;
}

/* v57 — lżejszy, krótszy footer; na mobile sekcje działają jak natywny accordion. */
.footer-modern {
    position: relative;
    margin-top: clamp(3.5rem, 7vw, 6.5rem);
    padding: clamp(2.2rem, 4.5vw, 4.4rem) 0 0;
    border-top: 1px solid #e4e2de;
    color: #252a30;
}

.footer-modern__brand-row {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    justify-content: space-between;
    padding-bottom: clamp(1.6rem, 3vw, 2.5rem);
    border-bottom: 1px solid #e3e1dc;
}

.footer-modern__logo-link,
.footer-modern__logo {
    display: block;
}

.footer-modern__logo-link {
    width: fit-content;
}

.footer-modern__logo {
    width: auto;
    height: 42px;
}

.footer-modern__brand-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.footer-modern__contact-link {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    padding: .35rem .15rem;
    color: #b72619;
    font-size: .86rem;
    font-weight: 750;
    text-decoration: none;
}

.footer-modern__contact-link:hover,
.footer-modern__contact-link:focus-visible {
    color: #252a30;
}

.footer-modern .footer-social-link {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border: 1px solid #dedbd5;
    border-radius: 50%;
    background: rgba(255, 255, 255, .7);
}

.footer-modern .footer-social-icon {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

.footer-modern__grid {
    display: grid;
    grid-template-columns: 1.05fr 1.25fr 1.05fr 1.35fr .75fr;
    gap: clamp(1.5rem, 3.5vw, 3.5rem);
    padding: clamp(2rem, 4vw, 3.6rem) 0;
}

.footer-modern__group {
    min-width: 0;
}

.footer-modern__group > summary {
    margin: 0 0 1rem;
    color: #272c31;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .075em;
    line-height: 1.35;
    list-style: none;
    text-transform: uppercase;
}

.footer-modern__group > summary::-webkit-details-marker {
    display: none;
}

.footer-modern__group > summary::marker {
    content: '';
}

.footer-modern__links {
    margin: 0;
}

.footer-modern__links li + li {
    margin-top: .48rem;
}

.footer-modern__links a {
    display: inline-block;
    color: #666b70;
    font-size: .78rem;
    font-weight: 500;
    line-height: 1.45;
    text-decoration: none;
    transition: color .18s ease, transform .18s ease;
}

.footer-modern__links a:hover,
.footer-modern__links a:focus-visible {
    color: #b72619;
    transform: translateX(2px);
}

.footer-modern__trust-row {
    display: flex;
    gap: 1.25rem 2rem;
    align-items: center;
    padding: 1.2rem 0;
    border-top: 1px solid #e3e1dc;
}

.footer-modern__trust-label {
    flex: 0 0 auto;
    color: #777c80;
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .075em;
    text-transform: uppercase;
}

.footer-modern .footer-memberships__logo {
    max-width: 104px;
    max-height: 42px;
}

.footer-modern__bottom {
    display: flex;
    gap: 1rem 2rem;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 0 1.7rem;
    border-top: 1px solid #e3e1dc;
    color: #85898d;
    font-size: .7rem;
    line-height: 1.5;
}

.footer-modern__bottom a {
    color: inherit;
    text-decoration: none;
}

.footer-modern__bottom a:hover,
.footer-modern__bottom a:focus-visible {
    color: #b72619;
}

.footer-modern__separator {
    display: inline-block;
    margin: 0 .35rem;
}

@media (min-width: 768px) {
    .footer-modern__group > summary {
        pointer-events: none;
        cursor: default;
    }
}

@media (max-width: 991.98px) and (min-width: 768px) {
    .footer-modern__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .footer-modern__group--services {
        grid-column: span 2;
    }
}

@media (max-width: 767.98px) {
    .footer-modern {
        margin-top: 3.25rem;
        padding-top: 1.65rem;
    }

    .footer-modern__brand-row {
        padding-bottom: 1.25rem;
    }

    .footer-modern__logo {
        height: 34px;
    }

    .footer-modern__contact-link {
        display: none;
    }

    .footer-modern .footer-social-link {
        width: 38px;
        height: 38px;
    }

    .footer-modern__grid {
        display: block;
        padding: .45rem 0 0;
    }

    .footer-modern__group {
        border-bottom: 1px solid #e3e1dc;
    }

    .footer-modern__group > summary {
        position: relative;
        display: flex;
        min-height: 54px;
        align-items: center;
        justify-content: space-between;
        margin: 0;
        padding: .75rem 2.1rem .75rem 0;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    .footer-modern__group > summary::after {
        position: absolute;
        top: 50%;
        right: .15rem;
        content: '+';
        color: #9a9d9f;
        font-size: 1.2rem;
        font-weight: 400;
        line-height: 1;
        transform: translateY(-50%);
    }

    .footer-modern__group[open] > summary::after {
        content: '−';
        color: #b72619;
    }

    .footer-modern__group > summary:focus-visible {
        outline: 2px solid rgba(183, 38, 25, .28);
        outline-offset: -2px;
    }

    .footer-modern__panel {
        padding: 0 0 1rem;
    }

    .footer-modern__links {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
        padding-right: 1.5rem;
    }

    .footer-modern__links li + li {
        margin-top: 0;
    }

    .footer-modern__links a {
        display: flex;
        min-height: 38px;
        align-items: center;
        padding: .32rem 0;
        font-size: .79rem;
    }

    .footer-modern__links a:hover,
    .footer-modern__links a:focus-visible {
        transform: none;
    }

    .footer-modern__trust-row {
        display: grid;
        gap: .85rem;
        padding: 1.25rem 0;
    }

    .footer-modern .footer-memberships {
        gap: 1rem !important;
    }

    .footer-modern .footer-memberships__logo {
        max-width: 92px;
        max-height: 38px;
    }

    .footer-modern__bottom {
        display: grid;
        gap: .45rem;
        justify-content: stretch;
        padding: 1.15rem 0 1.5rem;
        font-size: .67rem;
    }
}

/* v58 — telefon agenta: na ofercie pokazujemy prefiks + pierwsze 3 cyfry, pełny numer dopiero po akcji. */
.property-offer-sidebar .offer-phone-reveal__button {
    gap: .52rem;
}

.property-offer-sidebar .offer-phone-reveal__preview {
    color: #252a30;
    font-weight: 700;
    letter-spacing: .01em;
}

.property-offer-sidebar .offer-phone-reveal__label {
    color: #b72619;
    font-size: .8rem;
    font-weight: 700;
}

.property-offer-sidebar .offer-phone-reveal__button:hover .offer-phone-reveal__preview,
.property-offer-sidebar .offer-phone-reveal__button:focus-visible .offer-phone-reveal__preview {
    color: #252a30;
}

.property-offer-sidebar .offer-phone-reveal__button:hover .offer-phone-reveal__label,
.property-offer-sidebar .offer-phone-reveal__button:focus-visible .offer-phone-reveal__label {
    color: #8f1d14;
}

/* v58 — desktop footer: bardziej zwarty układ bez pięciu rzadkich, wysokich kolumn. */
@media (min-width: 992px) {
    .footer-modern {
        margin-top: clamp(3.25rem, 5vw, 5rem);
        padding-top: 2.35rem;
    }

    .footer-modern__brand-row {
        padding-bottom: 1.55rem;
    }

    .footer-modern__grid {
        grid-template-columns: minmax(210px, 1.05fr) minmax(210px, 1fr) minmax(390px, 1.75fr) minmax(120px, .6fr);
        grid-template-areas:
            'offices properties services em5'
            'special  properties services em5';
        column-gap: clamp(2rem, 4vw, 4.5rem);
        row-gap: 1.55rem;
        align-items: start;
        padding: 2rem 0 2.2rem;
    }

    .footer-modern__group--offices { grid-area: offices; }
    .footer-modern__group--special { grid-area: special; }
    .footer-modern__group--properties { grid-area: properties; }
    .footer-modern__group--services { grid-area: services; }
    .footer-modern__group--em5 { grid-area: em5; }

    .footer-modern__group > summary {
        margin-bottom: .7rem;
    }

    .footer-modern__links li + li {
        margin-top: .34rem;
    }

    .footer-modern__links a {
        font-size: .76rem;
        line-height: 1.4;
    }

    .footer-modern__group--services .footer-modern__links {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: .34rem 1.7rem;
    }

    .footer-modern__group--services .footer-modern__links li + li {
        margin-top: 0;
    }

    .footer-modern__trust-row {
        padding: 1rem 0;
    }

    .footer-modern__bottom {
        padding: 1rem 0 1.35rem;
    }
}

/* v59 — finalny polish desktopowego footera i maski telefonu w ofercie. */
.property-offer-sidebar .offer-phone-reveal__button {
    gap: .38rem;
    font-weight: 600;
}

.property-offer-sidebar .offer-phone-reveal__preview {
    color: #30343a;
    font-variant-numeric: tabular-nums;
    letter-spacing: .005em;
}

.property-offer-sidebar .offer-phone-reveal__preview > span {
    color: #9a9da0;
    letter-spacing: .08em;
}

.property-offer-sidebar .offer-phone-reveal__separator {
    color: #b8b8b5;
    font-weight: 400;
}

.property-offer-sidebar .offer-phone-reveal__label {
    color: #b72619;
    font-weight: 700;
}

@media (min-width: 992px) and (max-width: 1199.98px) {
    .footer-modern__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        grid-template-areas:
            'offices special properties'
            'services services em5';
        gap: 1.5rem 2rem;
        padding: 1.5rem 0 1.7rem;
    }

    .footer-modern__group--offices { grid-area: offices; }
    .footer-modern__group--special { grid-area: special; }
    .footer-modern__group--properties { grid-area: properties; }
    .footer-modern__group--services { grid-area: services; }
    .footer-modern__group--em5 { grid-area: em5; }
}

@media (min-width: 1200px) {
    .footer-modern {
        margin-top: clamp(3rem, 5vw, 4.5rem);
        padding-top: 2rem;
    }

    .footer-modern__brand-row {
        padding-bottom: 1.35rem;
    }

    .footer-modern__logo {
        height: 38px;
    }

    .footer-modern__grid {
        grid-template-columns: 1.05fr 1.12fr 1fr 1.85fr .58fr;
        grid-template-areas: none;
        gap: clamp(1.6rem, 2.6vw, 2.8rem);
        align-items: start;
        padding: 1.55rem 0 1.7rem;
    }

    .footer-modern__group--offices,
    .footer-modern__group--special,
    .footer-modern__group--properties,
    .footer-modern__group--services,
    .footer-modern__group--em5 {
        grid-area: auto;
        grid-row: 1;
    }

    .footer-modern__group--offices { grid-column: 1; }
    .footer-modern__group--special { grid-column: 2; }
    .footer-modern__group--properties { grid-column: 3; }
    .footer-modern__group--services { grid-column: 4; }
    .footer-modern__group--em5 { grid-column: 5; }

    .footer-modern__group > summary {
        margin-bottom: .72rem;
    }

    .footer-modern__links li + li {
        margin-top: .34rem;
    }

    .footer-modern__links a {
        font-size: .76rem;
        line-height: 1.38;
    }

    .footer-modern__group--services .footer-modern__links {
        display: block;
        columns: 2;
        column-gap: 2rem;
    }

    .footer-modern__group--services .footer-modern__links li,
    .footer-modern__group--services .footer-modern__links li + li {
        break-inside: avoid;
        margin: 0 0 .34rem;
    }

    .footer-modern__trust-row {
        padding: .95rem 0;
    }

    .footer-modern .footer-memberships__logo {
        max-width: 96px;
        max-height: 38px;
    }

    .footer-modern__bottom {
        padding: .9rem 0 1.2rem;
    }
}

