/**
 * Layout public – espacement header / contenu
 * Utilisé par layouts.base (site public)
 */
.home-section-header-layout .public-content-wrapper {
    padding-top: 58px;
}

@media (max-width: 991.98px) {
    .home-section-header-layout.home-section-header-layout--search .public-content-wrapper {
        padding-top: 132px;
    }

    body.has-home-services-app-bar .public-content-wrapper {
        padding-bottom: calc(4.25rem + env(safe-area-inset-bottom, 0px));
    }

    body.has-home-services-app-bar .footer {
        margin-bottom: calc(4.25rem + env(safe-area-inset-bottom, 0px));
    }

    /* Klaro cookie banner — au-dessus de la barre de navigation services */
    body.has-home-services-app-bar .klaro .cookie-notice {
        bottom: calc(4.25rem + env(safe-area-inset-bottom, 0px));
        z-index: 1065;
    }
}

/* Klaro — toujours au-dessus de la barre services mobile (z-index 1025) */
.klaro .cookie-notice,
.klaro .cookie-modal {
    z-index: 1065;
}

.home-section-toolbar {
    z-index: 1030;
}

.home-section-toolbar__inner {
    min-height: 58px;
}

.home-section-toolbar__title {
    font-size: 1.125rem;
    font-weight: 400;
    line-height: 1.2;
}

.home-section-toolbar__back,
.home-section-toolbar__menu,
.home-section-toolbar__actions {
    flex: 0 0 auto;
}

.home-section-toolbar__actions {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.home-section-toolbar__back {
    display: inline-flex;
    align-items: center;
}

.home-section-toolbar__back-icon {
    font-family: inherit;
    font-size: 1.35rem;
    font-weight: 400;
    line-height: 1;
}

.home-section-toolbar__menu {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 36px;
    padding: 0.35rem 0.55rem;
}

.home-section-toolbar__search .search-bar-container {
    position: relative;
    width: 100%;
}

.home-section-toolbar__search .search-bar {
    width: 100%;
    border-radius: 12px;
    border: 1px solid #ddd;
    padding: 10px 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    font-size: 0.95rem;
    background-color: #fff;
    cursor: pointer;
}

.home-section-toolbar__search .search-bar.search-bar--with-filter {
    padding-left: 48px;
}

.home-section-toolbar__search .search-bar:focus {
    border-color: #ddd;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    outline: none;
}

.home-section-toolbar__search .filter-btn {
    position: absolute;
    top: 50%;
    left: 6px;
    transform: translateY(-50%);
    z-index: 2;
    width: 34px;
    height: 34px;
    padding: 0;
    background-color: #f0151f;
    border: none;
    color: #fff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.home-section-desktop-heading {
    margin-top: 0.25rem;
}

.home-section-desktop-heading__title {
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 1.2;
}

.home-section-desktop-heading__back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 999px;
    transition: background-color 0.15s ease;
}

.home-section-desktop-heading__back-icon {
    font-family: inherit;
    font-size: 1.35rem;
    font-weight: 400;
    line-height: 1;
}

.home-section-desktop-heading__back:hover {
    background-color: rgba(15, 23, 42, 0.06);
}

/* Overlay recherche sections (responsive) */
.custom-overlay--section-search {
    background: #fff;
}

.home-section-toolbar__search .search-bar:not(.search-bar--with-filter) {
    padding-left: 1rem;
}

.section-search-overlay__header {
    display: grid;
    grid-template-columns: 2.75rem 1fr 2.75rem;
    align-items: center;
    gap: 0.5rem;
    min-height: 58px;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e9ecef;
    background: #fff;
    position: sticky;
    top: 0;
    z-index: 2;
}

.section-search-overlay__back {
    width: 2.75rem;
    height: 2.75rem;
    border: 1.5px solid #f0151f;
    border-radius: 10px;
    background: #fff;
    color: #f0151f;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.section-search-overlay__title {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 700;
    text-align: center;
    color: #212529;
    line-height: 1.2;
}

.section-search-overlay__header-spacer {
    width: 2.75rem;
}

.section-search-overlay__body {
    padding: 1rem;
    overflow-y: auto;
    height: calc(100% - 58px);
}

.section-search-overlay__field {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
}

.section-search-overlay__input {
    flex: 1 1 auto;
    min-width: 0;
    height: 3rem;
    border: 1px solid #212529;
    border-radius: 999px;
    padding: 0 1.15rem;
    font-size: 1rem;
    color: #212529;
    background: #fff;
}

.section-search-overlay__input::placeholder {
    color: #adb5bd;
}

.section-search-overlay__input:focus {
    outline: none;
    border-color: #212529;
    box-shadow: none;
}

.section-search-overlay__submit {
    flex-shrink: 0;
    width: 3rem;
    height: 3rem;
    border: none;
    border-radius: 999px;
    background: #f0151f;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.section-search-overlay__submit:hover,
.section-search-overlay__submit:focus {
    background: #b01017;
    color: #fff;
}

.section-search-overlay__loader {
    position: absolute;
    right: 3.75rem;
    color: #f0151f;
}

.section-search-overlay--loading .section-search-overlay__body {
    pointer-events: none;
}

.section-search-overlay--loading .section-search-overlay__input {
    opacity: 0.85;
}

.search-autocomplete--loading {
    pointer-events: none;
}

.search-autocomplete--loading .search-bar-btn .search-icon {
    pointer-events: none;
}

.section-search-overlay__suggestions {
    margin-top: 0.75rem;
    max-height: calc(100vh - 12rem);
    overflow-y: auto;
}

.section-search-overlay__suggestions .autocomplete-item {
    margin: 0;
    box-shadow: none;
    border-radius: 0;
}

.payment-header-layout .public-content-wrapper {
    padding-top: 88px;
}

@media (min-width: 992px) {
    .home-section-header-layout .public-content-wrapper {
        padding-top: 0;
    }

    .has-main-header .public-content-wrapper:not(.home-page) {
        padding-top: 120px;
    }

    .has-main-header .public-content-wrapper:not(.home-page) .container.pt-5,
    .has-main-header .public-content-wrapper:not(.home-page) .container.my-5.pt-5 {
        padding-top: 0 !important;
    }

    .has-main-header .public-content-wrapper:not(.home-page) .container.pt-3 {
        padding-top: 0 !important;
    }

    .has-main-header.annex-page .public-content-wrapper:not(.home-page) {
        padding-top: 40px;
    }

    .payment-header-layout .public-content-wrapper {
        padding-top: 80px;
    }
}
