/* ============================================================
   modern-skin.css — Refonte visuelle moderne (claude 2026-05-14)
   À charger APRÈS style.css, SIT_FASILAIMMO_style.css et responsive.css
   Override visuel uniquement, le HTML reste inchangé.

   Palette :
     bg          : #f5f6f8
     accent      : #2eaadc (brand cyan)
     accent-dk   : #1d8db9
     text        : #1f2937
     text-muted  : #6b7280
     card        : #ffffff
     border      : #e5e7eb
     footer-bg   : #111827
   ============================================================ */

/* ---------- Base ---------- */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
    background: #f5f6f8 !important;
    color: #1f2937 !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    -webkit-font-smoothing: antialiased;
}

p { line-height: 1.55 !important; color: #1f2937 !important; }
strong { color: inherit; }

a, a:visited {
    color: #1d8db9 !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    transition: color 0.15s ease;
}
a:hover {
    color: #145d7d !important;
    text-decoration: underline !important;
}

/* ---------- Headings ---------- */
h1 {
    font-size: 1.6em !important;
    font-weight: 700 !important;
    color: #fff !important;
    background: transparent !important;
    letter-spacing: -0.01em !important;
    margin: 0 !important;
    padding: 12px 0 !important;
}
h2 {
    background: transparent !important;
    color: #1f2937 !important;
    font-size: 1.15em !important;
    font-weight: 700 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    border-left: 4px solid #2eaadc !important;
    padding: 4px 0 4px 12px !important;
    margin: 0 0 16px 0 !important;
}
h3, .h3 {
    color: #1f2937 !important;
    font-weight: 700 !important;
    font-size: 1.05em !important;
    margin: 0 0 12px 0 !important;
    padding: 0 !important;
}
h4 {
    color: #1f2937 !important;
    font-weight: 600 !important;
    font-size: 0.95em !important;
}

/* ---------- Header (logo + recherche) ---------- */
#conteneur {
    background: #ffffff !important;
    box-shadow: 0 0 0 1px #e5e7eb;
    margin: 0 auto !important;
}
#header {
    background: #0f172a !important;
    height: auto !important;
    min-height: 100px;
    padding: 18px 32px !important;
    border-bottom: none !important;
    box-sizing: border-box;
    position: relative;
}
#header img {
    max-height: 64px;
    width: auto !important;
    height: auto !important;
}
#header h1 {
    color: #cbd5e1 !important;
    font-size: 13px !important;
    font-weight: 400 !important;
    padding: 4px 0 0 0 !important;
    letter-spacing: 0 !important;
    line-height: 1.4 !important;
    background: transparent !important;
}
#recherche {
    position: absolute !important;
    right: 32px;
    top: 26px;
}
#recherche form {
    display: flex;
    gap: 0;
    align-items: stretch;
}
#recherche input.search_string,
#recherche input[type=text] {
    border: 1px solid #d1d5db !important;
    border-radius: 8px 0 0 8px !important;
    padding: 8px 14px !important;
    font-size: 14px !important;
    width: 260px !important;
    height: 38px !important;
    box-sizing: border-box;
    background: #fff !important;
    color: #1f2937 !important;
    outline: none;
}
#recherche input.search_string:focus {
    border-color: #2eaadc !important;
    box-shadow: 0 0 0 3px rgba(46,170,220,0.15);
}
#recherche input.search_valider,
#recherche input[type=submit] {
    border: 1px solid #2eaadc !important;
    border-left: none !important;
    background: #2eaadc !important;
    color: #fff !important;
    border-radius: 0 8px 8px 0 !important;
    padding: 0 16px !important;
    font-weight: 600 !important;
    cursor: pointer;
    height: 38px !important;
    font-size: 13px !important;
}
#recherche input.search_valider:hover {
    background: #1d8db9 !important;
}

/* ---------- Backgrounds décoratifs neutralisés ---------- */
#backgroundheader,
#backgroundmenu {
    background: transparent !important;
    height: auto !important;
}

/* ---------- Menu haut (#haut / #menuhaut) — DESKTOP only ---------- */
@media screen and (min-width: 769px) {
    #haut {
        background: #1f2937 !important;
        height: auto !important;
        width: 100% !important;
        padding: 0 !important;
        text-transform: none !important;
    }
    #menuhaut {
        padding: 0 24px !important;
        margin: 0 !important;
        display: flex;
        gap: 4px;
        flex-wrap: wrap;
        font-size: 13px !important;
    }
    #menuhaut li {
        display: inline-block !important;
        list-style: none !important;
        margin: 0 !important;
        background-image: none !important;
    }
    #menuhaut a {
        display: block !important;
        color: #e5e7eb !important;
        padding: 12px 16px !important;
        margin: 0 !important;
        font-weight: 500 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.04em !important;
        font-size: 12px !important;
        line-height: 1 !important;
        border-radius: 0 !important;
    }
    #menuhaut a:hover {
        background: #2eaadc !important;
        color: #fff !important;
        text-decoration: none !important;
    }
}

/* ---------- Menu tétière (catégories) — DESKTOP only ---------- */
@media screen and (min-width: 769px) {
    #menu_tetiere {
        background: #fff !important;
        height: auto !important;
        width: 100% !important;
        padding: 0 24px !important;
        border-bottom: 1px solid #e5e7eb !important;
        box-shadow: 0 1px 2px rgba(0,0,0,0.03);
        box-sizing: border-box;
    }
}
@media screen and (min-width: 769px) {
    #menu_tetiere > ul {
        padding: 0 !important;
        margin: 0 !important;
        list-style: none !important;
        display: flex;
        flex-wrap: wrap;
        gap: 2px;
        text-transform: none !important;
    }
    #menu_tetiere > ul > li,
    #menu_tetiere ul li:first-child,
    #menu_tetiere ul li:nth-child(2),
    #menu_tetiere ul li:nth-child(3),
    #menu_tetiere ul li:nth-child(6),
    #menu_tetiere ul li:nth-child(7),
    #menu_tetiere ul li:nth-child(8),
    #menu_tetiere ul li:nth-child(9),
    #menu_tetiere ul li:nth-child(10),
    #menu_tetiere ul li:nth-child(11) {
        display: inline-block !important;
        float: none !important;
        background-image: none !important;
        background: transparent !important;
        line-height: 1 !important;
        margin: 0 !important;
        padding: 0 !important;
        position: relative;
    }
    #menu_tetiere > ul > li > a {
        display: inline-block !important;
        float: none !important;
        color: #1f2937 !important;
        padding: 14px 14px !important;
        margin: 0 !important;
        font-weight: 600 !important;
        font-size: 13px !important;
        text-transform: uppercase !important;
        letter-spacing: 0.02em;
        border-radius: 6px;
        transition: background 0.15s ease, color 0.15s ease;
        line-height: 1 !important;
        height: auto !important;
    }
    #menu_tetiere > ul > li > a:hover {
        background: #f3f4f6 !important;
        color: #2eaadc !important;
        text-decoration: none !important;
    }
}
/* Sous-menu déroulant (table) : caché par défaut, visible au hover */
#menu_tetiere > ul > li > table {
    display: none !important;
    z-index: 100;
    border-collapse: collapse;
    position: absolute;
    top: 100%;
    left: 0;
}
#menu_tetiere > ul > li:hover > table {
    display: table !important;
}
#menu_tetiere > ul > li > table > tbody > tr > td {
    background: #fff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 8px;
    padding: 8px !important;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    min-width: 180px;
}
#menu_tetiere > ul > li > table ul {
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
}
#menu_tetiere > ul > li > table ul li {
    background-image: none !important;
    padding: 0 !important;
    line-height: normal !important;
}
#menu_tetiere > ul > li > table ul li a {
    display: block !important;
    color: #1f2937 !important;
    padding: 8px 14px !important;
    border-radius: 4px;
    font-size: 13px !important;
    font-weight: 500 !important;
    text-transform: none !important;
}
#menu_tetiere > ul > li > table ul li a:hover {
    background: #f3f4f6 !important;
    color: #2eaadc !important;
}

/* ---------- Layout : centre / droite (2 colonnes via flex sur #contenu) ---------- */
@media screen and (min-width: 1001px) {
    #contenu {
        display: flex !important;
        flex-direction: row !important;
        gap: 24px;
        align-items: flex-start;
        padding: 24px 32px !important;
        background: #f5f6f8 !important;
        box-sizing: border-box;
        max-width: 100%;
    }
    #centre, #centreetdroite {
        flex: 1 1 auto;
        min-width: 0;
        padding: 0 !important;
        left: 0 !important;
        width: auto !important;
        float: none !important;
    }
    #droite {
        flex: 0 0 280px;
        width: 280px !important;
        padding: 0 !important;
        margin: 0 !important;
        height: auto !important;
        right: 0 !important;
        float: none !important;
    }
    #gauche {
        flex: 0 0 200px;
        width: 200px !important;
    }
}
/* Tablette/mobile : empilé */
@media screen and (max-width: 1000px) {
    #contenu {
        background: #f5f6f8 !important;
        padding: 16px !important;
        display: block !important;
    }
    #centre, #droite, #centreetdroite, #gauche {
        width: 100% !important;
        padding: 0 !important;
        left: 0 !important;
        float: none !important;
        height: auto !important;
    }
    #droite {
        margin-top: 16px !important;
    }
}

/* ---------- Cartes / paragraphes ---------- */
#centre > .paragraphe,
.paragraphe.par_encadre {
    background: #ffffff !important;
    border: none !important;
    border-radius: 12px !important;
    padding: 20px !important;
    margin-bottom: 16px !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04) !important;
}
#droite .paragraphe {
    background: #ffffff !important;
    border: none !important;
    border-radius: 12px !important;
    padding: 16px !important;
    margin-bottom: 12px !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06) !important;
}

/* ---------- Widget Coups de coeur ---------- */
@media screen and (min-width: 1001px) {
    .paragraphe.coupcoeur table {
        border-collapse: separate;
        border-spacing: 16px 0;
        width: 100%;
    }
    .paragraphe.coupcoeur td {
        background: #fafbfc;
        border-radius: 10px;
        padding: 14px !important;
        vertical-align: top;
        border: 1px solid #eef0f3;
    }
}
.paragraphe.coupcoeur td a {
    font-size: 13px;
    line-height: 1.4;
}
.paragraphe.coupcoeur td img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* Mobile : stack vertical des 4 tds coups de coeur via flex */
@media screen and (max-width: 1000px) {
    body .paragraphe.coupcoeur table,
    body .paragraphe.coupcoeur tbody {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    body .paragraphe.coupcoeur tr {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    body .paragraphe.coupcoeur td {
        display: block !important;
        width: 100% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        text-align: center !important;
        padding: 8px 12px !important;
        background: transparent !important;
        border: none !important;
        flex: 1 0 100% !important;
        align-self: stretch !important;
    }
    body .paragraphe.coupcoeur td:nth-child(2) {
        padding-bottom: 16px !important;
        border-bottom: 1px solid #e5e7eb !important;
        margin-bottom: 16px !important;
    }
}

/* ---------- Fieldset / legend ---------- */
fieldset {
    border: none !important;
    background: #fff !important;
    border-radius: 12px !important;
    padding: 16px !important;
    margin: 0 0 16px 0 !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
legend {
    background: transparent !important;
    color: #1f2937 !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    padding: 0 8px !important;
    text-transform: none !important;
}

/* ---------- Inputs / boutons globaux ---------- */
input[type=text],
input[type=email],
input[type=tel],
input[type=search],
input[type=password],
select,
textarea {
    border: 1px solid #d1d5db !important;
    border-radius: 6px !important;
    padding: 8px 12px !important;
    font-size: 14px !important;
    font-family: inherit !important;
    background: #fff !important;
    color: #1f2937 !important;
    box-sizing: border-box;
}
input[type=text]:focus,
input[type=email]:focus,
input[type=tel]:focus,
input[type=search]:focus,
input[type=password]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #2eaadc !important;
    box-shadow: 0 0 0 3px rgba(46,170,220,0.15);
}
input[type=submit],
input[type=button],
a.bouton, a.bouton:visited,
button[type=submit] {
    background: #2eaadc !important;
    border: none !important;
    color: #fff !important;
    padding: 9px 18px !important;
    border-radius: 6px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: background 0.15s ease;
    font-size: 13px !important;
    box-shadow: none !important;
    text-decoration: none !important;
}
input[type=submit]:hover,
input[type=button]:hover,
a.bouton:hover,
button[type=submit]:hover {
    background: #1d8db9 !important;
    transform: none !important;
    text-decoration: none !important;
}

/* ---------- Tableaux d'annonces ---------- */
table.annonce,
table.immo,
table.PRODUIT,
.mdl_immo table,
.mdl_annonce table {
    border-collapse: separate !important;
    border-spacing: 0 8px !important;
}
table.annonce td,
table.immo td,
table.PRODUIT td {
    background: #fff;
    border-bottom: 1px solid #f3f4f6 !important;
    padding: 12px !important;
}

/* ---------- Footer (#pied / #bas) ---------- */
#pied,
#bas {
    background: #111827 !important;
    color: #cbd5e1 !important;
    padding: 32px !important;
    height: auto !important;
    border: none !important;
}
#pied a, #pied a:visited,
#bas a, #bas a:visited {
    color: #cbd5e1 !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    font-size: 13px !important;
}
#pied a:hover, #bas a:hover {
    color: #fff !important;
    text-decoration: underline !important;
}
#pied table, #bas table {
    margin: 0 !important;
    border: none !important;
    width: 100% !important;
}
#pied table td, #bas table td {
    padding: 0 24px 0 0 !important;
    vertical-align: top;
}

/* ---------- Bouton toTop ---------- */
#totop, #toTop {
    background: #1f2937 !important;
    color: #fff !important;
    border-radius: 50% !important;
    width: 44px !important;
    height: 44px !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15) !important;
    border: none !important;
}

/* ---------- Carte des départements ---------- */
.carteFASILANNONCE {
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

/* ---------- Toggle IMMO/DIVERS (onglets) ---------- */
.tab_actif, .tab_inactif {
    border-radius: 6px 6px 0 0 !important;
}
