/* ===========================================================================
   agrikole-child — site-custom.css
   Personnalisations « métier » conservées, migrées depuis le Personnalisateur
   (Apparence → CSS additionnel). Nettoyé, dédupliqué, sectionné.

   N'inclut PAS :
   - les rustines d'espacement header  → voir header-fix.css
   - h5,h6 { font-family:'Bookman Old Style' !important }  → SUPPRIMÉ (cause
     racine du forçage de police ; chaque module du plugin la combattait)
   - le bloc .current-menu-item commenté (mort) → supprimé
   =========================================================================== */


/* ---------------------------------------------------------------------------
   1. WPAdverts (petites annonces)
   --------------------------------------------------------------------------- */

/* Masquer avatar + nom auteur sur la fiche annonce */
.-adverts-single-author-avatar,
.-adverts-single-author-name {
    display: none !important;
}

.adverts-multiselect-options label {
    font-size: 20px;
}

/* Titre de section (ex : Description) */
.wpadverts-cpt .atw-font-bold {
    font-size: 20px !important;
    font-weight: 700;
}

/* Texte de description */
.wpadverts-cpt .atw-text-base,
.wpadverts-cpt .atw-text-base p {
    font-size: 18px !important;
    line-height: 1.5;
}

/* Menu de tri */
#js-wpa-sort-options a,
#js-wpa-sort-options span {
    font-size: 10px !important;
}
#js-wpa-sort-options strong {
    font-size: 15px !important;
    font-weight: bold;
}

/* Titres de sections du formulaire */
.wpa-form-header-label {
    font-size: 20px !important;
    font-weight: bold;
}

/* Labels des champs */
.wpa-field-label-text {
    font-size: 18px !important;
    font-weight: 500;
}

/* Résultats de recherche : titre, métadonnées, prix */
.wpa-result-title-text {
    font-size: 1.8rem !important;
    font-weight: 700 !important;
}
.wpa-result-meta {
    font-size: 1.2rem !important;
}
.wpa-result-last-text {
    font-size: 1.8rem !important;
    color: #000;
}

/* « N results found. » */
.atw-flex strong.atw-text-base,
.atw-flex span.atw-text-base {
    font-size: 1.5rem !important;
    font-weight: 600;
}


/* ---------------------------------------------------------------------------
   2. LearnPress (cours) — masquages d'éléments d'UI non souhaités
   --------------------------------------------------------------------------- */

.lp-single-course-sidebar,
.course-instructor-category,
.lp-single-course-info-one,
.lp-section-instructor,
.info-metas {
    display: none !important;
}

.lp-single-course-main__right {
    position: relative;
    top: 70px;
}


/* ---------------------------------------------------------------------------
   3. Encart « menu association » (widget de navigation custom)
      .menu-association était déclaré 2× dans le Personnalisateur → fusionné.
   --------------------------------------------------------------------------- */

.menu-association {
    margin-top: 40px;
    padding: 35px 50px 40px;
    background-color: #faf8f5;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease;
    font-family: Arial, sans-serif;
    color: #333;
    position: relative;
}

.menu-association:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Compacité entre tous les blocs internes */
.menu-association > * {
    margin-top: 8px;
    margin-bottom: 8px;
}

.menu-association h2,
.menu-association .widgettitle {
    font-size: 24px;
    margin-top: 12px;
    margin-bottom: 10px;
    color: #2a2a2a;
    font-weight: 600;
    border-bottom: 2px solid #e0dcd7;
    padding-bottom: 5px;
}

.menu-association ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.menu-association ul li {
    margin-bottom: 6px;
    line-height: 1.3;
}

.menu-association ul li a {
    color: #333;
    text-decoration: none;
    padding: 6px 0;
    display: inline-block;
    transition: color 0.2s ease, padding-left 0.2s ease;
}

.menu-association ul li a:hover {
    color: #2a7ae2;
    padding-left: 4px;
    text-decoration: underline;
}

.menu-association ul.sub-menu {
    list-style: none;
    padding-left: 1em;
    margin-top: 6px;
}

/* Élément de sous-menu avec flèche */
.menu-association ul.sub-menu li::before {
    content: "➔ ";
    color: #2a7ae2;
    margin-right: 6px;
    font-weight: bold;
}

/* Supprimer cadre/fond des conteneurs parents directs */
.my_widget_menu,
.my_widget_menu > .vc_column-inner,
.my_widget_menu > .vc_column-inner > .wpb_wrapper,
.menu-association > .widget_nav_menu {
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
}


/* ---------------------------------------------------------------------------
   4. Navigation : menu courant, sous-menus
   --------------------------------------------------------------------------- */

[aria-current] {
    font-weight: bold;
    color: #b0ca41 !important;
}
[aria-current]:hover {
    color: #5b8c51 !important;
}

.menu-item ul {
    min-width: 150px;
    width: auto !important;
    max-width: 400px;
    white-space: nowrap;
}
.menu-item ul li a {
    display: block;
    padding: 10px 15px;
    text-align: left;
}


/* ---------------------------------------------------------------------------
   5. Utilitaires divers
   --------------------------------------------------------------------------- */

.myhidden {
    display: none;
}

.my_bkgradient1 {
    background: linear-gradient(180deg, rgba(245, 240, 233, 1) 0%, rgba(255, 255, 255, 0) 80%);
}

.search-field::placeholder {
    color: white;
}

.wpcf7-response-output {
    color: white;
    background-color: #5b8c51;
}

.custom-post-image {
    max-height: 400px;
    width: auto;
    max-width: 100%;
    display: block;
    margin: 20px auto;
    object-fit: cover;
    cursor: pointer;
}


/* ---------------------------------------------------------------------------
   6. Typographie — système cohérent (titres)
   ---------------------------------------------------------------------------
   Problème corrigé : le panneau Personnaliser → Typography (theme_mods
   `agrikole-child`) contient deux couches contradictoires :
     - section "Headings"  → h1..h6 = Amatic SC
     - sections "H1".."H4" → h1..h4 = "Bookman Old Style, serif" (tailles
       incohérentes : h1=20px alors que h2=30px) ; PAS de "H5"/"H6".
   Conséquence : h1..h4 en Bookman, h5/h6 en Amatic SC → deux titres voisins
   (ex. accueil : "Nos dernières actualités" h4 vs "Nos formations à venir"
   h5) n'ont jamais la même police.

   Choix retenu : TITRES en serif "Bookman Old Style", CORPS en "Barlow"
   (couple serif/sans éditorial classique, lisible). Appliqué de façon
   IDENTIQUE à h1..h6 → fin du mélange Bookman/Amatic.

   "Bookman Old Style" n'est PAS une police web (jamais chargée → présente
   seulement sur Windows/Office). Repli robuste : Georgia (serif chaude
   présente sur quasiment tous les OS, très proche de Bookman) avant le
   serif générique. Rendu cohérent partout (Bookman sur Windows, Georgia
   ailleurs — deux serifs quasi identiques), sans requête de police
   supplémentaire. Échelle de tailles régulière (ratio ~1.25), graisse et
   couleur constantes.

   Cascade : cette feuille est enqueue APRÈS le <style> inline du thème
   (`agrikole-theme-style-inline-css`, même handle, dépendance déclarée,
   prio 20 — cf. functions.php) → on gagne à spécificité égale SANS
   !important. Seul `.heading-font` du thème utilise !important (style.css)
   → on le réaligne explicitement.

   Tailles en px : le thème impose html{font-size:62.5%} (1rem≈10px) ;
   le px évite ce piège (convention déjà retenue dans header-fix.css).

   NB : sur l'accueil, les titres de section "agrikole-headings" portent une
   taille EN DUR dans le contenu Visual Composer (style="font-size:40px"…) :
   un style inline bat toute feuille → ces tailles-là restent telles quelles
   (hiérarchie voulue par le page builder). Mais la POLICE n'est pas inline →
   elle est désormais unifiée (Barlow) : les deux titres de l'accueil ont
   enfin la même police.
   --------------------------------------------------------------------------- */

h1, h2, h3, h4, h5, h6,
.main-title,
.heading,
.widget-title,
.post-title,
.vc_custom_heading,
.heading-font {
    font-family: "Bookman Old Style", Georgia, "Times New Roman", serif;
    color: #404a3d;
    letter-spacing: normal;
}

/* .heading-font est forcé en Amatic SC !important par le thème (style.css) */
.heading-font {
    font-family: "Bookman Old Style", Georgia, "Times New Roman", serif !important;
}

/* Échelle de titres native (h1..h6). Ne combat PAS les tailles inline des
   éléments Visual Composer — voir note ci-dessus. */
h1 { font-size: 40px; line-height: 1.2;  font-weight: 700; }
h2 { font-size: 32px; line-height: 1.25; font-weight: 700; }
h3 { font-size: 26px; line-height: 1.3;  font-weight: 700; }
h4 { font-size: 22px; line-height: 1.3;  font-weight: 700; }
h5 { font-size: 19px; line-height: 1.35; font-weight: 700; }
h6 { font-size: 17px; line-height: 1.4;  font-weight: 600; }
