@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

/* ==========================================================================
   Design System & Variables
   ========================================================================== */
:root {
    --font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    --dark: #090d16;
    --dark-muted: #1e293b;
    --accent: #1e40af;
    --accent-hover: #1d4ed8;
    --surface: #ffffff;
    --bg: #f8fafc;
    --border: #e2e8f0;
    --text: #0f172a;
    --text-muted: #64748b;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --shadow-soft: 0 10px 25px -5px rgba(15, 23, 42, 0.04), 0 8px 10px -6px rgba(15, 23, 42, 0.03);
    --shadow-hover: 0 20px 30px -10px rgba(15, 23, 42, 0.12);
}

/* Reset & Base */
*, *::before, *::after { 
    box-sizing: border-box; 
}

/* Empêche TOUT défilement et débordement fantôme vers la droite */
html, body {
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

/* Force les paragraphes du Hero à ne jamais couper les apostrophes */
.hero-lead, 
.hero-lead * {
    white-space: normal;
    word-break: normal !important;
    overflow-wrap: break-word !important;
    hyphens: none !important;
    -webkit-hyphens: none !important;
    text-align: center !important;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font);
    background-color: var(--bg);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    line-height: 1.5;
}

.wrap {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.15s ease;
}

a:hover {
    color: var(--accent-hover);
}

/* ==========================================================================
   En-tête (Header) & Navigation globale
   ========================================================================== */
/* 1. On garde une barre fine */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    /* S'assurer que le débordement n'est pas masqué */
    overflow: visible; 
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 76px;           /* La barre garde une hauteur élégante et compacte */
    position: relative;
}

/* 2. On ancre le logo en haut et on le laisse descendre */
.site-logo {
    display: flex;
    align-items: flex-start; /* Aligné en haut pour ne jamais déborder vers le plafond */
    padding-top: 8px;        /* Petite marge de respiration sous le haut de l'écran */
    z-index: 10;
}

.site-logo span {
    color: var(--accent);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 28px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-nav a {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-muted);
    transition: color 0.15s ease;
}

.main-nav a:hover,
.main-nav .is-active a {
    color: var(--text);
}

.nav-btn {
    background: var(--dark);
    color: #fff !important;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.15s ease;
}

.nav-btn:hover {
    background: var(--dark-muted);
}

/* ==========================================================================
   Page d'accueil (Hero, Contact rapide, Courtières)
   ========================================================================== */
.hero-banner {
    position: relative;
    min-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    padding: 100px 24px;
    color: #fff;
    text-align: center;
}

.hero-banner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(15, 23, 42, 0.45) 0%, rgba(9, 13, 22, 0.85) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 820px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.hero-content h1 {
    font-size: clamp(2.4rem, 5vw, 3.8rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin: 0 0 20px 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-lead {
    font-size: clamp(1.05rem, 2vw, 1.35rem);
    color: rgba(255, 255, 255, 0.9);
    margin: 0 auto 36px auto;
    max-width: 680px;
    width: 100%;
    font-weight: 400;
    text-align: center;
    box-sizing: border-box;
}

/* Neutralise les marges parasites injectées par l'éditeur de texte riche de ProcessWire */
.hero-lead p {
    margin: 0 0 10px 0;
    padding: 0;
    text-align: center;
    word-break: normal;
    overflow-wrap: break-word;
    hyphens: manual;
    -webkit-hyphens: manual;
    text-wrap: pretty; /* Équilibre le paragraphe sans mot orphelin */
}

.btn-hero {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #ffffff;
    color: var(--dark) !important;
    font-weight: 700;
    font-size: 1.05rem;
    padding: 16px 34px;
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-hero:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

/* Bandeau Contact Rapide */
.quick-contact-bar {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 18px 0;
}

.contact-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.contact-label {
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.contact-links {
    display: flex;
    gap: 12px;
}

.contact-pill {
    background: var(--bg);
    color: var(--text);
    padding: 8px 18px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid var(--border);
    transition: background 0.15s, border-color 0.15s;
}

.contact-pill:hover {
    background: #e2e8f0;
    border-color: #cbd5e1;
}

/* Sections communes de la Home */
.home-section {
    padding: 80px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
}

.section-header h2 {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0 0 6px 0;
}

.section-header .subtitle {
    margin: 0;
    color: var(--text-muted);
    font-size: 1.05rem;
}

.link-all {
    font-weight: 700;
    font-size: 1rem;
}

/* Courtières */
.courtiers-grille {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
}

.carte-courtier {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    text-align: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.carte-courtier:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.courtier-photo {
    height: 320px;
    background: var(--dark);
    overflow: hidden;
}

.courtier-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transition: transform 0.4s ease;
}

.carte-courtier:hover .courtier-photo img {
    transform: scale(1.04);
}

.courtier-info {
    padding: 20px;
}

.courtier-info h3 {
    margin: 0 0 6px 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
}

.courtier-role {
    margin: 0;
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 600;
}

/* ==========================================================================
   Catalogue / Liste des biens (biens.php)
   ========================================================================== */
.catalogue-wrapper {
    max-width: 1240px;
    margin: 0 auto;
    padding: 40px 24px 80px;
}

.catalogue-header h1 {
    font-size: 2.3rem;
    font-weight: 800;
    letter-spacing: -0.025em;
    margin: 0 0 6px 0;
}

.catalogue-header p {
    color: var(--text-muted);
    font-size: 1rem;
    margin: 0 0 30px 0;
}

/* ==========================================================================
   BARRE DE RECHERCHE IMMOBILIÈRE MODERNE
   ========================================================================== */
.search-panel {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.02);
    padding: 16px 22px;
    margin-bottom: 45px;
}

.search-panel-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr) auto;
    align-items: center;
    gap: 12px;
}

/* Chaque bloc de filtre */
.search-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-right: 12px;
    border-right: 1px solid #f1f5f9;
}

.search-field .field-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
}

/* Habillage sur-mesure du select */
.select-wrap {
    position: relative;
}

.select-wrap select {
    appearance: none;
    -webkit-appearance: none;
    width: 100%;
    background: transparent;
    border: none;
    padding: 4px 22px 4px 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #0f172a;
    cursor: pointer;
    outline: none;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

/* Flèche chevron personnalisée fine */
.select-wrap::after {
    content: '';
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    width: 7px;
    height: 7px;
    border-right: 2px solid #94a3b8;
    border-bottom: 2px solid #94a3b8;
    transform: translateY(-70%) rotate(45deg);
    pointer-events: none;
}

/* Boutons */
.search-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-left: 6px;
}

.btn-search {
    background: var(--accent, #0284c7);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 12px 20px;
    font-size: 0.95rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-search:hover {
    background: #0369a1;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.25);
}

.btn-clear {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background: #f1f5f9;
    color: #64748b;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 700;
    transition: all 0.15s ease;
}

.btn-clear:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.btn-primary {
    background: var(--dark);
    color: #fff !important;
    border: none;
    padding: 11px 22px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
}

.btn-primary:hover {
    background: var(--dark-muted);
}

.btn-secondary {
    background: var(--bg);
    color: var(--text-muted) !important;
    border: 1px solid var(--border);
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-secondary:hover {
    background: #e2e8f0;
    color: var(--text) !important;
}

/* Grille des biens */
.grille-biens {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 32px;
}

.carte-bien {
    background: var(--surface);
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.carte-bien:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
}

.vignette-container {
    position: relative;
    height: 230px;
    background: var(--dark);
    overflow: hidden;
    display: block;
}

.vignette-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.carte-bien:hover .vignette-container img {
    transform: scale(1.05);
}

.badge-transaction {
    position: absolute;
    top: 14px;
    left: 14px;
    background: rgba(9, 13, 22, 0.75);
    backdrop-filter: blur(8px);
    color: #fff;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    z-index: 2;
}

.badge-statut-pill {
    position: absolute;
    top: 14px;
    right: 14px;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #fff;
    z-index: 2;
}

.badge-statut-reserve { background: #ea580c; }
.badge-statut-vendu   { background: #475569; }

.carte-contenu {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.carte-contenu h2 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 8px 0;
    line-height: 1.35;
}

.carte-contenu h2 a {
    color: var(--text);
}

.localisation {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0 0 10px 0;
}

.specs {
    color: #475569;
    font-size: 0.95rem;
    font-weight: 500;
    margin: 0 0 18px 0;
}

.carte-footer {
    border-top: 1px solid var(--border);
    padding-top: 16px;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.prix {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text);
    letter-spacing: -0.02em;
}

/* Pagination */
.pagination {
    margin-top: 50px;
    display: flex;
    justify-content: center;
}

.pagination ul {
    display: flex;
    list-style: none;
    padding: 0;
    gap: 8px;
}

.pagination li a,
.pagination li span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: #fff;
    color: var(--text);
    font-weight: 600;
    font-size: 0.95rem;
}

.pagination li.uk-active span,
.pagination li.MarkupPagerNavOn span {
    background: var(--dark);
    color: #fff;
    border-color: var(--dark);
}

/* ==========================================================================
   Fiche détaillée (bien.php) & Formulaire de contact
   ========================================================================== */
.fiche-bien {
    max-width: 1060px;
    margin: 0 auto;
    padding: 40px 24px 80px;
    box-sizing: border-box;
    width: 100%;
}

.fiche-bien .bien-header {
    margin-bottom: 30px;
}

.fiche-bien h1 {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 800;
    line-height: 1.15;
    margin: 10px 0 8px 0;
    letter-spacing: -0.02em;
}

.fiche-bien .prix-principal {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text);
    margin-top: 14px;
}

.galerie-grille {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
    margin-bottom: 40px;
}

.galerie-grille a {
    display: block;
    height: 200px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

.galerie-grille img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.galerie-grille a:hover img {
    transform: scale(1.05);
}

.bien-specs {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 24px 30px;
    margin-bottom: 40px;
    box-shadow: var(--shadow-soft);
}

.bien-specs h2 {
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin: 0 0 14px 0;
}

.specs-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 36px;
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 1.2rem;
}

.specs-pills li strong {
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 600;
}

.bien-contact {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 36px;
    box-shadow: var(--shadow-soft);
    margin-top: 50px;
}

.bien-contact h2 {
    font-size: 1.6rem;
    font-weight: 800;
    margin-top: 0;
    margin-bottom: 6px;
}

.bien-contact form input,
.bien-contact form select,
.bien-contact form textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: #fff;
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.bien-contact form input:focus,
.bien-contact form select:focus,
.bien-contact form textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.15);
}

/* ==========================================================================
   Pied de page (Footer)
   ========================================================================== */
.site-footer {
    background: var(--dark);
    color: #94a3b8;
    padding: 70px 0 35px;
    margin-top: 80px;
    border-top: 1px solid var(--dark-muted);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 50px;
}

.footer-col h4 {
    color: #fff;
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 18px 0;
}

.footer-col p {
    line-height: 1.6;
    margin: 0 0 12px 0;
}

.footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-col li {
    margin-bottom: 10px;
}

.footer-col a {
    color: #94a3b8;
}

.footer-col a:hover {
    color: #fff;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    flex-wrap: wrap;
    gap: 12px;
}

/* Responsive */
@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .header-inner {
        height: 64px;
    }
    .main-nav {
        gap: 14px;
    }
}

.site-logo-img {
    height: 88px;
    width: auto;
    display: block;
    /* Ombre portée subtile pour détacher le logo qui flotte sur le fond */
    filter: drop-shadow(0 8px 12px rgba(0, 0, 0, 0.12));
    transition: transform 0.2s ease;
}

.site-logo-img:hover {
    transform: translateY(2px);
}

/* Détails contact courtières (Lignes 3 et 4) */
.courtier-contact-details {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.courtier-contact-item {
    margin: 0;
    font-size: 0.88rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.courtier-contact-item .icon {
    font-size: 0.95rem;
}

.courtier-contact-item a {
    color: var(--text);
    font-weight: 500;
    transition: color 0.15s ease;
}

.courtier-contact-item a:hover {
    color: var(--accent);
}

/* ==========================================================================
   OPTIMISATIONS MOBILE & MENU BURGER
   ========================================================================== */

/* Bouton Hamburger masqué sur grand écran */
.nav-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 110;
}

.nav-toggle span {
    display: block;
    width: 26px;
    height: 3px;
    background-color: var(--dark, #090d16);
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle span + span {
    margin-top: 5px;
}

/* Animation en croix quand le menu est ouvert */
.nav-toggle.is-active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.nav-toggle.is-active span:nth-child(2) {
    opacity: 0;
}
.nav-toggle.is-active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* --------------------------------------------------------------------------
   Écrans mobiles et tablettes (<= 768px)
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
    
    /* 1. Logo & Barre */
    .header-inner {
        height: 70px;
        min-height: 70px;
    }

    .site-logo-img {
        height: 64px; /* Un peu plus compact sur petit écran pour éviter les décalages */
    }

    /* 2. Menu en tiroir déroulant */
    .nav-toggle {
        display: block;
    }

    .main-nav-wrapper {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: #ffffff;
        border-bottom: 1px solid var(--border);
        box-shadow: 0 15px 25px rgba(0, 0, 0, 0.08);
        padding: 24px;
        display: none;
        flex-direction: column;
        z-index: 99;
    }

    .main-nav-wrapper.nav-open {
        display: flex;
    }

    .main-nav {
        flex-direction: column;
        align-items: flex-start;
        gap: 18px;
        width: 100%;
    }

    .main-nav li {
        width: 100%;
    }

    .main-nav a {
        font-size: 1.15rem;
        display: block;
        padding: 6px 0;
    }

    .nav-action-item {
        margin-top: 10px;
        padding-top: 16px;
        border-top: 1px solid var(--border);
    }

    .nav-action-item .nav-btn {
        display: block;
        text-align: center;
        width: 100%;
        padding: 12px;
        font-size: 1rem;
    }

     /* Hero Container Mobile */
    .hero-banner {
        min-height: auto;
        padding: 60px 16px 50px;
        overflow: hidden; /* Empêche tout débordement horizontal */
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .hero-content {
        width: 100%;
        max-width: 100%;
        margin: 0 auto;
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center; /* Force tous les enfants à rester parfaitement au milieu */
    }

    /* Titre sans coupure de mots */
    .hero-banner h1 {
        font-size: clamp(1.65rem, 5.5vw, 2.1rem);
        line-height: 1.2;
        letter-spacing: -0.01em;
        margin: 0 0 14px 0;
        width: 100%;
        text-align: center;
        hyphens: manual;
        -webkit-hyphens: manual;
        word-break: keep-all;
        overflow-wrap: normal;
        text-wrap: balance;
    }

    /* Sous-titre centré sans déborder */
    .hero-lead {
        font-size: 0.95rem;
        line-height: 1.5;
        margin: 0 auto 24px auto;
        padding: 0 8px;
        width: 100%;
        max-width: 100%;
        text-align: center;
    }

    .hero-lead p {
        margin: 0;
        text-align: center;
        hyphens: manual;
        -webkit-hyphens: manual;
    }

    .btn-hero {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
        font-size: 1rem;
    }

    /* 4. Bandeau Contact & Formulaire */
    .contact-bar-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .contact-links {
        width: 100%;
        flex-direction: column;
        gap: 8px;
    }

    .contact-pill {
        display: block;
        text-align: center;
    }

    .grille-biens,
    .courtiers-grille {
        grid-template-columns: 1fr; /* Une seule colonne propre sur smartphone */
        gap: 20px;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    /* Fiche détaillée du bien sur mobile */
    .fiche-bien {
        padding: 24px 18px 60px !important; /* Marge nette de 18px à gauche et à droite */
        box-sizing: border-box !important;
        width: 100% !important;
    }

    /* Évite que le titre touche les bords */
    .fiche-bien h1 {
        font-size: 1.75rem;
        line-height: 1.25;
        margin-bottom: 12px;
        word-break: normal;
        overflow-wrap: break-word;
    }

    /* Encadré des caractéristiques (pièces, surface, etc.) */
    .bien-specs {
        padding: 18px 16px !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
    }

    .specs-pills {
        gap: 16px 24px !important;
    }

    /* Bloc contact du bien */
    .bien-contact {
        padding: 24px 18px !important;
        box-sizing: border-box !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    /* Galerie sur la fiche bien */
    .fiche-bien .galerie-grille {
        grid-template-columns: 1fr; /* Une photo par ligne sur smartphone */
        gap: 14px;
        margin-left: 0;
        margin-right: 0;
    }

    .fiche-bien .galerie-grille a {
        height: 240px; /* Belle hauteur pour visualiser les pièces */
    }

    .filtres-bar {
        grid-template-columns: 1fr;
    }

    .search-panel-grid {
        grid-template-columns: 1fr;
    }
}

/* --------------------------------------------------------------------------
   RESPONSIVE : TABLETTE 
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
    .search-panel-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .search-field {
        border-right: none;
        border-bottom: 1px solid #f1f5f9;
        padding-bottom: 8px;
        padding-right: 0;
    }

    .search-actions {
        grid-column: 1 / -1;
        padding-left: 0;
        margin-top: 6px;
    }

    .btn-search {
        flex: 1;
        justify-content: center;
        padding: 14px;
    }
}