/* ===== Pages de listing (/projets, /promoteurs) et fiche promoteur =====
   Ces pages utilisaient encore le gabarit brut du theme (cartes
   "homelengo-box"), d'ou un rendu "template". On reprend ici le meme
   langage visuel que le reste du site (property-card, brand.css) :
   bandeau d'en-tete colore, cartes maison, fiche promoteur avec
   couverture + avatar. */

/* ----- Bandeau d'en-tete ----- */
.listing-hero {
    position: relative;
    overflow: hidden;
    padding: 56px 0 36px;
    margin-bottom: 32px;
    background: var(--color-bordeaux);
}
.listing-hero::before,
.listing-hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.07);
}
.listing-hero::before {
    width: 320px;
    height: 320px;
    top: -160px;
    right: -60px;
}
.listing-hero::after {
    width: 180px;
    height: 180px;
    bottom: -110px;
    left: 8%;
    background: rgba(255, 255, 255, 0.05);
}
.listing-hero-inner {
    position: relative;
    z-index: 1;
}
.listing-hero-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 16px;
}
.listing-hero-breadcrumb a {
    color: rgba(255, 255, 255, 0.85);
}
.listing-hero-breadcrumb a:hover {
    color: #ffffff;
}
.listing-hero h1 {
    color: #ffffff;
    font-size: 32px;
    font-weight: 800;
    margin: 0 0 10px;
}
.listing-hero-count {
    color: rgba(255, 255, 255, 0.85);
    font-size: 15px;
    margin: 0;
}
@media (max-width: 575px) {
    .listing-hero {
        padding: 40px 0 28px;
    }
    .listing-hero h1 {
        font-size: 25px;
    }
}

/* ----- Barre d'outils (filtres actifs + tri) ----- */
.listing-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    background: #ffffff;
    border-radius: 14px;
    padding: 14px 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
    margin-bottom: 24px;
}
.listing-toolbar-filters {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}
.listing-toolbar-empty {
    font-size: 14px;
    color: #8a939b;
}
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(139, 48, 51, 0.08);
    color: var(--color-bordeaux);
    border-radius: 999px;
    padding: 7px 12px 7px 14px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    transition: background-color .15s ease;
}
.filter-chip:hover {
    background-color: rgba(139, 48, 51, 0.16);
    color: var(--color-bordeaux);
}
.filter-chip .icon {
    font-size: 10px;
}
.filter-chip-clear {
    background-color: transparent;
    color: #8a939b;
    text-decoration: underline;
    padding-left: 4px;
    padding-right: 4px;
}
.filter-chip-clear:hover {
    color: #161e2d;
}
.listing-toolbar-sort {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}
.listing-toolbar label {
    font-size: 13px;
    color: #8a939b;
    margin-right: 10px;
    white-space: nowrap;
}
.listing-toolbar select {
    border: 1px solid #e4e4e4;
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 14px;
    color: #161e2d;
    background: #ffffff;
}

/* ----- Panneau de filtres ----- */
.filter-panel {
    background: #ffffff;
    border-radius: 16px;
    padding: 26px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
}
.filter-panel-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    font-weight: 700;
    color: #161e2d;
    margin: 0 0 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid #eef0f1;
}
.filter-panel-title .icon {
    color: var(--color-bordeaux);
    font-size: 18px;
}
.filter-panel .form-style {
    margin-bottom: 14px;
}

.filter-group {
    padding-top: 18px;
    margin-top: 18px;
    border-top: 1px solid #eef0f1;
}
.filter-group:first-child {
    padding-top: 0;
    margin-top: 0;
    border-top: none;
}
.filter-group-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #8a939b;
    margin: 0 0 12px;
}
.filter-panel .ip-group.icon-left {
    position: relative;
}
.filter-panel .ip-group.icon-left input {
    padding-left: 42px;
}
.filter-panel .ip-group.icon-left > .icon {
    position: absolute;
    top: 50%;
    left: 16px;
    transform: translateY(-50%);
    font-size: 16px;
    color: #a3abb0;
    pointer-events: none;
}

/* ----- Bascule "Eligible Daam Sakan" ----- */
.daam-highlight {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 12px;
    background-color: rgba(95, 197, 190, .08);
    border: 1px solid rgba(95, 197, 190, .25);
    cursor: pointer;
    position: relative;
}
.daam-highlight-icon {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background-color: rgba(95, 197, 190, .18);
    color: var(--color-turquoise-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}
.daam-highlight-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.daam-highlight-text strong {
    font-size: 13px;
    color: #161e2d;
}
.daam-highlight-text span {
    font-size: 12px;
    color: #8a939b;
    line-height: 1.4;
}
.daam-highlight input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
}
.daam-highlight .switch-track {
    flex-shrink: 0;
    position: relative;
    width: 40px;
    height: 24px;
    border-radius: 999px;
    background-color: #d7dbe0;
    transition: background-color .2s ease;
}
.daam-highlight .switch-track::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background-color: #fff;
    box-shadow: 0 1px 3px rgba(22, 30, 45, .3);
    transition: transform .2s ease;
}
.daam-highlight input:checked ~ .switch-track {
    background-color: var(--color-turquoise-dark);
}
.daam-highlight input:checked ~ .switch-track::before {
    transform: translateX(16px);
}

/* ----- Grille de commodites ----- */
.amenities-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.amenity-chip-input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
}
.amenity-chip {
    display: block;
    text-align: center;
    padding: 9px 8px;
    border: 1px solid #e4e4e4;
    border-radius: 10px;
    font-size: 13px;
    color: #161e2d;
    cursor: pointer;
    transition: all .15s ease;
}
.amenity-chip:hover {
    background-color: var(--color-turquoise);
    border-color: var(--color-turquoise);
    color: #ffffff;
}
.amenity-chip-input:checked + .amenity-chip {
    background-color: var(--color-turquoise);
    border-color: var(--color-turquoise);
    color: #ffffff;
    font-weight: 600;
}
@media (max-width: 420px) {
    .amenities-grid {
        grid-template-columns: 1fr;
    }
}

/* ----- Cartes promoteur ----- */
.promoter-card {
    background: #ffffff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.promoter-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
}
.promoter-card-cover {
    position: relative;
    height: 118px;
    overflow: hidden;
}
.promoter-card-cover > a {
    display: block;
    height: 100%;
}
.promoter-card-cover img {
    width: 100%;
    height: 118px;
    object-fit: cover;
    display: block;
}
.promoter-card-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(22, 30, 45, 0.15);
}
.promoter-card-badges {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 6px;
    z-index: 2;
}
.promoter-card-badges span {
    background-color: var(--color-bordeaux);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
}
.promoter-card-badges span.verified {
    background-color: var(--color-turquoise-dark);
}
.promoter-card-body {
    position: relative;
    padding: 46px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
}
.promoter-card-avatar {
    position: absolute;
    top: -32px;
    left: 20px;
    width: 66px;
    height: 66px;
    border-radius: 50%;
    border: 4px solid #ffffff;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.14);
}
.promoter-card-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.promoter-card-name {
    font-size: 17px;
    font-weight: 700;
    color: #161e2d;
    margin: 0;
}
.promoter-card-name a {
    color: inherit;
}
.promoter-card-location {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #8a939b;
    margin: 0;
}
.promoter-card-location .icon {
    color: var(--color-bordeaux);
}
.promoter-card-desc {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.promoter-card-footer {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid #eef0f1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.promoter-card-footer .count {
    font-size: 13px;
    color: #8a939b;
}
.promoter-card-footer .link-view {
    font-size: 13px;
    font-weight: 700;
    color: var(--color-bordeaux);
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}
.promoter-card-footer .link-view:hover {
    color: var(--color-bordeaux-dark);
}

/* ----- Etat vide ----- */
.listing-empty {
    background: #ffffff;
    border-radius: 14px;
    padding: 60px 30px;
    text-align: center;
    color: #6b7280;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
}

/* ----- Fiche promoteur : en-tete couverture + avatar ----- */
.promoter-hero {
    margin-bottom: 40px;
}
.promoter-hero-cover {
    position: relative;
    height: 220px;
    border-radius: 20px;
    overflow: hidden;
}
.promoter-hero-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.promoter-hero-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(22, 30, 45, 0.35);
}
.promoter-hero-card {
    position: relative;
    z-index: 1;
    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 10px 36px rgba(0, 0, 0, 0.1);
    margin: -60px 28px 0;
    padding: 22px 26px 24px 150px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    min-height: 108px;
}
.promoter-hero-avatar {
    position: absolute;
    left: 26px;
    top: -38px;
    width: 108px;
    height: 108px;
    border-radius: 50%;
    border: 5px solid #ffffff;
    background: #ffffff;
    overflow: hidden;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.16);
}
.promoter-hero-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.promoter-hero-badges {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
}
.promoter-hero-info h1 {
    font-size: 25px;
    font-weight: 800;
    color: #161e2d;
    margin: 0 0 8px;
}
.promoter-hero-location {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #6b7280;
    font-size: 14px;
    margin: 0 0 8px;
}
.promoter-hero-location .icon {
    color: var(--color-bordeaux);
}
.promoter-hero-desc {
    color: #6b7280;
    font-size: 14px;
    max-width: 560px;
    margin: 0;
}
.promoter-hero-stats {
    display: flex;
    gap: 30px;
    flex-shrink: 0;
}
.promoter-hero-stats .stat {
    text-align: center;
}
.promoter-hero-stats .stat .num {
    display: block;
    font-size: 24px;
    font-weight: 800;
    color: var(--color-bordeaux);
    line-height: 1.2;
}
.promoter-hero-stats .stat .label {
    font-size: 12px;
    color: #8a939b;
}
@media (max-width: 767px) {
    .promoter-hero-cover {
        height: 150px;
        border-radius: 14px;
    }
    .promoter-hero-card {
        margin: -46px 14px 0;
        padding: 60px 20px 22px;
        flex-direction: column;
        align-items: flex-start;
    }
    .promoter-hero-avatar {
        left: 20px;
        top: -34px;
        width: 84px;
        height: 84px;
    }
    .promoter-hero-stats {
        gap: 24px;
    }
}
