:root {
    --bg-beige: #F9F6F0;
    --bg-beige-dark: #EFEBE4;
    --bleu-pastel: #A9C2D0;
    --bois-sombre: #4A3E3D;
    --bois-moyen: #7A6253;
    --bg-beige-doux : #fffefc;
    --blanc: #FFFFFF;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Helvetica, Arial, sans-serif;
    background-color: var(--bg-beige);
    color: var(--bois-sombre);
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

h1, h2, h3 { color: var(--bois-moyen); font-weight: 600; }

/* ==========================================================================
   Navigation (Header)
   ========================================================================== */
nav {
    display: flex; justify-content: space-between; align-items: center;
    padding: 1rem 2rem; 
    background-color: var(--bg-beige); 
    box-shadow: none; 
}

nav .logo {
    display: flex;
    align-items: center;
    gap: 0.8rem; 
    font-weight: bold;
    color: var(--bois-moyen);
}

.logo-img {
    height: 48px;  
    width: 48px;   
    object-fit: contain;
    border-radius: 4px; 
}

nav > ul {
    display: flex;
    align-items: center; 
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 1rem; 
}

nav > ul > li > a {
    text-decoration: none; color: var(--bois-sombre); font-weight: 500;
    padding-bottom: 5px; border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

nav > ul > li > a:hover {
    color: var(--bois-moyen); border-bottom: 2px solid var(--bleu-pastel);
}

/* ==========================================================================
   Menu Déroulant 
   ========================================================================= */
.menu-deroulant {
    position: relative;
}

.sous-menu {
    display: none; 
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--blanc);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-radius: 8px;
    min-width: 250px; 
    padding: 0.5rem 0;
    z-index: 100;
    list-style: none;
    margin: 0;
}

.menu-deroulant:hover .sous-menu {
    display: block; 
}

.sous-menu li {
    width: 100%;
    margin: 0;
    padding: 0;
}

.sous-menu a {
    display: block;
    padding: 0.6rem 1.5rem;
    text-align: left; 
    color: var(--bois-sombre);
    text-decoration: none;
    font-size: 0.95rem;
    border-bottom: none !important; 
    transition: background-color 0.2s ease, color 0.2s ease;
}

.sous-menu a:hover {
    background-color: var(--bg-beige); 
    color: var(--bois-moyen);
    border-bottom: none !important;
}

/* Bouton Prendre RDV dans la barre de navigation */
.btn-rdv-menu {
    background-color: var(--bois-moyen);
    color: var(--blanc) !important;
    font-weight: 500; 
    font-size: 0.95rem; 
    display: inline-flex;
    align-items: center; 
    justify-content: center;
    padding: 0.4rem 1.2rem !important; 
    border-radius: 20px;
    line-height: 1.5; 
    transition: background-color 0.3s ease;
}

.btn-rdv-menu:hover {
    background-color: var(--bois-sombre) !important;
}

/* ==========================================================================
   Section d'Accueil (Hero Modernisé à 2 colonnes)
   ========================================================================== */
.hero {
    background-color: var(--bleu-pastel);
    padding: 4rem 2rem;
}

.hero-container {
    max-width: 1000px; 
    margin: 0 auto;
    display: flex;
    flex-direction: row; 
    align-items: center;
    justify-content: center;
    gap: 3rem; 
}

.hero-photo {
    flex: 1;
    max-width: 350px; 
    display: flex;
    justify-content: center;
}

.portrait-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    max-height: 300px;
    object-fit: cover;
    border-radius: 16px; 
    box-shadow: 0 10px 25px rgba(74, 62, 61, 0.15); 
    background-color: #EFEBE4;  
}

.hero-texte {
    flex: 1.5; 
    text-align: left; 
    color: var(--bois-sombre);
}

.hero-texte h1 {
    color: var(--bois-sombre);
    font-size: 2.6rem;
    margin-top: 0;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-texte p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* ==========================================================================
   Boutons globaux et Sections
   ========================================================================== */
.btn-rdv {
    display: inline-block; background-color: var(--bois-moyen); color: var(--blanc);
    text-decoration: none; padding: 1rem 2.5rem; border-radius: 50px;
    font-weight: bold; box-shadow: 0 4px 15px rgba(122, 98, 83, 0.3);
    transition: all 0.3s ease;
}

.btn-rdv:hover {
    background-color: #655044; transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(122, 98, 83, 0.5);
}

section { padding: 4rem 1rem; max-width: 800px; margin: 0 auto; }

#motifs {
    background-color: var(--bg-beige-dark); max-width: 100%; padding: 4rem 2rem;
}

.container-motifs { max-width: 800px; margin: 0 auto; }

.grille-cartes {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem; margin-top: 2rem;
}

.carte {
    background-color: var(--blanc); padding: 1.5rem; border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04); font-weight: 500;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.carte:hover {
    transform: translateY(-5px); box-shadow: 0 8px 20px rgba(74, 62, 61, 0.1);
}

#approche ul {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

#approche ul li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

/* ==========================================================================
   Mise en page des Articles (Effet Carte Blanche)
   ========================================================================== */
.article-container {
    max-width: 900px;
    margin: 4rem auto;
    padding: 0 1rem;
}

.article-carte {
    background-color: var(--blanc);
    padding: 4rem 5rem;
    border-radius: 16px;
    box-shadow: none;
    border: 1px solid rgba(74, 62, 61, 0.08);
    color: var(--bois-sombre);
    line-height: 1.7;
}

.article-header {
    text-align: center;
    margin-bottom: 3.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--bg-beige-dark);
}

.article-header h1 {
    font-size: 2.5rem;
    color: var(--bois-moyen);
    margin-top: 0;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.article-description {
    font-size: 1.15rem;
    color: var(--bois-sombre);
    font-style: italic;
    opacity: 0.85;
    max-width: 700px;
    margin: 0 auto;
}

/* ==========================================================================
   Styles typographiques des articles (Markdown)
   ========================================================================== */
main p, main li {
    font-size: 1.1rem; 
    color: var(--bois-sombre);
}

main h2 {
    margin-top: 3rem; 
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--bg-beige-dark); 
}

main h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

main ul, main ol {
    margin-bottom: 2rem;
}

main li {
    margin-bottom: 0.8rem; 
}

main blockquote {
    border-left: 4px solid var(--bleu-pastel); 
    background-color: var(--bg-beige-dark); 
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: var(--bois-moyen);
}

main table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    background-color: var(--blanc);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

main th, main td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--bg-beige-dark);
}

main th {
    background-color: var(--bleu-pastel);
    color: var(--bois-sombre);
    font-weight: 600;
}

/* ==========================================================================
   Pied de page (Footer)
   ========================================================================== */
footer {
    background-color: var(--bois-sombre); 
    color: var(--blanc);
    text-align: center;
    padding: 2rem 1rem;
    margin-top: 4rem; 
}

.footer-content {
    display: flex;
    flex-direction: column;   
    align-items: center;       
    justify-content: center;   
    text-align: center;        
    width: 100%;
}

.footer-liens {
    margin-top: 0.5rem;
    color: var(--beige-clair, #F8F5F2);
    text-decoration: none;
    font-size: 0.85rem;
    opacity: 0.8; 
    transition: opacity 0.3s ease;
}

.footer-liens a:hover {
    opacity: 1;
    text-decoration: underline;
}

.tel-protect::after { content: attr(data-fin); }
.mail-protect::after { content: attr(data-arobase) attr(data-domaine); }


/* ==========================================================================
   Menu Burger (Bouton masqué sur ordinateur)
   ========================================================================== */
.menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 24px;
    flex-direction: column;
    justify-content: space-between;
    z-index: 101; 
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: var(--bois-moyen);
    border-radius: 2px;
    transition: all 0.3s ease-in-out;
}

/* ==========================================================================
   Adaptation pour les écrans de Smartphones (Responsive Global)
   ========================================================================== */
@media (max-width: 768px) {
    /* --- 1. L'accueil et les articles (Tes règles d'origine) --- */
    .hero-container { flex-direction: column; text-align: center; gap: 2rem; }
    .hero-texte { text-align: center; }
    .hero-texte h1 { font-size: 2rem; }
    .article-container { margin: 2rem auto; }
    .article-carte { padding: 2rem 1.5rem; border-radius: 12px; box-shadow: none; border: 1px solid rgba(74, 62, 61, 0.08); }
    .article-header h1 { font-size: 2rem; }

    /* --- 2. NOUVEAU : Comportement du Menu Burger --- */
    .menu-toggle {
        display: flex; 
    }

    /* Le menu devient une colonne masquée par défaut */
    .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 75px; /* S'affiche juste sous ton header */
        left: 0;
        width: 100%;
        background-color: var(--bg-beige);
        padding: 2rem 0;
        box-shadow: 0 10px 15px rgba(0,0,0,0.05);
        gap: 1.5rem;
        z-index: 100;
        
        /* Masqué par défaut */
        opacity: 0;
        visibility: hidden;
        transform: translateY(-20px);
        transition: all 0.3s ease;
    }

    /* Classe activée par le clic (JavaScript) */
    .nav-links.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    /* Centrer les éléments et réinitialiser les sous-menus pour le mobile */
    .nav-links li {
        text-align: center;
        width: 100%;
    }
    
    .sous-menu {
        position: relative; /* Annule le positionnement flottant du PC */
        box-shadow: none;
        background-color: transparent;
        padding: 0.5rem 0;
    }
    
    .sous-menu a {
        text-align: center;
    }

    /* Animation du bouton qui se transforme en croix */
    .menu-toggle.open span:nth-child(1) { transform: translateY(10.5px) rotate(45deg); }
    .menu-toggle.open span:nth-child(2) { opacity: 0; }
    .menu-toggle.open span:nth-child(3) { transform: translateY(-10.5px) rotate(-45deg); }

    /* --- 3. NOUVEAU : Correction des Tableaux --- */
    main table {
        display: block; 
        overflow-x: auto; 
        white-space: nowrap; 
        -webkit-overflow-scrolling: touch; 
    }
}